]> git.pld-linux.org Git - packages/automysqlbackup.git/commitdiff
- new, based from src.rpm: master automysqlbackup-3_0-0_rc6_1
authorElan Ruusamäe <glen@pld-linux.org>
Tue, 20 Mar 2012 10:52:30 +0000 (10:52 +0000)
committercvs2git <feedback@pld-linux.org>
Sun, 24 Jun 2012 12:13:13 +0000 (12:13 +0000)
  http://www.jur-linux.org/rpms/el-updates/6.2/SRPMS/automysqlbackup-3.0-1.07.el6.src.rpm

Changed files:
    automysqlbackup-du.patch -> 1.1
    automysqlbackup-silent.patch -> 1.1
    automysqlbackup.spec -> 1.1

automysqlbackup-du.patch [new file with mode: 0644]
automysqlbackup-silent.patch [new file with mode: 0644]
automysqlbackup.spec [new file with mode: 0644]

diff --git a/automysqlbackup-du.patch b/automysqlbackup-du.patch
new file mode 100644 (file)
index 0000000..a054206
--- /dev/null
@@ -0,0 +1,11 @@
+--- automysqlbackup-v3.0_rc2/automysqlbackup
++++ automysqlbackup-v3.0_rc2/automysqlbackup
+@@ -2039,7 +2039,7 @@ method_backup () {
+       # -> finished information
+       echo "Total disk space used for backup storage..."
+       echo "Size - Location"
+-      echo `du -hsH "${CONFIG_backup_dir}"`
++      echo `du -hs --si "${CONFIG_backup_dir}"`
+       echo
+       echo "======================================================================"
+       # <- finished information
diff --git a/automysqlbackup-silent.patch b/automysqlbackup-silent.patch
new file mode 100644 (file)
index 0000000..fa05c0e
--- /dev/null
@@ -0,0 +1,51 @@
+--- automysqlbackup-v3.0_rc6/automysqlbackup
++++ automysqlbackup-v3.0_rc6/automysqlbackup
+@@ -850,7 +850,6 @@ directory_checks_enable_logging () {
+       [[ "${CONFIG_mysql_dump_dbstatus}" = 'yes' ]] && { checkdirs=( "${checkdirs[@]}" "${CONFIG_backup_dir}/status" ); }
+     tmp_permcheck=0
+-    printf '# Checking for permissions to write to folders:\n'
+     # "dirname ${CONFIG_backup_dir}" exists?
+@@ -873,14 +872,9 @@ directory_checks_enable_logging () {
+     # -> check base folder
+-    printf 'base folder %s ... ' "$(dirname "${CONFIG_backup_dir}")"
+     if [[ -d "$(dirname "${CONFIG_backup_dir}")" ]]; then
+-      printf 'exists ... ok.\n'
+-      printf 'backup folder %s ... ' "${CONFIG_backup_dir}"
+-
+       if [[ -d "${CONFIG_backup_dir}" ]]; then
+-          printf 'exists ... writable? ' 
+           if (( $CONFIG_dryrun )); then
+             printf 'dry-running. Skipping. Logging to /tmp\n'
+             log_file="/tmp/${CONFIG_mysql_dump_host}-`date +%N`.log"
+@@ -889,7 +883,6 @@ directory_checks_enable_logging () {
+             tmp_permcheck=1
+           else
+               if chk_folder_writable "${CONFIG_backup_dir}"; then
+-                printf 'yes. Proceeding.\n'
+                 log_file="${CONFIG_backup_dir}/${CONFIG_mysql_dump_host}-`date +%N`.log"
+                 log_errfile="${CONFIG_backup_dir}/ERRORS_${CONFIG_mysql_dump_host}-`date +%N`.log"
+                 activateIO "$log_file" "$log_errfile"
+@@ -1643,7 +1636,7 @@ method_backup () {
+       load_default_config
+       trap mail_cleanup EXIT SIGHUP SIGINT SIGQUIT SIGTERM
+-      if [[ -r "${CONFIG_configfile}" ]]; then source "${CONFIG_configfile}"; echo "Parsed config file \"${CONFIG_configfile}\""; else let "N |= $N_config_file_missing"; fi; echo
++      if [[ -r "${CONFIG_configfile}" ]]; then source "${CONFIG_configfile}"; else let "N |= $N_config_file_missing"; fi
+       if (( $opt_flag_config_file )); then if [[ -r "${opt_config_file}" ]]; then source "${opt_config_file}"; let "N |= $N_arg_conffile_parsed"; else let "N |= $N_arg_conffile_unreadable"; fi; else let "N |= $N_too_many_args"; fi
+       (( $CONFIG_dryrun )) && {
+@@ -2209,7 +2202,7 @@ NO_ARGS=0
+ E_OPTERROR=85
+ if (( $# == $NO_ARGS )); then   # Script invoked with no command-line args?
+-  echo "Invoking backup method."; echo; method_backup
++  method_backup
+ fi
+ while getopts ":c:blh" Option
diff --git a/automysqlbackup.spec b/automysqlbackup.spec
new file mode 100644 (file)
index 0000000..57d542a
--- /dev/null
@@ -0,0 +1,49 @@
+%define                subver  rc6
+%define                rel             1
+Summary:       Automatic MySQL Backup
+Name:          automysqlbackup
+Version:       3.0
+Release:       0.%{subver}.%{rel}
+License:       GPL v2+
+Group:         Development/Tools
+Source0:       http://downloads.sourceforge.net/automysqlbackup/%{name}-v%{version}_%{subver}.tar.gz
+# Source0-md5: 33db887176f8480a9a9c324f5b718b88
+Patch2:                %{name}-du.patch
+Patch3:                %{name}-silent.patch
+URL:           http://sourceforge.net/projects/automysqlbackup/
+BuildRequires: sed >= 4.0
+BuildArch:     noarch
+BuildRoot:     %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
+
+%description
+AutoMySQLBackup with a basic configuration will create Daily, Weekly
+and Monthly backups of one or more of your MySQL databases from one or
+more of your MySQL servers.
+
+Other Features include:
+- Email notification of backups
+- Backup Compression and Encryption
+- Configurable backup rotation
+- Incremental database backups
+
+%prep
+%setup -q -n %{name}-v%{version}_%{subver}
+%patch2 -p1
+%patch3 -p1
+
+%{__sed} -i -e '1s,#!/usr/bin/env bash,#!/bin/bash,' %{name}
+
+%install
+rm -rf $RPM_BUILD_ROOT
+install -d $RPM_BUILD_ROOT{%{_sysconfdir}/%{name},%{_bindir}}
+cp -p %{name}.conf $RPM_BUILD_ROOT%{_sysconfdir}/%{name}
+install -p %{name} $RPM_BUILD_ROOT%{_bindir}
+
+%clean
+rm -rf $RPM_BUILD_ROOT
+
+%files
+%defattr(644,root,root,755)
+%dir %{_sysconfdir}/%{name}
+%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}/%{name}.conf
+%attr(755,root,root) %{_bindir}/%{name}
This page took 0.07719 seconds and 4 git commands to generate.