From 58d6dcb46aede39229cd0caa63ad5ec3c8faab7b Mon Sep 17 00:00:00 2001 From: zunda Date: Fri, 2 Jun 2017 21:19:30 -1000 Subject: [PATCH] Remove the procedure to run `rake secret` outside the container This change will help users avoid unnecessary procedure to complete `bundle install` outside the container. The explanation > To generate the PAPERCLIP_SECRET, SECRET_KEY_BASE, and > OTP_SECRET, you may use: > > ``` > rake secret > ``` gives users a false impression that secrets have to be filled in before the image can be built. Here, with introduction of CLD3, completion of `bundle install` became more involved procedure to prepare tools and libraries as well as higher version of Ruby. --- Running-Mastodon/Docker-Guide.md | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/Running-Mastodon/Docker-Guide.md b/Running-Mastodon/Docker-Guide.md index 245a50df..946a5fbe 100644 --- a/Running-Mastodon/Docker-Guide.md +++ b/Running-Mastodon/Docker-Guide.md @@ -21,9 +21,8 @@ Then, you need to fill in the `.env.production` file: Do NOT change the `REDIS_*` or `DB_*` settings when running with the default docker configurations. -You will need to fill in, at least: `LOCAL_DOMAIN`, `LOCAL_HTTPS`, `PAPERCLIP_SECRET`, `SECRET_KEY_BASE`, `OTP_SECRET`, and the `SMTP_*` settings. To generate the `PAPERCLIP_SECRET`, `SECRET_KEY_BASE`, and `OTP_SECRET`, you may use: +You will need to fill in, at least: `LOCAL_DOMAIN`, `LOCAL_HTTPS`, and the `SMTP_*` settings. - rake secret ## Building the app @@ -31,9 +30,9 @@ Before running the first time, you need to build the images: docker-compose build - docker-compose run --rm web rake secret +Now the image can be used to generate secrets. Run the command below for each of `PAPERCLIP_SECRET`, `SECRET_KEY_BASE`, and `OTP_SECRET` then copy the results into the `.env.production` file: -Do this once for each of those keys, and copy the result into the `.env.production` file in the appropriate field. + docker-compose run --rm web rake secret Then you should run the `db:migrate` command to create the database, or migrate it from an older release: