Update Registry to unpack new repo

This commit is contained in:
Mike Reeves
2020-01-23 10:45:08 -05:00
parent 71edddd846
commit 2c619db6ad
3 changed files with 32 additions and 16 deletions

View File

@@ -457,6 +457,7 @@ docker_registry() {
docker_seed_registry() {
VERSION="HH1.1.4"
TRUSTED_CONTAINERS=( \
"so-acng:$VERSION" \
"so-auth-api:$VERSION" \
"so-auth-ui:$VERSION" \
"so-core:$VERSION" \
@@ -489,22 +490,28 @@ docker_seed_registry() {
"so-wazuh:$VERSION" \
"so-zeek:$VERSION" )
for i in "${TRUSTED_CONTAINERS[@]}"
do
# Pull down the trusted docker image
echo "Downloading $i"
docker pull --disable-content-trust=false docker.io/soshybridhunter/$i
# Tag it with the new registry destination
docker tag soshybridhunter/$i $HOSTNAME:5000/soshybridhunter/$i
docker push $HOSTNAME:5000/soshybridhunter/$i
done
if [ ! -f /nsm/docker-registry/docker/so-dockers-1.1.4.tar ]; then
# Download the container from the interwebs
for i in "${TRUSTED_CONTAINERS[@]}"
do
# Pull down the trusted docker image
echo "Downloading $i"
docker pull --disable-content-trust=false docker.io/soshybridhunter/$i
# Tag it with the new registry destination
docker tag soshybridhunter/$i $HOSTNAME:5000/soshybridhunter/$i
docker push $HOSTNAME:5000/soshybridhunter/$i
done
for i in "${TRUSTED_CONTAINERS[@]}"
do
echo "Removing $i locally"
docker rmi soshybridhunter/$i
done
else
# We already have the goods son
rm /nsm/docker-registry/docker/so-dockers-$VERSION.tar
fi
for i in "${TRUSTED_CONTAINERS[@]}"
do
echo "Removing $i locally"
docker rmi soshybridhunter/$i
done
}
es_heapsize() {