Your "Minimal Viable Product" is finished, now you want to publish it on the web.
After working through this guide you should be able to
Slides - use arrow keys to navigate, esc to return to page view, f for fullscreen
heroku is one "Platform as a Service" provider that offers to host your rails app. Heroku uses git to push the code to the production server.
(See also Railsbridge Installfest: Create A Heroku Account and Railsbridge Installfest: Deploy A Rails App )
in your rails app, which is already using git:
That's it. You should now have an app with a very strange URL, like http://mighty-shore-1497.herokuapp.com/
(See also Railsbridge Installfest)
id_rsa
id_rsa.pub
~/.ssh/id_rsa
~/.ssh/authorized_keys2
deploy_x
is set up as an account on the server~deploy_x/.ssh/authorized_keys2
~deploy_x/.ssh/authorized_keys2
ssh-rsa AAAAB3NzaC...2EAAAABI== alice@fh-salzburg.ac.at
ssh-rsa AAAAB8NzaC...DVj3R4Ww== bob@fh-salzburg.ac.at
DocumentRoot
to public/
RailsEnv production
tmp/restart.txt
to force reload of codecapfile
$ sudo gem install capistrano
Fetching: capistrano-2.13.5.gem (100%)
Successfully installed capistrano-2.13.5
1 gem installed
$ $ cap install
mkdir -p config/deploy
create config/deploy.rb
create config/deploy/staging.rb
create config/deploy/production.rb
mkdir -p lib/capistrano/tasks
create Capfile
Capified
config/deploy.rb
local information, see our wiki
task :display_free_disk_space do
run "df -h"
end
$ cap production git:check
$ scp config/database.yml deployuser@server:/var/www/.../shared/config
$ scp config/secrets.yml deployuser@server:/var/www/.../shared/config
$ cap production deploy
$ cap production deploy
$ cap display_free_disk_space
* 2012-11-29 05:34:45 executing 'display_free_disk_space'
* executing "df -h"
servers: ["multimediaart.at"]
Password: ****
[multimediaart.at] executing command
** [out :: multimediaart.at] Size Used Avail Use% Mounted on
** [out :: multimediaart.at] 98G 70G 24G 75% /var/www
command finished in 165ms
read the logfile, try to find out how capistrano lays out the folders
$ cap deploy:setup
$ cap deploy:check
$ cap deploy:cold
$ cap deploy:upload FILES='config/database.yml'