From f592a38562a79883e275ba0d95b57643ac7c7ac3 Mon Sep 17 00:00:00 2001 From: Martin Fenner Date: Sun, 22 Nov 2020 13:25:52 +0100 Subject: [PATCH] correctly set env variables. #681 --- .env.build | 3 --- .github/workflows/deploy.yml | 14 +++++++++++--- 2 files changed, 11 insertions(+), 6 deletions(-) diff --git a/.env.build b/.env.build index fcd9a4b36..e69de29bb 100644 --- a/.env.build +++ b/.env.build @@ -1,3 +0,0 @@ -# these ENV variables are not used in production and can be shared publicly -SESSION_ENCRYPTED_COOKIE_SALT=0769107f0f07c8b0c2bbdc50dc1785 -SECRET_KEY_BASE=5653e5687542b9ddb22a788b9d10bac6579a9c8933c2389b3e79a2b374adb0ab8751d026e9aafb5e55fb48bacbb8a42692a991be02046249388d558319236e1a diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml index f9629c3f5..f2106df5f 100644 --- a/.github/workflows/deploy.yml +++ b/.github/workflows/deploy.yml @@ -8,9 +8,11 @@ jobs: runs-on: ubuntu-latest env: MEMCACHE_SERVERS: "localhost:11211" - MYSQL_HOST: "localhost:3306" + MYSQL_HOST: "localhost" ES_HOST: "localhost:9200" ELASTIC_PASSWORD: "changeme" + SECRET_KEY_BASE: ${{ secrets.SECRET_KEY_BASE }} + SESSION_ENCRYPTED_COOKIE_SALT: ${{ secrets.SESSION_ENCRYPTED_COOKIE_SALT }} services: memcached: image: memcached:1.4.31 @@ -35,17 +37,23 @@ jobs: http.cors.allow-origin: "*" ports: - 9200:9200 - - 9300:9300 steps: - uses: actions/checkout@v2 - name: Set up Ruby 2.6 uses: actions/setup-ruby@v1 with: - ruby-version: '2.6.x' + ruby-version: '2.6.x' + - uses: actions/cache@v2 + with: + path: vendor/bundle + key: ${{ runner.os }}-gems-${{ hashFiles('**/Gemfile.lock') }} + restore-keys: | + ${{ runner.os }}-gems- - name: Install run: | cp .env.build .env gem install bundler + bundle config path vendor/bundle bundle install --jobs 4 --retry 3 bundle exec rails db:setup RAILS_ENV=test - name: Lint and Test