Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature Request: CroJobs #243

Open
juzerali opened this issue Oct 8, 2022 · 3 comments
Open

Feature Request: CroJobs #243

juzerali opened this issue Oct 8, 2022 · 3 comments
Labels
bug Something isn't working idle Inactive for 14 days

Comments

@juzerali
Copy link

juzerali commented Oct 8, 2022

Feature request

Requesting support for CronJobs. Currently image substitution in CronJobs does not work.

  deploy:
    name: Deploy
    needs: [ build, publish ]
    runs-on: ubuntu-latest
    steps:
      - name: Set the Kubernetes context
        uses: azure/k8s-set-context@v2
        with:
          method: service-account
          k8s-url: https://my-kube-domain
          k8s-secret: ${{ secrets.KUBERNETES_SECRET }}

      - name: Checkout source code
        uses: actions/checkout@v3

      - name: Deploy to the Kubernetes cluster
        uses: azure/k8s-deploy@v1
        with:
          namespace: default
          manifests: |
            kube/cronjob.yml
          images: |
            asia-south1-docker.pkg.dev/project/repo/image:${{ github.sha }}

Expected: CronJob is updated with the new image as per ${{ github.sha }}
Actual: Image name that is hardcoded, gets updated

@OliverMKing
Copy link
Collaborator

I'm going to look into this!

@OliverMKing OliverMKing added the bug Something isn't working label Oct 12, 2022
@OliverMKing
Copy link
Collaborator

You can temporarily use https://github.com/Azure/k8s-artifact-substitute this action to swap images prior to running deploy. It should correctly handle this case. Simply take the output of this action and use that as your manifests input in deploy.

@github-actions
Copy link

This issue is idle because it has been open for 14 days with no activity.

@github-actions github-actions bot added the idle Inactive for 14 days label Oct 31, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working idle Inactive for 14 days
Projects
None yet
Development

No branches or pull requests

2 participants