From 2d119f2ecdd8ca4251348b2efd6f532e77059607 Mon Sep 17 00:00:00 2001 From: Andrew Cantino Date: Thu, 14 Mar 2013 22:22:01 -0700 Subject: [PATCH] The Backup gem doesn't work well when used inside of Bundler. --- Gemfile | 4 ---- README.md | 2 +- config/database.yml | 2 +- config/example_backup.rb | 4 +++- 4 files changed, 5 insertions(+), 7 deletions(-) diff --git a/Gemfile b/Gemfile index c605f946a5..ec4a007945 100644 --- a/Gemfile +++ b/Gemfile @@ -34,10 +34,6 @@ gem 'em-http-request' gem 'unicorn' -# If you want to use the Backup gem for backups, uncomment these lines: -# gem 'backup', :require => false -# gem 'fog', '~> 1.4.0', :require => false - group :development do gem 'capistrano' gem 'capistrano-unicorn', :require => false diff --git a/README.md b/README.md index 393b36309b..60a677663b 100644 --- a/README.md +++ b/README.md @@ -108,7 +108,7 @@ We assume your deployment will run over SSL. This is a very good idea! However, #### Setup Backups -Checkout `config/example_backup.rb` for an example script that you can use with the Backup gem. If you want to use it, uncomment the associated lines in your Gemfile. +Checkout `config/example_backup.rb` for an example script that you can use with the Backup gem. ## License diff --git a/config/database.yml b/config/database.yml index 04b2319173..990eab6d33 100644 --- a/config/database.yml +++ b/config/database.yml @@ -29,4 +29,4 @@ production: pool: 5 username: root password: password - socket: <%= ["/var/run/mysqld/mysqld.sock", "/opt/local/var/run/mysql5/mysqld.sock", "/tmp/mysql.sock"].find{ |path| File.exist? path } %> + socket: /var/run/mysqld/mysqld.sock \ No newline at end of file diff --git a/config/example_backup.rb b/config/example_backup.rb index b8940531a4..3f89001c32 100644 --- a/config/example_backup.rb +++ b/config/example_backup.rb @@ -1,13 +1,15 @@ # This file contains an example template for using the Backup gem for backing up your Huginn installation to S3. # In your crontab do something like: -# 0 0,12 * * * /bin/bash -l -c "cd /home/you/app/current && RAILS_ENV=production bundle exec backup perform -t huginn_backup --config_file /home/you/huginn_backup.rb" 2>&1 >> /home/you/huginn_backup_log.txt +# 0 0,12 * * * /bin/bash -l -c "RAILS_ENV=production backup perform -t huginn_backup --config_file /home/you/huginn_backup.rb" 2>&1 >> /home/you/huginn_backup_log.txt # In backups.password on your server: # some password # In huginn_backup.rb on your server put an edited version of the following file. REMEMBER TO EDIT THE FILE! +# You'll also need to install the backup gem on your server, as well as the net-ssh, excon, net-scp, and fog gems. + database_yml = '/home/you/app/current/config/database.yml' rails_env = ENV['RAILS_ENV'] || 'production'