Skip to content

Commit 9e71b54

Browse files
committed
wip
1 parent ae5cfb0 commit 9e71b54

File tree

1 file changed

+23
-0
lines changed

1 file changed

+23
-0
lines changed

README.md

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -82,6 +82,29 @@ In case `config/credentials/#{Rails.app_env}.key` does not exist, it falls back
8282
As with default Rails behaviours, if `ENV["RAILS_MASTER_KEY"]` is present, it takes precedence over
8383
`config/credentials/#{Rails.app_env}.key` and `config/master.key`.
8484

85+
As with default Rails behaviours, when invoking `$ rails credentials` commands, specific the `--environment` option
86+
instead of using `APP_ENV` and `RAILS_ENV`.
87+
88+
```console
89+
$ APP_ENV=foo RAILS_ENV=bar bin/rails credentials:edit --environment qaz
90+
91+
# Creates or edits the following files:
92+
# config/credentials/qaz.key
93+
# config/credentials/qaz.yml.enc
94+
#
95+
# APP_ENV and RAILS_ENV are ignored.
96+
```
97+
98+
```console
99+
# Creates or edits the following files:
100+
# config/credentials/qaz.key
101+
# config/credentials/qaz.yml.enc
102+
#
103+
# APP_ENV and RAILS_ENV are ignored.
104+
#
105+
$ APP_ENV=foo RAILS_ENV=bar bin/rails credentials:edit --environment qaz
106+
```
107+
85108
Learn more in the [Heroku](#heroku) section below.
86109

87110
### Console

0 commit comments

Comments
 (0)