Skip to content

Commit 4b2c864

Browse files
authored
Merge pull request #118 from mhjacks/main
Branch v1.4 to-be
2 parents 198e792 + c85b811 commit 4b2c864

File tree

114 files changed

+13883
-1509
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

114 files changed

+13883
-1509
lines changed

Changes.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,8 +43,10 @@
4343
* Update platform level override using new templated valuefile name feature in common
4444
* Skip multicloud gateway (noobaa) installation in ODF by default
4545

46-
## Changes in main (July 25, 2024)
46+
## Changes for v1.4 (July 29, 2024)
4747

4848
* Introduce clean-golden-images job to imperative. This is a workaround for a bug in CNV 4.15/ODF 4.15 where if the default StorageClass is not the same as the default virtualization storage class, CNV cannot properly provision datavolumes.
4949
* Default storageclass for edge-gitops-vms to "ocs-storagecluster-ceph-rbd-virtualization", available since ODF 4.14.
5050
* Use api_version for Route queries when discovering credentials for AAP instance.
51+
* Update common.
52+
* Update deploy_kubevirt_worker.yml Ansible playbook to copy securityGroups and blockDevices config from first machineSet. Tag naming schemes changed from OCP 4.15 to 4.16; this method ensures forward and backward compatibility.

ansible/deploy_kubevirt_worker.yml

Lines changed: 3 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -7,11 +7,6 @@
77
gather_facts: false
88
vars:
99
kubeconfig: "{{ lookup('env', 'KUBECONFIG') }}"
10-
machineset_blockdevices:
11-
- ebs:
12-
iops: 0
13-
volumeSize: 120
14-
volumeType: gp2
1510
machineset_instance_type: m5.metal
1611
machineset_machine_role: worker
1712
machineset_machine_type: worker
@@ -47,6 +42,8 @@
4742
machineset_ami_id: "{{ cluster_machinesets.resources[0].spec.template.spec.providerSpec.value.ami.id }}"
4843
machineset_subnet: "{{ cluster_machinesets.resources[0].spec.template.spec.providerSpec.value.subnet.filters[0]['values'][0] }}"
4944
machineset_tags: "{{ cluster_machinesets.resources[0].spec.template.spec.providerSpec.value.tags }}"
45+
machineset_blockdevices: "{{ cluster_machinesets.resources[0].spec.template.spec.providerSpec.value.blockDevices }}"
46+
machineset_securitygroups: "{{ cluster_machinesets.resources[0].spec.template.spec.providerSpec.value.securityGroups }}"
5047
machineset_zone: "{{ cluster_machinesets.resources[0].spec.template.spec.providerSpec.value.placement.availabilityZone }}"
5148
infrastructure_name: "{{ cluster_info.resources[0].status.infrastructureName }}"
5249
infrastructure_region: "{{ cluster_info.resources[0].status.platformStatus.aws.region }}"
@@ -97,11 +94,7 @@
9794
placement:
9895
availabilityZone: "{{ machineset_zone }}"
9996
region: "{{ infrastructure_region }}"
100-
securityGroups:
101-
- filters:
102-
- name: tag:Name
103-
values:
104-
- "{{ infrastructure_name }}-worker-sg"
97+
securityGroups: {{ machineset_securitygroups }}
10598
subnet:
10699
filters:
107100
- name: tag:Name

charts/hub/edge-gitops-vms/templates/job-waitForMetalNode.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ spec:
1818
while [ 1 ];
1919
do
2020
nodes=$(oc get machineset -n openshift-machine-api -l 'edge-gitops-role=kubevirt-worker' -o jsonpath='{.items[*].status.availableReplicas}')
21-
if [ "$nodes" -ge "1" ]; then
21+
if [ "0$nodes" -ge "1" ]; then
2222
echo "Node is ready, exiting"
2323
exit 0
2424
fi

common/.github/workflows/chart-branches.yml

Lines changed: 5 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -49,9 +49,7 @@ jobs:
4949
5050
acm:
5151
needs: changes
52-
if: |
53-
${{ needs.changes.outputs.acm == 'true' }} &&
54-
github.repository == 'validatedpatterns/common'
52+
if: ${{ (needs.changes.outputs.acm == 'true') && (github.repository == 'validatedpatterns/common') }}
5553
uses: validatedpatterns/common/.github/workflows/chart-split.yml@main
5654
permissions:
5755
actions: write
@@ -63,9 +61,7 @@ jobs:
6361

6462
golang-external-secrets:
6563
needs: changes
66-
if: |
67-
${{ needs.changes.outputs.golang-external-secrets == 'true' }} &&
68-
github.repository == 'validatedpatterns/common'
64+
if: ${{ (needs.changes.outputs.golang-external-secrets == 'true') && (github.repository == 'validatedpatterns/common') }}
6965
uses: validatedpatterns/common/.github/workflows/chart-split.yml@main
7066
permissions:
7167
actions: write
@@ -77,9 +73,7 @@ jobs:
7773

7874
hashicorp-vault:
7975
needs: changes
80-
if: |
81-
${{ needs.changes.outputs.hashicorp-vault == 'true' }} &&
82-
github.repository == 'validatedpatterns/common'
76+
if: ${{ (needs.changes.outputs.hashicorp-vault == 'true') && (github.repository == 'validatedpatterns/common') }}
8377
uses: validatedpatterns/common/.github/workflows/chart-split.yml@main
8478
permissions:
8579
actions: write
@@ -91,9 +85,7 @@ jobs:
9185

