Containers changed names

This commit is contained in:
Micke Nordin 2025-02-10 10:25:36 +01:00
parent 602fb12a7f
commit f2774b9c38
Signed by untrusted user: Micke
GPG key ID: 0DA0A7A5708FE257
7 changed files with 9 additions and 9 deletions

View file

@ -213,7 +213,7 @@ MACAddressPolicy=none'
}
# if $nodenumber == '2' {
# cron { 'add_back_bucket_for_karin_nordgren':
# command => '(/usr/local/bin/occ nextcloud-kmh_app_1 files_external:list karin_nordgren@kmh.se && /home/script/bin/create_bucket.sh nextcloud-kmh_app_1 karin_nordgren@kmh.se karin-nordgren-drive-sunet-se) || /bin/true',
# command => '(/usr/local/bin/occ nextcloud-kmh-app-1 files_external:list karin_nordgren@kmh.se && /home/script/bin/create_bucket.sh nextcloud-kmh-app-1 karin_nordgren@kmh.se karin-nordgren-drive-sunet-se) || /bin/true',
# user => 'root',
# minute => '*/10',
# }
@ -222,7 +222,7 @@ MACAddressPolicy=none'
$customer_config_full = hiera_hash($customer)
$customer_config = $customer_config_full[$environment]
cron { "multinode_cron_${customer}":
command => "/opt/nextcloud/cron.sh nextcloud-${customer}_app_1",
command => "/opt/nextcloud/cron.sh nextcloud-${customer}-app-1",
require => File['/opt/nextcloud/cron.sh'],
user => 'root',
minute => '*/10',

View file

@ -388,7 +388,7 @@ class sunetdrive::script (
$singlenodes.each | $singlenode| {
$multinode = hiera_hash('multinode_mapping')[$singlenode]['server']
$multinodeserver = "${multinode}.${site_name}"
$nccontainer = "nextcloud-${singlenode}_app_1"
$nccontainer = "nextcloud-${singlenode}-app-1"
sunet::scriptherder::cronjob { "backup${singlenode}db":
ensure => absent,

View file

@ -5,7 +5,7 @@ shift
include_userbuckets="${1}"
shift
environment="<%= @environment %>"
container="nextcloud-${customer}_app_1"
container="nextcloud-${customer}-app-1"
yq="/usr/local/bin/yq"
if ! [[ -x ${yq} ]]; then

View file

@ -4,7 +4,7 @@ customer="${1}"
multinode="${2}"
environment="<%= @environment %>"
location="${customer}-${environment}"
userjson=$(ssh "script@${multinode}" "sudo /home/script/bin/list_users.sh nextcloud-${customer}_app_1")
userjson=$(ssh "script@${multinode}" "sudo /home/script/bin/list_users.sh nextcloud-${customer}-app-1")
project="statistics"
bucket="drive-server-coms"
base_dir="${project}:${bucket}"

View file

@ -11,7 +11,7 @@ function usage {
exit 1
}
if ! [[ ${container} == 'nextcloud_app_1' ]] && ! [[ ${container} =~ ^nextcloud-[a-z]*_app_1$ ]]; then
if ! [[ ${container} == 'nextcloud_app_1' ]] && ! [[ ${container} =~ ^nextcloud-[a-z]*-app-1$ ]]; then
usage
fi
if ! [[ ${bucket} =~ ^[a-zA-Z0-9]+ ]]; then
@ -26,7 +26,7 @@ echo "$(date): Start executing create_bucket.sh ${1} ${2} ${3}"
rclone_config="/opt/nextcloud/rclone.conf"
if [[ "${container}" != "nextcloud_app_1" ]]; then
customer=$(echo "${container}" | sed -e 's/^nextcloud-//' -e 's/_app_1$//')
customer=$(echo "${container}" | sed -e 's/^nextcloud-//' -e 's/-app-1$//')
rclone_config="/opt/multinode/${customer}/rclone.conf"
fi

View file

@ -9,7 +9,7 @@ function usage {
exit 1
}
if ! [[ ${container} == 'nextcloud_app_1' ]] && ! [[ ${container} =~ ^nextcloud-[a-z]*_app_1$ ]]; then
if ! [[ ${container} == 'nextcloud_app_1' ]] && ! [[ ${container} =~ ^nextcloud-[a-z]*-app-1$ ]]; then
usage
fi

View file

@ -2,7 +2,7 @@
container=${1}
if ! [[ ${container} == 'nextcloud_app_1' ]] && ! [[ ${container} =~ ^nextcloud-[a-z]*_app_1$ ]]; then
if ! [[ ${container} == 'nextcloud_app_1' ]] && ! [[ ${container} =~ ^nextcloud-[a-z]*-app-1$ ]]; then
echo "Usage: ${0} <nextcloud container name>"
echo "Example : ${0} nextcloud_app_1"
exit 1