diff --git a/examples/kvm-qemu/cube-backup.sh b/examples/kvm-qemu/cube-backup.sh index 34237c2..e414245 100644 --- a/examples/kvm-qemu/cube-backup.sh +++ b/examples/kvm-qemu/cube-backup.sh @@ -1,6 +1,6 @@ #!/usr/bin/env bash -# Script ver 2024110401 +# Script ver 2025022301 #TODO: blockcommit removes current snapshots, even if not done by cube # - it's interesting to make housekeeping, let's make this an option @@ -140,9 +140,9 @@ function run_backup { # Prepare config file rm -f "${NPBACKUP_CONF_FILE}" cp "${NPBACKUP_CONF_FILE_TEMPLATE}" "${NPBACKUP_CONF_FILE}" - sed -i "s%### TENANT ###%${tenant}%g" "${NPBACKUP_CONF_FILE}" - sed -i "s%### SOURCE ###%${BACKUP_FILE_LIST}%g" "${NPBACKUP_CONF_FILE}" - sed -i "s%### VM ###%${vm}%g" "${NPBACKUP_CONF_FILE}" + sed -i "s%___TENANT___%${tenant}%g" "${NPBACKUP_CONF_FILE}" + sed -i "s%___SOURCE___%${BACKUP_FILE_LIST}%g" "${NPBACKUP_CONF_FILE}" + sed -i "s%___VM___%${vm}%g" "${NPBACKUP_CONF_FILE}" "${NPBACKUP_EXECUTABLE}" --config-file "${NPBACKUP_CONF_FILE}" --backup --force >> "$LOG_FILE" 2>&1 if [ $? -ne 0 ]; then diff --git a/examples/kvm-qemu/npbackup-cube.conf.template b/examples/kvm-qemu/npbackup-cube.conf.template index 09f01eb..ef4149d 100644 --- a/examples/kvm-qemu/npbackup-cube.conf.template +++ b/examples/kvm-qemu/npbackup-cube.conf.template @@ -5,11 +5,11 @@ repos: repo_group: default_group backup_opts: paths: - - ### SOURCE ### + - ___SOURCE___ source_type: files_from_verbatim exclude_files_larger_than: 0.0 KiB tags: - - ### VM ### + - ___VM___ repo_opts: repo_password: retention_policy: {} @@ -66,7 +66,7 @@ groups: keep_within: true ntp_server: prometheus: - backup_job: ### VM ### + backup_job: ___VM___ group: ${MACHINE_GROUP} env: env_variables: {} @@ -77,12 +77,12 @@ identity: machine_group: SOME_ARBITRARY_GROUP_NAME global_prometheus: metrics: false - instance: ### VM ### + instance: ___VM___ destination: http_username: http_password: additional_labels: - npf_tenant: ### TENANT ### + npf_tenant: ___TENANT___ backup_type: vm no_cert_verify: true global_options: