Skip to content

Commit

Permalink
fixed recent updates/formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
zackbradys committed Oct 22, 2024
1 parent 7d51bda commit 3eac851
Showing 1 changed file with 21 additions and 7 deletions.
28 changes: 21 additions & 7 deletions .github/workflows/main.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -375,10 +375,10 @@ jobs:
- name: Fetch/Build Harvester
run: |
cd hauler/harvester && source ~/.bashrc
sed -e 's#quay.io/##g' -e 's#ghcr.io/##g' -e 's#registry.k8s.io/##g' -e 's#registry.suse.com/##g' rancher-airgap-harvester.yaml > rancher-airgap-harvester-amd64.yaml
sed -e 's#quay.io/##g' -e 's#ghcr.io/##g' -e 's#registry.k8s.io/##g' -e 's#registry.suse.com/##g' rancher-airgap-harvester.yaml > rancher-airgap-harvester-arm64.yaml
sed -i "1,/---/c\apiVersion: content.hauler.cattle.io/v1alpha1\nkind: Images\nmetadata:\n name: rancher-airgap-images-harvester\nspec:\n images:\n - name: ${Registry}/carbide/harvester/harvester-v1.3.2-carbide-2-amd64.iso:v1.3.2-carbide-2\n - name: ${Registry}/carbide/harvester/harvester-v1.3.2-carbide-2-amd64-net-install.iso:v1.3.2-carbide-2\n - name: ${Registry}/carbide/harvester/harvester-v1.3.2-carbide-2-vmlinuz-amd64:v1.3.2-carbide-2\n - name: ${Registry}/carbide/harvester/harvester-v1.3.2-carbide-2-initrd-amd64:v1.3.2-carbide-2\n - name: ${Registry}/carbide/harvester/harvester-v1.3.2-carbide-2-rootfs-amd64.squashfs:v1.3.2-carbide-2\n - name: ${Registry}/carbide/harvester/harvester-v1.3.2-carbide-2-amd64.sha512:v1.3.2-carbide-2\n---" rancher-airgap-harvester-amd64.yaml
sed -i "1,/---/c\apiVersion: content.hauler.cattle.io/v1alpha1\nkind: Images\nmetadata:\n name: rancher-airgap-images-harvester\nspec:\n images:\n - name: ${Registry}/carbide/harvester/harvester-v1.3.2-carbide-2-arm64.iso:v1.3.2-carbide-2\n - name: ${Registry}/carbide/harvester/harvester-v1.3.2-carbide-2-vmlinuz-arm64:v1.3.2-carbide-2\n - name: ${Registry}/carbide/harvester/harvester-v1.3.2-carbide-2-initrd-arm64:v1.3.2-carbide-2\n - name: ${Registry}/carbide/harvester/harvester-v1.3.2-carbide-2-rootfs-arm64.squashfs:v1.3.2-carbide-2\n - name: ${Registry}/carbide/harvester/harvester-v1.3.2-carbide-2-arm64.sha512:v1.3.2-carbide-2\n---" rancher-airgap-harvester-arm64.yaml
sed -e "s#quay.io/##g" -e "s#ghcr.io/##g" -e "s#registry.k8s.io/##g" -e "s#registry.suse.com/##g" rancher-airgap-harvester.yaml > rancher-airgap-harvester-amd64.yaml
sed -e "s#quay.io/##g" -e "s#ghcr.io/##g" -e "s#registry.k8s.io/##g" -e "s#registry.suse.com/##g" rancher-airgap-harvester.yaml > rancher-airgap-harvester-arm64.yaml
sed -i "1,/---/c\apiVersion: content.hauler.cattle.io/v1alpha1\nkind: Images\nmetadata:\n name: rancher-airgap-images-harvester\nspec:\n images:\n - name: ${Registry}/carbide/harvester/harvester-v1.3.2-govt.1-amd64.iso:v1.3.2-govt.1\n - name: ${Registry}/carbide/harvester/harvester-v1.3.2-govt.1-amd64-net-install.iso:v1.3.2-govt.1\n - name: ${Registry}/carbide/harvester/harvester-v1.3.2-govt.1-vmlinuz-amd64:v1.3.2-govt.1\n - name: ${Registry}/carbide/harvester/harvester-v1.3.2-govt.1-initrd-amd64:v1.3.2-govt.1\n - name: ${Registry}/carbide/harvester/harvester-v1.3.2-govt.1-rootfs-amd64.squashfs:v1.3.2-govt.1\n - name: ${Registry}/carbide/harvester/harvester-v1.3.2-govt.1-amd64.sha512:v1.3.2-govt.1\n---" rancher-airgap-harvester-amd64.yaml
sed -i "1,/---/c\apiVersion: content.hauler.cattle.io/v1alpha1\nkind: Images\nmetadata:\n name: rancher-airgap-images-harvester\nspec:\n images:\n - name: ${Registry}/carbide/harvester/harvester-v1.3.2-govt.1-arm64.iso:v1.3.2-govt.1\n - name: ${Registry}/carbide/harvester/harvester-v1.3.2-govt.1-vmlinuz-arm64:v1.3.2-govt.1\n - name: ${Registry}/carbide/harvester/harvester-v1.3.2-govt.1-initrd-arm64:v1.3.2-govt.1\n - name: ${Registry}/carbide/harvester/harvester-v1.3.2-govt.1-rootfs-arm64.squashfs:v1.3.2-govt.1\n - name: ${Registry}/carbide/harvester/harvester-v1.3.2-govt.1-arm64.sha512:v1.3.2-govt.1\n---" rancher-airgap-harvester-arm64.yaml
time hauler store sync --store amd64 --registry ${Registry} --key ../../carbide-key.pub --platform linux/amd64 --files rancher-airgap-harvester-amd64.yaml
time hauler store sync --store arm64 --registry ${Registry} --key ../../carbide-key.pub --platform linux/arm64 --files rancher-airgap-harvester-arm64.yaml
time hauler store save --store amd64 --platform linux/amd64 --filename harvester-carbide-amd64.tar.zst
Expand Down Expand Up @@ -420,8 +420,9 @@ jobs:
run: |
mkdir -p hauler/carbide && cd hauler/carbide && source ~/.bashrc
echo -e "apiVersion: content.hauler.cattle.io/v1alpha1\nkind: Images\nmetadata:\n name: carbide-images\nspec:\n images:\n$(curl -sfL https://raw.githubusercontent.com/rancherfederal/carbide-releases/main/carbide-images.txt | sed '/nats/d' | sed 's/^/ - name: /')" > carbide-images.yaml
sed -i "s/rgcrprod.azurecr.us/registry.ranchercarbide.dev/g" carbide-images.yaml
echo -e "apiVersion: content.hauler.cattle.io/v1alpha1\nkind: Images\nmetadata:\n name: carbide-dependency-images\nspec:\n images:\n$(curl -sfL https://raw.githubusercontent.com/rancherfederal/carbide-releases/main/carbide-images.txt | sed '/rgcr/d' | sed 's/^/ - name: /')" > carbide-dependency-images.yaml
echo -e "apiVersion: content.hauler.cattle.io/v1alpha1\nkind: Charts\nmetadata:\n name: carbide-charts\nspec:\n charts:\n - name: airgapped-docs\n repoURL: https://rancherfederal.github.io/carbide-charts\n version: 0.1.51\n - name: stigatron\n repoURL: https://rancherfederal.github.io/carbide-charts\n version: 0.3.0\n - name: stigatron-ui\n repoURL: https://rancherfederal.github.io/carbide-charts\n version: 0.2.3\n---\napiVersion: content.hauler.cattle.io/v1alpha1\nkind: Charts\nmetadata:\n name: carbide-dependency-charts\nspec:\n charts:\n - name: heimdall2\n repoURL: https://rancherfederal.github.io/carbide-charts\n version: 0.1.45\n - name: nats\n repoURL: https://nats-io.github.io/k8s/helm/charts\n version: 1.1.5" > carbide-charts.yaml
echo -e "apiVersion: content.hauler.cattle.io/v1alpha1\nkind: Charts\nmetadata:\n name: carbide-charts\nspec:\n charts:\n - name: rancher\n repoURL: https://rancherfederal.github.io/carbide-charts\n version: 2.9.2\n - name: airgapped-docs\n repoURL: https://rancherfederal.github.io/carbide-charts\n version: 0.1.52\n - name: stigatron\n repoURL: https://rancherfederal.github.io/carbide-charts\n version: 0.3.0\n - name: stigatron-ui\n repoURL: https://rancherfederal.github.io/carbide-charts\n version: 0.3.0\n---\napiVersion: content.hauler.cattle.io/v1alpha1\nkind: Charts\nmetadata:\n name: carbide-dependency-charts\nspec:\n charts:\n - name: heimdall2\n repoURL: https://rancherfederal.github.io/carbide-charts\n version: 0.1.45\n - name: nats\n repoURL: https://nats-io.github.io/k8s/helm/charts\n version: 1.1.5" > carbide-charts.yaml
time hauler store sync --store amd64 --key ../../carbide-key.pub --platform linux/amd64 --files carbide-images.yaml
time hauler store sync --store arm64 --key ../../carbide-key.pub --platform linux/arm64 --files carbide-images.yaml
time hauler store sync --store amd64 --platform linux/amd64 --files carbide-dependency-images.yaml
Expand Down Expand Up @@ -452,6 +453,7 @@ jobs:
done
time tar --zstd -cvf hauler-binaries.tar.zst ./*_checksums.txt */
time aws s3 cp --no-progress hauler-binaries.tar.zst s3://carbide/${{ github.ref_name }}/
time 7z a -v999m hauler-binaries.tar hauler-binaries.tar.zst
time for file in hauler-binaries.tar.0*; do
aws s3 cp --no-progress "$file" s3://carbide/${{ github.ref_name }}/spilts/
Expand Down Expand Up @@ -494,6 +496,7 @@ jobs:
cd hauler/rancher && source ~/.bashrc
time aws s3 cp --no-progress rancher-carbide-amd64.tar.zst s3://carbide/${{ github.ref_name }}/
time aws s3 cp --no-progress rancher-carbide-arm64.tar.zst s3://carbide/${{ github.ref_name }}/
time 7z a -v999m rancher-carbide-amd64.tar rancher-carbide-amd64.tar.zst
time for file in rancher-carbide-amd64.tar.0*; do
aws s3 cp --no-progress "$file" s3://carbide/${{ github.ref_name }}/spilts/
Expand All @@ -508,6 +511,7 @@ jobs:
cd hauler/rancher && source ~/.bashrc
time aws s3 cp --no-progress rancher-minimal-carbide-amd64.tar.zst s3://carbide/${{ github.ref_name }}/
time aws s3 cp --no-progress rancher-minimal-carbide-arm64.tar.zst s3://carbide/${{ github.ref_name }}/
time 7z a -v999m rancher-minimal-carbide-amd64.tar rancher-minimal-carbide-amd64.tar.zst
time for file in rancher-minimal-carbide-amd64.tar.0*; do
aws s3 cp --no-progress "$file" s3://carbide/${{ github.ref_name }}/spilts/
Expand All @@ -522,6 +526,7 @@ jobs:
cd hauler/longhorn && source ~/.bashrc
time aws s3 cp --no-progress longhorn-carbide-amd64.tar.zst s3://carbide/${{ github.ref_name }}/
time aws s3 cp --no-progress longhorn-carbide-arm64.tar.zst s3://carbide/${{ github.ref_name }}/
time 7z a -v999m longhorn-carbide-amd64.tar longhorn-carbide-amd64.tar.zst
time for file in longhorn-carbide-amd64.tar.0*; do
aws s3 cp --no-progress "$file" s3://carbide/${{ github.ref_name }}/spilts/
Expand All @@ -536,6 +541,7 @@ jobs:
cd hauler/neuvector && source ~/.bashrc
time aws s3 cp --no-progress neuvector-carbide-amd64.tar.zst s3://carbide/${{ github.ref_name }}/
time aws s3 cp --no-progress neuvector-carbide-arm64.tar.zst s3://carbide/${{ github.ref_name }}/
time 7z a -v999m neuvector-carbide-amd64.tar neuvector-carbide-amd64.tar.zst
time for file in neuvector-carbide-amd64.tar.0*; do
aws s3 cp --no-progress "$file" s3://carbide/${{ github.ref_name }}/spilts/
Expand All @@ -550,6 +556,7 @@ jobs:
cd hauler/harvester && source ~/.bashrc
time aws s3 cp --no-progress harvester-carbide-amd64.tar.zst s3://carbide/${{ github.ref_name }}/
time aws s3 cp --no-progress harvester-carbide-arm64.tar.zst s3://carbide/${{ github.ref_name }}/
time 7z a -v999m harvester-carbide-amd64.tar harvester-carbide-amd64.tar.zst
time for file in harvester-carbide-amd64.tar.0*; do
aws s3 cp --no-progress "$file" s3://carbide/${{ github.ref_name }}/spilts/
Expand All @@ -558,9 +565,15 @@ jobs:
time for file in harvester-carbide-arm64.tar.0*; do
aws s3 cp --no-progress "$file" s3://carbide/${{ github.ref_name }}/spilts/
done
time hauler store extract ${Registry}/carbide/harvester/harvester-v1.3.2-govt.1-amd64.iso:v1.3.2-govt.1
time 7z a -v999m harvester-v1.3.2-carbide-2-amd64.iso.tar harvester-v1.3.2-carbide-2-amd64.iso
time for file in harvester-v1.3.2-carbide-2-amd64.iso.tar.0*; do
time 7z a -v999m harvester-v1.3.2-carbide-amd64.iso.tar harvester-v1.3.2-carbide-2-amd64.iso
time for file in harvester-v1.3.2-carbide-amd64.iso.tar.0*; do
aws s3 cp --no-progress "$file" s3://carbide/${{ github.ref_name }}/spilts/
done
time hauler store extract ${Registry}/carbide/harvester/harvester-v1.3.2-govt.1-arm64.iso:v1.3.2-govt.1
time 7z a -v999m harvester-v1.3.2-carbide-arm64.iso.tar harvester-v1.3.2-carbide-2-arm64.iso
time for file in harvester-v1.3.2-carbide-arm64.iso.tar.0*; do
aws s3 cp --no-progress "$file" s3://carbide/${{ github.ref_name }}/spilts/
done
Expand All @@ -587,6 +600,7 @@ jobs:
cd hauler/carbide && source ~/.bashrc
time aws s3 cp --no-progress carbide-carbide-amd64.tar.zst s3://carbide/${{ github.ref_name }}/
time aws s3 cp --no-progress carbide-carbide-arm64.tar.zst s3://carbide/${{ github.ref_name }}/
time 7z a -v999m carbide-carbide-amd64.tar carbide-carbide-amd64.tar.zst
time for file in carbide-carbide-amd64.tar.0*; do
aws s3 cp --no-progress "$file" s3://carbide/${{ github.ref_name }}/spilts/
Expand Down

0 comments on commit 3eac851

Please sign in to comment.