File tree Expand file tree Collapse file tree 1 file changed +8
-6
lines changed Expand file tree Collapse file tree 1 file changed +8
-6
lines changed Original file line number Diff line number Diff line change @@ -233,17 +233,19 @@ manually store this file somewhere and deploy it. There are 2 ways to do that:
233
233
234
234
1) Uploading the file:
235
235
236
- The first option is to copy the **decryption key ** -
237
- ``/ config/secrets/prod/prod.decrypt.private.php `` to your server(s).
236
+ The first option is to copy the **production decryption key ** -
237
+ ``config/secrets/prod/prod.decrypt.private.php `` to your server(s).
238
238
239
239
2) Using an Environment Variable
240
240
241
241
The second way is to set the ``SYMFONY_DECRYPTION_SECRET `` environment variable
242
- to the base64 encoded value of the **decryption key **. A fancy way to fetch the
243
- value of the key is:
242
+ to the base64 encoded value of the **production decryption key **. A fancy way to
243
+ fetch the value of the key is:
244
244
245
245
.. code-block :: terminal
246
246
247
+ # this command only gets the value of the key; you must also set an env var
248
+ # in your system with this value (e.g. `export SYMFONY_DECRYPTION_SECRET=...`)
247
249
$ php -r 'echo base64_encode(require "config/secrets/prod/prod.decrypt.private.php");'
248
250
249
251
To improve performance (i.e. avoid decrypting secrets at runtime), you can decrypt
@@ -253,8 +255,8 @@ your secrets during deployment to the "local" vault:
253
255
254
256
$ php bin/console secrets:decrypt-to-local --force --env=prod
255
257
256
- This will put all the decrypted secrets into ``.env.prod.local ``. After doing this,
257
- the decryption key does *not * need to remain on the server.
258
+ This will write all the decrypted secrets into the ``.env.prod.local `` file.
259
+ After doing this, the decryption key does *not * need to remain on the server.
258
260
259
261
Rotating Secrets
260
262
----------------
You can’t perform that action at this time.
0 commit comments