Skip to content

Commit 07dd7d2

Browse files
committed
add comment
Signed-off-by: PoAn Yang <[email protected]>
1 parent 96453d3 commit 07dd7d2

File tree

4 files changed

+43
-37
lines changed

4 files changed

+43
-37
lines changed

.github/workflows/rancher-integration.yaml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -92,23 +92,23 @@ jobs:
9292
working-directory: ./ci/terraform
9393
run: |
9494
./cleanup_test_files.sh
95-
- name: Testing existing files
95+
- name: Check files exist on provisioned hosts
9696
working-directory: ./ci/terraform
9797
run: |
9898
./check_files.sh ${{ steps.ipxe.outputs.VAGRANT_HOME }}/settings.yml
99-
- name: Testing services status
99+
- name: Check system services status on provisioned hosts
100100
working-directory: ./ci/terraform
101101
run: |
102102
./check_services_status.sh ${{ steps.ipxe.outputs.VAGRANT_HOME }}/settings.yml
103-
- name: Testing basic operations with terraform
103+
- name: Create Harvester resources for testing
104104
working-directory: ./ci/terraform
105105
run: |
106106
curl https://releases.hashicorp.com/terraform/1.3.7/terraform_1.3.7_linux_amd64.zip -o terraform_bin.zip
107107
unzip -o terraform_bin.zip
108108
./get_kubeconfig.sh ${{ steps.ipxe.outputs.VAGRANT_HOME }}/settings.yml
109109
./terraform init -no-color
110110
./terraform apply -auto-approve -no-color
111-
- name: Test network on the VMs
111+
- name: Test VM networking
112112
working-directory: ./ci/terraform
113113
run: |
114114
./test_terraform_vm.sh ${{ steps.ipxe.outputs.VAGRANT_HOME }}/settings.yml
@@ -141,7 +141,7 @@ jobs:
141141
exit 1
142142
fi
143143
144-
- name: Check rotate RKE2 certificates
144+
- name: Test RKE2 cert rotation
145145
run: |
146146
node0_ip=$(yq e ".harvester_network_config.cluster[0].ip" ${{ steps.ipxe.outputs.VAGRANT_HOME }}/settings.yml)
147147
first_enddate=$(ssh -o "StrictHostKeyChecking no" -i tmp-ssh-key rancher@$node0_ip "openssl x509 -in /var/lib/rancher/rke2/server/tls/serving-kube-apiserver.crt -noout -enddate")

.github/workflows/rancher-upgrade-integration.yaml

Lines changed: 10 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -102,51 +102,29 @@ jobs:
102102
working-directory: ./ci/terraform
103103
run: |
104104
./cleanup_test_files.sh
105-
- name: Testing existing files
105+
- name: Check files exist on provisioned hosts
106106
working-directory: ./ci/terraform
107107
run: |
108108
./check_files.sh ${{ steps.ipxe.outputs.VAGRANT_HOME }}/settings.yml
109-
- name: Testing services status
109+
- name: Check system services status on provisioned hosts
110110
working-directory: ./ci/terraform
111111
run: |
112112
./check_services_status.sh ${{ steps.ipxe.outputs.VAGRANT_HOME }}/settings.yml
113113
114-
- name: Create new-version.yaml
115-
run: |
116-
echo "apiVersion: harvesterhci.io/v1beta1" > new-version.yaml
117-
echo "kind: Version" >> new-version.yaml
118-
echo "metadata:" >> new-version.yaml
119-
echo " name: master-head" >> new-version.yaml
120-
echo " namespace: harvester-system" >> new-version.yaml
121-
echo "spec:" >> new-version.yaml
122-
echo " isoURL: http://localhost:8000/dist/artifacts/harvester-master-amd64.iso" >> new-version.yaml
123-
echo " minUpgradableVersion: v1.3.1" >> new-version.yaml
124-
echo " releaseDate: \"202401231\"" >> new-version.yaml
125-
echo " tags:" >> new-version.yaml
126-
echo " - dev" >> new-version.yaml
127-
echo " - test" >> new-version.yaml
128-
129-
- name: Create new-upgrade.yaml
114+
- name: Start file server
130115
run: |
131-
echo "apiVersion: harvesterhci.io/v1beta1" > new-version.yaml
132-
echo "kind: Upgrade" >> new-version.yaml
133-
echo "metadata:" >> new-version.yaml
134-
echo " name: master-head" >> new-version.yaml
135-
echo " namespace: harvester-system" >> new-version.yaml
136-
echo "spec:" >> new-version.yaml
137-
echo " logEnabled: true" >> new-version.yaml
138-
echo " version: master-head" >> new-version.yaml
116+
python3 -m http.server 8000 --bind 0.0.0.0 &
139117
140-
- name: Apply new-version.yaml
118+
- name: Create new-version.yaml
119+
working-directory: ./ci/upgrade
141120
run: |
121+
./create_version_file.sh
142122
kubectl apply -f new-version.yaml
143123
144-
- name: Start file server
145-
run: |
146-
python3 -m http.server 8000 --bind 0.0.0.0 &
147-
148-
- name: Apply new-upgrade.yaml
124+
- name: Create new-upgrade.yaml
125+
working-directory: ./ci/upgrade
149126
run: |
127+
./create_upgrade_file.sh
150128
kubectl apply -f new-upgrade.yaml
151129
152130
- name: Wait for upgrade to complete

ci/upgrade/create_upgrade_file.sh

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
#!/bin/bash -ex
2+
3+
cat <<EOF > new-upgrade.yaml
4+
apiVersion: harvesterhci.io/v1beta1
5+
kind: Upgrade
6+
metadata:
7+
name: master-head
8+
namespace: harvester-system
9+
spec:
10+
logEnabled: true
11+
version: master-head
12+
EOF

ci/upgrade/create_version_file.sh

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
#!/bin/bash -ex
2+
3+
cat <<EOF > new-version.yaml
4+
apiVersion: harvesterhci.io/v1beta1
5+
kind: Version
6+
metadata:
7+
name: master-head
8+
namespace: harvester-system
9+
spec:
10+
isoURL: http://localhost:8000/dist/artifacts/harvester-master-amd64.iso
11+
minUpgradableVersion: v1.3.1
12+
releaseDate: 202401231
13+
tags:
14+
- dev
15+
- test
16+
EOF

0 commit comments

Comments
 (0)