Sha256: 4711711fce4e439089223f0538384fc8798430870849be213950cc3fcec434e8

Contents?: true

Size: 636 Bytes

Versions: 120

Compression:

Stored size: 636 Bytes

Contents

<%
  @read_cmd = 'crontab -l'
  @write_cmd = 'crontab -'
  @additive = ["# rubber-mysql-start", "# rubber-mysql-end"]
%>

<%
  # Backup db every 3 hours to secondary db if available, else primary db
  backup_db_host = rubber_instances.for_role('db', {}).first rescue nil
  backup_db_host ||= rubber_instances.for_role('db', 'primary' => true).first
  if backup_db_host.name == rubber_env.host
%>
0 */3 * * * BACKUP_DIR=/mnt/db_backups DBUSER=<%= rubber_env.db_user %> DBPASS=<%= rubber_env.db_pass %> DBNAME=<%= rubber_env.db_name %> DBHOST=<%= backup_db_host.full_name %> <%= RUBBER_ROOT %>/script/cron-rake rubber:backup_db
<% end %>

Version data entries

120 entries across 80 versions & 7 rubygems

Version Path
axtro-rubber-1.2.0 generators/vulcanize/templates/mysql/config/rubber/role/db/crontab
axtro-rubber-1.0.2.8 generators/vulcanize/templates/mysql/config/rubber/role/db/crontab
axtro-rubber-1.0.2.7 generators/vulcanize/templates/mysql/config/rubber/role/db/crontab
rubber-1.2.0 generators/vulcanize/templates/mysql/config/rubber/role/db/crontab
nirvdrum-rubber-1.1.7 generators/vulcanize/templates/mysql/config/rubber/role/db/crontab
rubber-1.1.7 generators/vulcanize/templates/mysql/config/rubber/role/db/crontab
rubber-1.1.6 generators/vulcanize/templates/mysql/config/rubber/role/db/crontab
rubber-1.1.5 generators/vulcanize/templates/mysql/config/rubber/role/db/crontab
rubber-1.1.4 generators/vulcanize/templates/mysql/config/rubber/role/db/crontab
rubber-1.1.3 generators/vulcanize/templates/mysql/config/rubber/role/db/crontab
rubber-1.1.2 generators/vulcanize/templates/mysql/config/rubber/role/db/crontab
rubber-1.1.1 generators/vulcanize/templates/mysql/config/rubber/role/db/crontab
rubber-1.1.0 generators/vulcanize/templates/mysql/config/rubber/role/db/crontab
axtro-rubber-1.0.2.6 generators/vulcanize/templates/mysql/config/rubber/role/db/crontab
axtro-rubber-1.0.2.5 generators/vulcanize/templates/mysql/config/rubber/role/db/crontab
axtro-rubber-1.0.2.4 generators/vulcanize/templates/mysql/config/rubber/role/db/crontab
axtro-rubber-1.0.2.3 generators/vulcanize/templates/mysql/config/rubber/role/db/crontab
axtro-rubber-1.0.2.2 generators/vulcanize/templates/mysql/config/rubber/role/db/crontab
axtro-rubber-1.0.2.1 generators/vulcanize/templates/mysql/config/rubber/role/db/crontab
rubber-1.0.2 generators/vulcanize/templates/mysql/config/rubber/role/db/crontab