diff --git a/.gitignore b/.gitignore index c32b546..e733b47 100644 --- a/.gitignore +++ b/.gitignore @@ -1 +1,2 @@ -*.tar.gz \ No newline at end of file +*.tar.gz +*.tar \ No newline at end of file diff --git a/README.md b/README.md index b01c7f4..921fed4 100644 --- a/README.md +++ b/README.md @@ -5,6 +5,11 @@ This can be used to add a proxy and/or a CA cert to guest clusters automatically **NOTE: when upgrading the Supervisor Cluster it will role the nodes so the image for proxy-inject that is stored on the local registry will be removed. you will need to re-run the install script to re-upload the image otherwise you will get image pull errors** +## Compatibility + +if you are running a supervisor cluster that is `v1.18.2-vsc0.0.6-17224208` or higher please use `1.3.0` and up. if you are only an older version use `1.2.0` + + ## Usage 1. ssh to vcenter and hop into shell diff --git a/build.sh b/build.sh index ba51db9..21ca0e1 100755 --- a/build.sh +++ b/build.sh @@ -1,4 +1,4 @@ #!/bin/bash -docker build -t proxy-inject:1.2.0 . -docker save proxy-inject:1.2.0 | gzip > proxy-inject.tar.gz \ No newline at end of file +docker build -t proxy-inject:1.3.0 . +# docker save proxy-inject:1.3.0 | gzip > proxy-inject.tar.gz \ No newline at end of file diff --git a/install.sh b/install.sh index 5e44028..251b5a6 100755 --- a/install.sh +++ b/install.sh @@ -53,9 +53,11 @@ else fi echo "importing image into local registry" sshpass -p "${sv_pass}" ssh -t -q -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null root@"${ip}" << EOF -docker load -i proxy-inject.tar.gz -docker tag proxy-inject:1.2.0 localhost:5002/vmware/proxy-inject:1.2.0 -docker push localhost:5002/vmware/proxy-inject:1.2.0 +source /etc/profile +gunzip -f proxy-inject.tar.gz +ctr image import proxy-inject.tar +ctr image tag proxy-inject:1.3.0 localhost:5002/vmware/proxy-inject:1.3.0 +ctr image push localhost:5002/vmware/proxy-inject:1.3.0 EOF if [ $? -eq 0 ] ; then @@ -67,6 +69,7 @@ fi echo "cleanup image tar" sshpass -p "${sv_pass}" ssh -t -q -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null root@"${ip}" << EOF rm ./proxy-inject.tar.gz +rm ./proxy-inject.tar EOF ip=$(nextip $ip) success=$((success+1)) diff --git a/manifest-nsxt.yml b/manifest-nsxt.yml index 20cc08e..b429236 100644 --- a/manifest-nsxt.yml +++ b/manifest-nsxt.yml @@ -53,7 +53,7 @@ spec: spec: serviceAccountName: internal-kubectl containers: - - image: docker-registry.kube-system.svc:5000/vmware/proxy-inject:1.2.0 + - image: docker-registry.kube-system.svc:5000/vmware/proxy-inject:1.3.0 imagePullPolicy: Always name: proxy-inject env: diff --git a/manifest-vds.yml b/manifest-vds.yml index 5779826..7be2e7d 100644 --- a/manifest-vds.yml +++ b/manifest-vds.yml @@ -87,7 +87,7 @@ spec: runAsGroup: 1000 fsGroup: 1000 containers: - - image: localhost:5000/vmware/proxy-inject:1.2.0 + - image: localhost:5000/vmware/proxy-inject:1.3.0 imagePullPolicy: Always name: proxy-inject env: