-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
1 changed file
with
9 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -9,10 +9,13 @@ jobs: | |
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v3 | ||
# - name: NO_PROXY workaround | ||
# run: | | ||
# sudo sed -i "s#NO_PROXY.*#NO_PROXY=localhost,127.0.0.1,127.0.0.0/8,10.0.0.0/8,10.130.0.0/16,10.134.248.0/24,192.168.0.0/16,10.152.0.0/16,.jujucharms.com,.svc#g" /etc/environment | ||
# sudo sed -i "s#no_proxy.*#no_proxy=localhost,127.0.0.1,127.0.0.0/8,10.0.0.0/8,10.130.0.0/16,10.134.248.0/24,192.168.0.0/16,10.152.0.0/16,.jujucharms.com,.svc#g" /etc/environment | ||
- name: NO_PROXY workaround | ||
run: | | ||
sudo sed -i "s#NO_PROXY.*#NO_PROXY=localhost,127.0.0.1,127.0.0.0/8,10.0.0.0/8,10.130.0.0/16,10.134.248.0/24,192.168.0.0/16,10.152.0.0/16,.jujucharms.com,.svc#g" /etc/environment | ||
sudo sed -i "s#no_proxy.*#no_proxy=localhost,127.0.0.1,127.0.0.0/8,10.0.0.0/8,10.130.0.0/16,10.134.248.0/24,192.168.0.0/16,10.152.0.0/16,.jujucharms.com,.svc#g" /etc/environment | ||
echo "===========================================================================================================================" | ||
cat /etc/environment | ||
echo "===========================================================================================================================" | ||
- name: Set Environment Variables | ||
uses: tw3lveparsecs/[email protected] | ||
with: | ||
|
@@ -40,14 +43,14 @@ jobs: | |
/usr/bin/bash -c "sudo usermod -a -G snap_microk8s $USER" | ||
/usr/bin/sg snap_microk8s -c "microk8s status --wait-ready" | ||
/usr/bin/sg snap_microk8s -c "sudo microk8s enable hostpath-storage" | ||
/usr/bin/sg snap_microk8s -c "sudo microk8s enable metallb:192.168.1.1-192.168.1.254" | ||
/usr/bin/sg snap_microk8s -c "sudo microk8s enable metallb:10.1.1.1-10.1.1.254" | ||
echo "# Get cluster subnets" | ||
CLUSTER_CIDR=`/usr/bin/sudo cat /var/snap/microk8s/current/args/kube-proxy | grep cluster-cidr | awk -F= '{ print $2 }'` | ||
SERVICE_CLUSTER_IP_RANGE=`/usr/bin/sudo cat /var/snap/microk8s/current/args/kube-apiserver | grep service-cluster-ip-range | awk -F= '{ print $2 }'` | ||
NODE_INTERNAL_IP=`/usr/bin/sudo microk8s kubectl get nodes -o wide | awk '{ print $6 }' | awk 'END{print}'` | ||
KUBERNETES_SERVICE_IP=`/usr/bin/sudo microk8s kubectl -n default get svc | awk '{ print $3 }' | awk 'END{print}'` | ||
JUJU_MODEL_NO_PROXY="${no_proxy//::1,/},$CLUSTER_CIDR,$SERVICE_CLUSTER_IP_RANGE,$NODE_INTERNAL_IP,$KUBERNETES_SERVICE_IP,.local,192.168.0.0/16,172.250.0.0/16" | ||
JUJU_MODEL_NO_PROXY="${no_proxy//::1,/},$CLUSTER_CIDR,$SERVICE_CLUSTER_IP_RANGE,$NODE_INTERNAL_IP,$KUBERNETES_SERVICE_IP,.local,10.0.0.0/8,192.168.0.0/16,172.250.0.0/16" | ||
echo "JUJU_MODEL_NO_PROXY=$JUJU_MODEL_NO_PROXY" | ||
/usr/bin/sudo apt install -yqq libsctp-dev lksctp-tools | ||
echo "================================================================================" | ||
|