-
Notifications
You must be signed in to change notification settings - Fork 82
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add git actions to build multi arch images
- Loading branch information
Showing
17 changed files
with
404 additions
and
44 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 |
---|---|---|
@@ -0,0 +1,41 @@ | ||
name: Build consumerui | ||
|
||
on: | ||
push: | ||
branches: | ||
- "master" | ||
|
||
jobs: | ||
docker: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- | ||
name: Checkout | ||
uses: actions/checkout@v3 | ||
- | ||
name: Set up QEMU | ||
uses: docker/setup-qemu-action@v2 | ||
- | ||
name: Set up Docker Buildx | ||
uses: docker/setup-buildx-action@v2 | ||
- | ||
name: Login to Container Registry | ||
uses: docker/login-action@v2 | ||
with: | ||
registry: ${{ secrets.REGISTRY }} | ||
username: ${{ secrets.REGISTRY_USERNAME }} | ||
password: ${{ secrets.REGISTRY_PASSWORD }} | ||
- | ||
name: Set Version | ||
run: echo "VERSION=$(tail -1 deploy/versions.txt)" >> $GITHUB_ENV | ||
|
||
- | ||
name: Build and push consumerui | ||
uses: docker/build-push-action@v4 | ||
with: | ||
context: . | ||
file: consumerui/Dockerfile | ||
platforms: linux/amd64,linux/arm64 | ||
push: true | ||
tags: | | ||
${{ secrets.REGISTRY }}/${{ secrets.REGISTRY_USERNAME }}/consumerui:latest |
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 |
---|---|---|
@@ -0,0 +1,60 @@ | ||
name: Build deploy utils | ||
|
||
on: | ||
push: | ||
branches: | ||
- "master" | ||
|
||
jobs: | ||
docker: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- | ||
name: Checkout | ||
uses: actions/checkout@v3 | ||
- | ||
name: Set up QEMU | ||
uses: docker/setup-qemu-action@v2 | ||
- | ||
name: Set up Docker Buildx | ||
uses: docker/setup-buildx-action@v2 | ||
- | ||
name: Login to Container Registry | ||
uses: docker/login-action@v2 | ||
with: | ||
registry: ${{ secrets.REGISTRY }} | ||
username: ${{ secrets.REGISTRY_USERNAME }} | ||
password: ${{ secrets.REGISTRY_PASSWORD }} | ||
- | ||
name: Set Version | ||
run: echo "VERSION=$(tail -1 deploy/versions.txt)" >> $GITHUB_ENV | ||
- | ||
name: Build and push webhook-tls-getter | ||
uses: docker/build-push-action@v4 | ||
with: | ||
context: . | ||
file: deploy/Dockerfile | ||
platforms: linux/amd64,linux/arm64 | ||
push: true | ||
tags: | | ||
${{ secrets.REGISTRY }}/${{ secrets.REGISTRY_USERNAME }}/webhook-tls-getter:latest | ||
- | ||
name: Build and push delete-kubeplus-resources | ||
uses: docker/build-push-action@v4 | ||
with: | ||
context: . | ||
file: deploy/Dockerfile.cleanup | ||
platforms: linux/amd64,linux/arm64 | ||
push: true | ||
tags: | | ||
${{ secrets.REGISTRY }}/${{ secrets.REGISTRY_USERNAME }}/delete-kubeplus-resources:latest | ||
- | ||
name: Build and push kubeconfiggenerator | ||
uses: docker/build-push-action@v4 | ||
with: | ||
context: . | ||
file: deploy/Dockerfile.kubeconfiggenerator | ||
platforms: linux/amd64,linux/arm64 | ||
push: true | ||
tags: | | ||
${{ secrets.REGISTRY }}/${{ secrets.REGISTRY_USERNAME }}/kubeconfiggenerator:latest |
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 |
---|---|---|
@@ -0,0 +1,40 @@ | ||
name: Build mutating-webhook-helper | ||
|
||
on: | ||
push: | ||
branches: | ||
- "master" | ||
|
||
jobs: | ||
docker: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- | ||
name: Checkout | ||
uses: actions/checkout@v3 | ||
- | ||
name: Set up QEMU | ||
uses: docker/setup-qemu-action@v2 | ||
- | ||
name: Set up Docker Buildx | ||
uses: docker/setup-buildx-action@v2 | ||
- | ||
name: Login to Container Registry | ||
uses: docker/login-action@v2 | ||
with: | ||
registry: ${{ secrets.REGISTRY }} | ||
username: ${{ secrets.REGISTRY_USERNAME }} | ||
password: ${{ secrets.REGISTRY_PASSWORD }} | ||
- | ||
name: Set Version | ||
run: echo "VERSION=$(tail -1 deploy/versions.txt)" >> $GITHUB_ENV | ||
- | ||
name: Build and push mutating-webhook-helper | ||
uses: docker/build-push-action@v4 | ||
with: | ||
context: . | ||
file: mutating-webhook-helper/Dockerfile | ||
platforms: linux/amd64,linux/arm64 | ||
push: true | ||
tags: | | ||
${{ secrets.REGISTRY }}/${{ secrets.REGISTRY_USERNAME }}/mutating-webhook-helper:latest |
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 |
---|---|---|
@@ -0,0 +1,40 @@ | ||
name: Build mutating-webhook | ||
|
||
on: | ||
push: | ||
branches: | ||
- "master" | ||
|
||
jobs: | ||
docker: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- | ||
name: Checkout | ||
uses: actions/checkout@v3 | ||
- | ||
name: Set up QEMU | ||
uses: docker/setup-qemu-action@v2 | ||
- | ||
name: Set up Docker Buildx | ||
uses: docker/setup-buildx-action@v2 | ||
- | ||
name: Login to Container Registry | ||
uses: docker/login-action@v2 | ||
with: | ||
registry: ${{ secrets.REGISTRY }} | ||
username: ${{ secrets.REGISTRY_USERNAME }} | ||
password: ${{ secrets.REGISTRY_PASSWORD }} | ||
- | ||
name: Set Version | ||
run: echo "VERSION=$(tail -1 deploy/versions.txt)" >> $GITHUB_ENV | ||
- | ||
name: Build and push mutating-webhook | ||
uses: docker/build-push-action@v4 | ||
with: | ||
context: . | ||
file: mutating-webhook/Dockerfile | ||
platforms: linux/amd64,linux/arm64 | ||
push: true | ||
tags: | | ||
${{ secrets.REGISTRY }}/${{ secrets.REGISTRY_USERNAME }}/pac-mutating-admission-webhook:latest |
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 |
---|---|---|
@@ -0,0 +1,50 @@ | ||
name: Build platform-operator and helmer | ||
|
||
on: | ||
push: | ||
branches: | ||
- "master" | ||
|
||
jobs: | ||
docker: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- | ||
name: Checkout | ||
uses: actions/checkout@v3 | ||
- | ||
name: Set up QEMU | ||
uses: docker/setup-qemu-action@v2 | ||
- | ||
name: Set up Docker Buildx | ||
uses: docker/setup-buildx-action@v2 | ||
- | ||
name: Login to Container Registry | ||
uses: docker/login-action@v2 | ||
with: | ||
registry: ${{ secrets.REGISTRY }} | ||
username: ${{ secrets.REGISTRY_USERNAME }} | ||
password: ${{ secrets.REGISTRY_PASSWORD }} | ||
- | ||
name: Set Version | ||
run: echo "VERSION=$(tail -1 deploy/versions.txt)" >> $GITHUB_ENV | ||
- | ||
name: Build and push platform-operator | ||
uses: docker/build-push-action@v4 | ||
with: | ||
context: . | ||
file: platform-operator/artifacts/deployment/Dockerfile | ||
platforms: linux/amd64,linux/arm64 | ||
push: true | ||
tags: | | ||
${{ secrets.REGISTRY }}/${{ secrets.REGISTRY_USERNAME }}/platform-operator:latest | ||
- | ||
name: Build and push helm pod | ||
uses: docker/build-push-action@v4 | ||
with: | ||
context: . | ||
file: platform-operator/helm-pod/Dockerfile | ||
platforms: linux/amd64,linux/arm64 | ||
push: true | ||
tags: | | ||
${{ secrets.REGISTRY }}/${{ secrets.REGISTRY_USERNAME }}/helm-pod:latest |
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
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 |
---|---|---|
@@ -1,10 +1,10 @@ | ||
FROM ubuntu:20.04 | ||
RUN apt-get update && apt-get install -y openssl jq python3 python3-pip && pip3 install pyyaml | ||
ADD webhook-create-self-signed-ca-cert.sh / | ||
COPY kubectl /root/ | ||
COPY kubeplus-non-pod-resources.yaml /root/. | ||
COPY mutatingwebhook.yaml /root/. | ||
RUN apt-get update && apt-get install -y openssl curl jq python3 python3-pip && pip3 install pyyaml | ||
ADD deploy/webhook-create-self-signed-ca-cert.sh / | ||
RUN arch=$(arch | sed s/aarch64/arm64/ | sed s/x86_64/amd64/) && cd /root/ && curl -LO "https://dl.k8s.io/release/v1.26.0/bin/linux/${arch}/kubectl" | ||
COPY deploy/kubeplus-non-pod-resources.yaml /root/. | ||
COPY deploy/mutatingwebhook.yaml /root/. | ||
#COPY webhook-patch-ca-bundle-new.sh /root/. | ||
COPY kubeconfiggenerator.py /root/. | ||
COPY deploy/kubeconfiggenerator.py /root/. | ||
RUN cp /root/kubectl bin/. && chmod +x /root/kubectl && chmod +x bin/kubectl | ||
ENTRYPOINT ["/webhook-create-self-signed-ca-cert.sh"] |
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 |
---|---|---|
@@ -1,6 +1,6 @@ | ||
FROM ubuntu:20.04 | ||
ADD delete-kubeplus-components.sh /root/. | ||
COPY kubectl /root/ | ||
RUN apt-get update && apt-get install -y openssl jq python3 python3-pip && pip3 install pyyaml | ||
ADD deploy/delete-kubeplus-components.sh /root/. | ||
RUN apt-get update && apt-get install -y openssl curl jq python3 python3-pip && pip3 install pyyaml | ||
RUN arch=$(arch | sed s/aarch64/arm64/ | sed s/x86_64/amd64/) && cd /root/ && curl -LO "https://dl.k8s.io/release/v1.26.0/bin/linux/${arch}/kubectl" | ||
RUN cp /root/kubectl bin/. && chmod +x /root/kubectl && chmod +x bin/kubectl | ||
ENTRYPOINT ["/root/delete-kubeplus-components.sh"] |
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 |
---|---|---|
@@ -1,15 +1,19 @@ | ||
FROM ubuntu:20.04 | ||
RUN apt-get update && apt-get install -y openssl jq python3 python3-pip wget && pip3 install pyyaml | ||
COPY kubectl /root/ | ||
COPY helm /root/ | ||
COPY kubeconfiggenerator.py /root/. | ||
COPY kubeconfiggenerator.sh /root/. | ||
ADD requirements.txt /root/requirements.txt | ||
RUN cd /root; pip install -r requirements.txt | ||
RUN apt-get update && apt-get install -y curl wget openssl jq python3 python3-pip && pip3 install pyyaml Flask | ||
RUN arch=$(arch | sed s/aarch64/arm64/ | sed s/x86_64/amd64/) && \ | ||
wget "https://get.helm.sh/helm-v3.11.1-linux-${arch}.tar.gz" && \ | ||
tar xvf "helm-v3.11.1-linux-${arch}.tar.gz" && \ | ||
mv "linux-${arch}/helm" /root/ && rm "helm-v3.11.1-linux-${arch}.tar.gz" && \ | ||
rm -rf "linux-${arch}"/ | ||
RUN arch=$(arch | sed s/aarch64/arm64/ | sed s/x86_64/amd64/) && cd /root/ && curl -LO "https://dl.k8s.io/release/v1.26.0/bin/linux/${arch}/kubectl" | ||
COPY deploy/kubeconfiggenerator.sh /root/. | ||
COPY deploy/kubeconfiggenerator.py /root/. | ||
RUN cp /root/kubectl bin/. && chmod +x /root/kubectl && chmod +x bin/kubectl && chmod +x /root/kubeconfiggenerator.sh && cp /root/helm bin/. && chmod +x /root/helm && chmod +x bin/helm | ||
|
||
#ENTRYPOINT ["/root/kubeconfiggenerator.sh"] | ||
|
||
#ENTRYPOINT ["/root/kubeconfiggenerator.sh"] | ||
|
||
EXPOSE 5005 | ||
CMD ["python3", "/root/kubeconfiggenerator.py"] | ||
|
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 |
---|---|---|
@@ -0,0 +1,49 @@ | ||
{{- define "webhooktlsGetterImage" -}} | ||
{{- $registryName := .Values.webhooktlsGetter.image.registry -}} | ||
{{- $imageName := .Values.webhooktlsGetter.image.repository -}} | ||
{{- $tag := .Values.webhooktlsGetter.image.tag -}} | ||
{{- printf "%s/%s:%s" $registryName $imageName $tag -}} | ||
{{- end -}} | ||
|
||
{{- define "kubeconfiggeneratorImage" -}} | ||
{{- $registryName := .Values.kubeconfiggenerator.image.registry -}} | ||
{{- $imageName := .Values.kubeconfiggenerator.image.repository -}} | ||
{{- $tag := .Values.kubeconfiggenerator.image.tag -}} | ||
{{- printf "%s/%s:%s" $registryName $imageName $tag -}} | ||
{{- end -}} | ||
|
||
{{- define "mutatingAdmissionWebhookImage" -}} | ||
{{- $registryName := .Values.mutatingAdmissionWebhook.image.registry -}} | ||
{{- $imageName := .Values.mutatingAdmissionWebhook.image.repository -}} | ||
{{- $tag := .Values.mutatingAdmissionWebhook.image.tag -}} | ||
{{- printf "%s/%s:%s" $registryName $imageName $tag -}} | ||
{{- end -}} | ||
|
||
{{- define "platformOperatorImage" -}} | ||
{{- $registryName := .Values.platformOperator.image.registry -}} | ||
{{- $imageName := .Values.platformOperator.image.repository -}} | ||
{{- $tag := .Values.platformOperator.image.tag -}} | ||
{{- printf "%s/%s:%s" $registryName $imageName $tag -}} | ||
{{- end -}} | ||
|
||
|
||
{{- define "consumeruiImage" -}} | ||
{{- $registryName := .Values.consumerui.image.registry -}} | ||
{{- $imageName := .Values.consumerui.image.repository -}} | ||
{{- $tag := .Values.consumerui.image.tag -}} | ||
{{- printf "%s/%s:%s" $registryName $imageName $tag -}} | ||
{{- end -}} | ||
|
||
{{- define "helmerImage" -}} | ||
{{- $registryName := .Values.helmer.image.registry -}} | ||
{{- $imageName := .Values.helmer.image.repository -}} | ||
{{- $tag := .Values.helmer.image.tag -}} | ||
{{- printf "%s/%s:%s" $registryName $imageName $tag -}} | ||
{{- end -}} | ||
|
||
{{- define "cleanupKubeplusComponentsImage" -}} | ||
{{- $registryName := .Values.cleanupKubeplusComponents.image.registry -}} | ||
{{- $imageName := .Values.cleanupKubeplusComponents.image.repository -}} | ||
{{- $tag := .Values.cleanupKubeplusComponents.image.tag -}} | ||
{{- printf "%s/%s:%s" $registryName $imageName $tag -}} | ||
{{- end -}} |
Oops, something went wrong.