Skip to content

Commit

Permalink
update cap config for new server
Browse files Browse the repository at this point in the history
  • Loading branch information
acoffman committed Oct 23, 2024
1 parent 6e48267 commit c837092
Showing 1 changed file with 14 additions and 1 deletion.
15 changes: 14 additions & 1 deletion server/config/deploy/production.rb
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
server "44.231.73.12", user: 'ubuntu', roles: %w{web db app}

set :branch, 'release'
set :rbenv_ruby, '3.3.0'
set :rbenv_ruby, '3.3.5'

set :rails_env, 'production'

Expand All @@ -14,3 +14,16 @@
auth_methods: %w(publickey)
}
end

# from https://github.com/capistrano/rails?tab=readme-ov-file#uploading-your-masterkey
namespace :deploy do
namespace :check do
before :linked_files, :set_master_key do
on roles(:app) do
unless test("[ -f #{shared_path}/config/credentials/production.key ]")
upload! 'config/credentials/production.key', "#{shared_path}/config/credentials/production.key"
end
end
end
end
end

0 comments on commit c837092

Please sign in to comment.