I'd like to contribute "php artisan env:update / :add / :delete" #44346
Unanswered
maxwoerner
asked this question in
Ideas
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Hey there,
I recently had to update an existing environment variable in Laravel with a little shell script (side note: I used the "sed" command on Ubuntu for this). However, I thought it might be a nice idea to have an Artisan command to update / add / delete specific environment variables within the .env file.
This could be particulary useful for configuration management products like Ansible, Terraform, etc. It would be very easy (and secure) to e.g. update the AWS_ACCESS_KEY without even showing it to the user (which was exactly my use case btw). In addition, users might prefer the artisan command instead of manually editing the file.
I was thinking of something like:
php artisan env:update AWS_ACCESS_KEY 1234567890
I'd be happy to contribute this to the framework. What are your thoughts?
Beta Was this translation helpful? Give feedback.
All reactions