Based on this tutorial but simplified and inlined. Particularly removed any Rails and 3rd party services part, assumed you just need deployment to any Ubuntu machine.
- A functional Rails app
- Hosted Git repository (Github, Bitbucket, Gitlab)
- Cloud hosting account (Digital Ocean, Vultr, Linode, Lightsail)
- Local SSH account
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Traducciones adicionales en https://github.com/plataformatec/devise/wiki/I18n | |
es: | |
devise: | |
confirmations: | |
confirmed: "Tu correo electr贸nico ha sido confirmado exitosamente." | |
send_instructions: "Recibir谩s un email con las instrucciones para confirmar tu correo electr贸nico en unos minutos." | |
send_paranoid_instructions: "Si tu correo electr贸nico existe en nuestra base de datos, recibir谩s un email con las instrucciones para confirmar tu correo electr贸nico en unos minutos." | |
failure: | |
already_authenticated: "Ya iniciaste sesi贸n." |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Sidekiq interaction and startup script | |
commands: | |
create_post_dir: | |
command: "mkdir -p /opt/elasticbeanstalk/hooks/appdeploy/post" | |
ignoreErrors: true | |
files: | |
"/opt/elasticbeanstalk/hooks/appdeploy/post/50_restart_sidekiq.sh": | |
mode: "000755" | |
owner: root | |
group: root |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# see the current limits | |
$ sysctl -a | grep maxproc | |
# increase it | |
$ sudo sysctl -w kern.maxproc=xxxx | |
$ sudo sysctl -w kern.maxprocperuid=xxx | |
# run at startup | |
$ sudo vim /etc/sysctl.conf |
You could have postgre installed on localhost with password (or without user or password seted after instalation) but if we are developing we really don't need password, so configuring postgre server without password for all your rails project is usefull.
- postgresql
- postgresql-client
- libpq-dev
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require 'tempfile' | |
require 'openssl' | |
require 'escape' # gem install escape | |
class CommandFailError < StandardError; end | |
def p12_to_pem_text(p12, pass='') | |
pass = '' if pass.nil? | |
# Use shell command for JRuby (see https://github.com/jruby/jruby-ossl/issues/8) |