Skip to content

Commit

Permalink
fix FreeBSD support for backups
Browse files Browse the repository at this point in the history
  • Loading branch information
fraenki committed Mar 31, 2015
1 parent 5de035c commit a2faed2
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 4 deletions.
2 changes: 1 addition & 1 deletion manifests/backup/mysqlbackup.pp
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
$backupdir,
$backupdirmode = '0700',
$backupdirowner = 'root',
$backupdirgroup = 'root',
$backupdirgroup = $mysql::params::root_group,
$backupcompress = true,
$backuprotate = 30,
$ignore_events = true,
Expand Down
4 changes: 2 additions & 2 deletions manifests/backup/mysqldump.pp
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
$backupdir,
$backupdirmode = '0700',
$backupdirowner = 'root',
$backupdirgroup = 'root',
$backupdirgroup = $mysql::params::root_group,
$backupcompress = true,
$backuprotate = 30,
$ignore_events = true,
Expand Down Expand Up @@ -47,7 +47,7 @@
path => '/usr/local/sbin/mysqlbackup.sh',
mode => '0700',
owner => 'root',
group => 'root',
group => $mysql::params::root_group,
content => template('mysql/mysqlbackup.sh.erb'),
}

Expand Down
2 changes: 1 addition & 1 deletion manifests/backup/xtrabackup.pp
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
$backupmethod = 'mysqldump',
$backupdirmode = '0700',
$backupdirowner = 'root',
$backupdirgroup = 'root',
$backupdirgroup = $mysql::params::root_group,
$backupcompress = true,
$backuprotate = 30,
$ignore_events = true,
Expand Down
6 changes: 6 additions & 0 deletions templates/mysqlbackup.sh.erb
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
<%- if @kernel == 'Linux' -%>
#!/bin/bash
<%- else -%>
#!/bin/sh
<%- end -%>
#
# MySQL Backup Script
# Dumps mysql databases to a file for another backup tool to pick up.
Expand Down Expand Up @@ -27,7 +31,9 @@ PATH=<%= @execpath %>



<%- if @kernel == 'Linux' -%>
set -o pipefail
<%- end -%>

cleanup()
{
Expand Down

0 comments on commit a2faed2

Please sign in to comment.