diff --git a/laptop/helm-upgrade.sh b/laptop/helm-upgrade.sh deleted file mode 100755 index 5502f8c..0000000 --- a/laptop/helm-upgrade.sh +++ /dev/null @@ -1,23 +0,0 @@ -#!/usr/bin/env bash - - -# Check if the script received exactly one argument -if [ "$#" -ne 1 ]; then - echo "Usage: $0 filename" - exit 1 -fi - -filename="$1" - -# Check if the file exists -if [ ! -f "$filename" ]; then - echo "Error: File '$filename' does not exist." - exit 1 -fi - -helm upgrade tink-stack -n tink-system -f "$filename" oci://ghcr.io/tinkerbell/charts/stack - -kubectl -n tink-system patch clusterrole smee-role --type='json' -p='[ - {"op": "add", "path": "/rules/0/verbs/-", "value": "create"}, - {"op": "add", "path": "/rules/0/verbs/-", "value": "update"} -]' diff --git a/laptop/setup.sh b/laptop/setup.sh index b97c55d..ad70ff5 100644 --- a/laptop/setup.sh +++ b/laptop/setup.sh @@ -94,12 +94,12 @@ helm_install_tink_stack() { --create-namespace \ --namespace "$namespace" \ --wait \ - --set "smee.trustedProxies=${trusted_proxies}" \ - --set "hegel.trustedProxies=${trusted_proxies}" \ - --set "stack.kubevip.interface=${interface}" \ - --values manifests/proxy-values.yaml \ - --set "stack.loadBalancerIP=${loadbalancer_ip}" \ - --set "smee.publicIP=${loadbalancer_ip}" + --values manifests/proxy-values.yaml + + kubectl -n tink-system patch clusterrole smee-role --type='json' -p='[ + {"op": "add", "path": "/rules/0/verbs/-", "value": "create"}, + {"op": "add", "path": "/rules/0/verbs/-", "value": "update"} + ]' } configure_dnsmasq() { diff --git a/virtual-datacenter/scripts/functions.sh b/virtual-datacenter/scripts/functions.sh index b9aab01..55e1a6c 100644 --- a/virtual-datacenter/scripts/functions.sh +++ b/virtual-datacenter/scripts/functions.sh @@ -48,7 +48,6 @@ curl -sLO https://github.com/konstructio/colony/releases/download/${COLONY_CLI_V export COLONY_API_KEY=$COLONY_API_KEY; \ sudo install -m 0755 ./colony /usr/local/bin/; \ sudo kubectl -n tink-system get secret mgmt-kubeconfig; \ -/home/vagrant/manifests/helm-upgrade.sh /home/vagrant/manifests/proxy-values.yaml; \ echo '------------------------------------'; \ echo 'kubens tink-system'; \ echo 'kubens tink-system' >> ~/.bashrc; \ @@ -62,12 +61,13 @@ echo '------------------------------------'; \ sshCommand=$(civo_get_ssh_command) echo -e "${YELLOW}$sshCommand ${NOCOLOR}" + local branch="main" local fullCommand="$sshCommand -tt 'vagrant plugin list | grep -q vagrant-libvirt || vagrant plugin install vagrant-libvirt; \ curl -sLO https://github.com/konstructio/colony/releases/download/${COLONY_CLI_VERSION}/colony_Linux_x86_64.tar.gz && tar -xvf colony_Linux_x86_64.tar.gz; \ sudo install -m 0755 ./colony /usr/local/bin/; \ sudo systemctl restart libvirtd; \ -git clone https://github.com/konstructio/colony-vagrant.git colony-vagrant; \ +git clone -b $branch https://github.com/konstructio/colony-vagrant.git colony-vagrant; \ cd colony-vagrant; vagrant up spine01 leaf01 exit laptop; vagrant ssh laptop -c \"$vagrantCommand\"; \ vagrant ssh laptop; exec /bin/bash -i'"