You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@openwhisk.apache.org by "kh3654po (via GitHub)" <gi...@apache.org> on 2024/07/16 04:03:10 UTC
[I] When creating an action, how do you set the environment variables for the container? [openwhisk]
kh3654po opened a new issue, #5492:
URL: https://github.com/apache/openwhisk/issues/5492
I am creating an action using Rust, and I found /bin/compile.py in the default image used by OpenWhisk, which is openwhisk/action-rust-v1.34:nightly. Upon inspecting the code, I noticed that the RELEASE environment variable must be set in os.environ for the compile option to use the release build. However, I don't know how to set this environment variable.
```
def build(tgt_dir):
# support RELEASE
cmd = ["cargo", "build"]
bin_dir = "debug"
if "RELEASE" in os.environ:
cmd += "--release"
bin_dir = "release"
```
How do I set this environment variable?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@openwhisk.apache.org.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [I] When creating an action, how do you set the environment variables for the container? [openwhisk]
Posted by "sciabarracom (via GitHub)" <gi...@apache.org>.
sciabarracom commented on issue #5492:
URL: https://github.com/apache/openwhisk/issues/5492#issuecomment-2230419973
It should be in the docker file as ENV
Michele Sciabarra
CEO - Nuvolaris Inc
On Tue, 16 Jul 2024 at 06:03, kh3654po ***@***.***> wrote:
> I am creating an action using Rust, and I found /bin/compile.py in the
> default image used by OpenWhisk, which is
> openwhisk/action-rust-v1.34:nightly. Upon inspecting the code, I noticed
> that the RELEASE environment variable must be set in os.environ for the
> compile option to use the release build. However, I don't know how to set
> this environment variable.
>
> def build(tgt_dir):
> # support RELEASE
> cmd = ["cargo", "build"]
> bin_dir = "debug"
> if "RELEASE" in os.environ:
> cmd += "--release"
> bin_dir = "release"
>
> How do I set this environment variable?
>
> —
> Reply to this email directly, view it on GitHub
> <https://github.com/apache/openwhisk/issues/5492>, or unsubscribe
> <https://github.com/notifications/unsubscribe-auth/AHJ4D34BYS3LLGWWM6OPJRTZMSLSFAVCNFSM6AAAAABK5XQEMSVHI2DSMVQWIX3LMV43ASLTON2WKOZSGQYTAMJVGIYTGMQ>
> .
> You are receiving this because you are subscribed to this thread.Message
> ID: ***@***.***>
>
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@openwhisk.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org