Clean up OpenEuler mirroring infrastructure

The parent change stopped updating the mirror and deleted the
content. Once it's had a chance to run, this removes all remaining
traces other than the empty AFS volume itself.

Change-Id: I562873779072e0369d9892ccc85558659bf95241
This commit is contained in:
Jeremy Stanley
2025-09-05 18:31:19 +00:00
parent a6c0caa76c
commit df4ed24dea
5 changed files with 7 additions and 56 deletions

View File

@@ -1,47 +0,0 @@
#!/bin/bash -xe
# Copyright 2021 Linaro Limited.
# Copyright 2016 Red Hat, Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License"); you may
# not use this file except in compliance with the License. You may obtain
# a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
# License for the specific language governing permissions and limitations
# under the License.
#
# This references CentOS 7 mirroring part of centos-mirror-update.
source /usr/share/mirror-update/functions.sh
MIRROR_VOLUME=$1
# Runs with timeout under cron
if [[ ${UNDER_CRON:-0} -eq 0 ]]; then
echo_ts "Running interactively"
TIMEOUT=""
set -x
else
TIMEOUT="timeout -k 2m 90m"
fi
BASE="/afs/.openstack.org/mirror/openeuler"
K5START="k5start -t -f /etc/openeuler.keytab service/openeuler-mirror -- $TIMEOUT"
# Cleanup old repos
for REPO in openEuler-24.03-LTS ; do
if [ -d $BASE/$REPO/ ]; then
$K5START rm -rf $BASE/$REPO/
fi
done
date --iso-8601=ns | $K5START tee $BASE/timestamp.txt
echo_ts "rsync completed successfully, running vos release."
vos_release $MIRROR_VOLUME
date --iso-8601=ns
echo_ts "Done."

View File

@@ -17,7 +17,6 @@
- centos-stream
- epel
- fedora
- openeuler
- yum-puppetlabs
- name: Cleanup old unused rsync mirroring scripts
@@ -25,6 +24,7 @@
cleanup_rsync_update_scripts:
- opensuse
- centos
- openeuler
##### Script creation #####

View File

@@ -96,7 +96,6 @@
- epel
- fedora
- logs
- openeuler
- opensuse
- ubuntu
- ubuntu-ports

View File

@@ -16,9 +16,6 @@ mirror_update_keytab_epel: |-
mirror_update_keytab_fedora: |-
aEkRPhZllm2F2y71Zgf3X9NjyHT7/sS8bd/vXt9oG1PKkUmpeBXprFnrxzMuKiupHwwTa09w5LuB
blLvBOC8W5Miz1u6TkRe+/jLQurLpzYHwk3bJCJ6s3WwPKDej54TDVgrVQ==
mirror_update_keytab_openeuler: |-
aEkRPhZllm2F2y71Zgf3X9NjyHT7/sS8bd/vXt9oG1PKkUmpeBXprFnrxzMuKiupHwwTa09w5LuB
blLvBOC8W5Miz1u6TkRe+/jLQurLpzYHwk3bJCJ6s3WwPKDej54TDVgrVQ==
mirror_update_keytab_opensuse: |-
aEkRPhZllm2F2y71Zgf3X9NjyHT7/sS8bd/vXt9oG1PKkUmpeBXprFnrxzMuKiupHwwTa09w5LuB
blLvBOC8W5Miz1u6TkRe+/jLQurLpzYHwk3bJCJ6s3WwPKDej54TDVgrVQ==

View File

@@ -30,13 +30,12 @@ def test_rsync_scripts(host):
for script in ['centos-stream',
'epel',
'fedora',
'openeuler',
'yum-puppetlabs']:
f = host.file('/usr/local/bin/%s-mirror-update' % script)
assert f.exists
def test_rsync_scripts_removed(host):
for script in ['opensuse', 'centos']:
for script in ['opensuse', 'centos', 'openeuler']:
f = host.file('/usr/local/bin/%s-mirror-update' % script)
assert not f.exists
@@ -50,7 +49,6 @@ def test_keytabs(host):
'/etc/centos-stream.keytab',
'/etc/epel.keytab',
'/etc/fedora.keytab',
'/etc/openeuler.keytab',
'/etc/yum-puppetlabs.keytab',
'/etc/reprepro.keytab']:
@@ -60,7 +58,11 @@ def test_keytabs(host):
assert f.mode == 0o400
def test_keytabs_removed(host):
for keytab in ['/etc/opensuse.keytab', '/etc/centos.keytab']:
for keytab in [
'/etc/opensuse.keytab',
'/etc/centos.keytab',
'/etc/openeuler.keytab',
]:
f = host.file(keytab)
assert not f.exists