9286
letsencrypt:
9387
needs: changes
94-
if: |
95-
${{ needs.changes.outputs.letsencrypt == 'true' }} &&
96-
github.repository == 'validatedpatterns/common'
88+
if: ${{ (needs.changes.outputs.letsencrypt == 'true') && (github.repository == 'validatedpatterns/common') }}
9789
uses: validatedpatterns/common/.github/workflows/chart-split.yml@main
9890
permissions:
9991
actions: write
@@ -105,9 +97,7 @@ jobs:
10597

10698
clustergroup:
10799
needs: changes
108-
if: |
109-
${{ needs.changes.outputs.clustergroup == 'true' }} &&
110-
github.repository == 'validatedpatterns/common'
100+
if: ${{ (needs.changes.outputs.clustergroup == 'true') && (github.repository == 'validatedpatterns/common') }}
111101
uses: validatedpatterns/common/.github/workflows/chart-split.yml@main
112102
permissions:
113103
actions: write

common/.github/workflows/chart-split.yml

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,8 +31,12 @@ jobs:
3131
set -e
3232
N="${{ inputs.chart_name }}"
3333
B="${N}-main-single-chart"
34+
GITIMG="quay.io/hybridcloudpatterns/gitsubtree-container:2.40.1"
35+
sudo apt-get update -y && sudo apt-get install -y podman
36+
echo "Running subtree split for ${B}"
37+
podman pull "${GITIMG}"
3438
git push origin -d "${B}" || /bin/true
35-
git subtree split -P "${N}" -b "${B}"
36-
git push -f -u origin "${B}"
39+
# Git subtree got broken on recent versions of git hence this container
40+
podman run --net=host --rm -t -v .:/git "${GITIMG}" subtree split -P "${N}" -b "${B}"
3741
#git clone https://validatedpatterns:${GITHUB_TOKEN}@github.com/validatedpatterns/common.git -b "acm-main-single-chart" --single-branch
3842
git push --force https://validatedpatterns:"${GITHUB_TOKEN}"@github.com/${{ inputs.target_repository }}.git "${B}:main"

common/.github/workflows/linter.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ jobs:
3636
- name: Setup helm
3737
uses: azure/setup-helm@v4
3838
with:
39-
version: 'v3.13.2'
39+
version: 'v3.14.0'
4040

4141

4242
################################

common/.github/workflows/superlinter.yml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,16 +21,19 @@ jobs:
2121
# Run Linter against code base #
2222
################################
2323
- name: Lint Code Base
24-
uses: github/super-linter/slim@v5
24+
uses: github/super-linter/slim@v6
2525
env:
2626
VALIDATE_ALL_CODEBASE: true
2727
DEFAULT_BRANCH: main
2828
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
2929
# These are the validation we disable atm
3030
VALIDATE_ANSIBLE: false
3131
VALIDATE_BASH: false
32+
VALIDATE_CHECKOV: false
3233
VALIDATE_JSCPD: false
3334
VALIDATE_KUBERNETES_KUBECONFORM: false
35+
VALIDATE_PYTHON_PYLINT: false
36+
VALIDATE_SHELL_SHFMT: false
3437
VALIDATE_YAML: false
3538
# VALIDATE_DOCKERFILE_HADOLINT: false
3639
# VALIDATE_MARKDOWN: false

common/Makefile

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -230,17 +230,20 @@ kubeconform: ## run helm kubeconform
230230
super-linter: ## Runs super linter locally
231231
rm -rf .mypy_cache
232232
podman run -e RUN_LOCAL=true -e USE_FIND_ALGORITHM=true \
233+
-e VALIDATE_ANSIBLE=false \
233234
-e VALIDATE_BASH=false \
235+
-e VALIDATE_CHECKOV=false \
236+
-e VALIDATE_DOCKERFILE_HADOLINT=false \
234237
-e VALIDATE_JSCPD=false \
235238
-e VALIDATE_KUBERNETES_KUBECONFORM=false \
236-
-e VALIDATE_YAML=false \
237-
-e VALIDATE_ANSIBLE=false \
238-
-e VALIDATE_DOCKERFILE_HADOLINT=false \
239+
-e VALIDATE_PYTHON_PYLINT=false \
240+
-e VALIDATE_SHELL_SHFMT=false \
239241
-e VALIDATE_TEKTON=false \
242+
-e VALIDATE_YAML=false \
240243
$(DISABLE_LINTERS) \
241244
-v $(PWD):/tmp/lint:rw,z \
242245
-w /tmp/lint \
243-
docker.io/github/super-linter:slim-v5
246+
ghcr.io/super-linter/super-linter:slim-v6
244247

245248
.PHONY: ansible-lint
246249
ansible-lint: ## run ansible lint on ansible/ folder

common/acm/Chart.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,4 +3,4 @@ description: A Helm chart to configure Advanced Cluster Manager for OpenShift.
33
keywords:
44
- pattern
55
name: acm
6-
version: 0.0.1
6+
version: 0.1.0

common/acm/README.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
# Validated Patterns ACM chart
2+
3+
This chart is used to set up ACM in [Validated Patterns](https://validatedpatterns.io)
4+
5+
Please send PRs [here](https://github.com/validatedpatterns/common)

0 commit comments

Comments
 (0)