fix: update name of function deploying Helm (#319) #161
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
name: Golden image CI | |
on: | |
push: | |
branches: | |
- master | |
paths: | |
- "machine-images/**" | |
repository_dispatch: | |
types: | |
- golden-images-id-comparison | |
workflow_dispatch: | |
permissions: | |
contents: write | |
jobs: | |
golden-image-ci: | |
runs-on: ubuntu-latest | |
permissions: | |
contents: read | |
env: | |
working_dir: machine-images | |
if: | | |
github.event_name == 'push' || | |
(github.event_name == 'repository_dispatch' && github.event.client_payload.unequal_flag == 'true') || | |
github.event_name == 'workflow_dispatch' | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Initialize machine image builder | |
run: packer init ${{ env.working_dir }} | |
- name: Build machine image | |
env: | |
K3S_TOKEN: ${{ secrets.K3S_TOKEN }} | |
OCI_PRIVATE_KEY: ${{ secrets.OCI_PRIVATE_KEY }} | |
OCI_INSTANCES_SSH_PRIVATE_KEY: ${{ secrets.OCI_INSTANCES_SSH_PRIVATE_KEY }} | |
run: | | |
echo -n "${OCI_PRIVATE_KEY}" > certificates/[email protected]_2024-03-02T19_23_13.049Z.pem | |
echo -n "${OCI_INSTANCES_SSH_PRIVATE_KEY}" > certificates/ssh-key-2024-03-16.key | |
packer build ${{ env.working_dir }} | |
- name: Set flag | |
uses: peter-evans/repository-dispatch@v3 | |
with: | |
token: ${{ secrets.PUSH_TOKEN }} | |
repository: hajle-silesia/provisioning | |
event-type: golden-image-ci | |
client-payload: '{"flag": "true"}' |