From 6b0c787e2b19b3de26940b0728e9443dfb60fefd Mon Sep 17 00:00:00 2001 From: f Date: Mon, 2 Mar 2020 13:29:26 -0300 Subject: [PATCH] ci/cd grrr --- .gitlab-ci.yml | 1 + config/deploy.rb | 15 +++++++-------- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 5e1c5bc..b73369e 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -12,3 +12,4 @@ deploy_application: - echo -e "-----BEGIN OPENSSH PRIVATE KEY-----\n$SSH_PRIVATE_KEY\n-----END OPENSSH PRIVATE KEY-----" | ssh-add - - echo "$RAILS_MASTER_KEY" > config/master.key - bundle exec cap production deploy + - rm -f config/master.key diff --git a/config/deploy.rb b/config/deploy.rb index e49e88c..1bf3e2e 100644 --- a/config/deploy.rb +++ b/config/deploy.rb @@ -9,16 +9,15 @@ append :linked_dirs, 'log', 'tmp/pids', 'tmp/cache', 'tmp/sockets', 'public/system', 'data', '.bundle', 'docs' set :bundle_flags, '--deployment' set :bundle_jobs, 1 -set :bundle_env_variables, { nokogiri_use_system_libraries: 1 } +set :bundle_env_variables, nokogiri_use_system_libraries: 1 set :keep_releases, 2 -set :ssh_options, verify_host_key: :always +set :ssh_options, verify_host_key_dns: true, check_host_ip: true -set :default_env, { - rails_env: 'production', - rails_master_key: File.read('config/master.key'), - web_concurrency: '1', - ld_preload: '/usr/lib/libjemalloc.so' -} +set :default_env, + rails_env: 'production', + rails_master_key: File.read('config/master.key'), + web_concurrency: '1', + ld_preload: '/usr/lib/libjemalloc.so' after 'deploy:published', 'pumx:stop' after 'pumx:stop', 'pumx:start'