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

Tag input is not supported #160

Closed
maxkruger opened this issue Jul 29, 2021 · 3 comments
Closed

Tag input is not supported #160

maxkruger opened this issue Jul 29, 2021 · 3 comments
Labels
bug Something isn't working

Comments

@maxkruger
Copy link

TL;DR

When using tag input (as listed here), the error below is experienced

Expected behavior
The revision to be tagged with the value supplied

Observed behavior
Warning: Unexpected input(s) 'tag', valid inputs are ['image', 'service', 'region', 'env_vars', 'metadata', 'project_id', 'credentials'] Run google-github-actions/deploy-cloudrun@v0.2.0 with: service: *** image: gcr.io/***/*** credentials: *** tag: 0.1.1-rc.2 env: CLOUDSDK_METRICS_ENVIRONMENT: github-actions-setup-gcloud Setting project Id from credentials Creating a new service... Service *** has been successfully deployed. Error: The operation was canceled.

Reproduction

Action YAML

name: Stage application on Google Cloud Run
on:
  push:
    tags:
    - '*.*.*-rc.*'

jobs:
  deploy:
    name: Deploy job
    runs-on: ubuntu-latest
    steps:
    - name: Checkout the repository
      uses: actions/checkout@v1

    - name: Build Docker image
      run: |
        docker build . --tag eu.gcr.io/${{ secrets.GCLOUD_PROJECT }}/${{ secrets.GCLOUD_APP_NAME }}

    - name: Authenticate into Google Cloud Platform
      uses: google-github-actions/setup-gcloud@master
      with:
        service_account_email: ${{ secrets.GCLOUD_EMAIL }}
        service_account_key: ${{ secrets.GCLOUD_AUTH }}

    - name: Configure Docker to use Google Cloud Platform
      run: "gcloud auth configure-docker --quiet"

    - name: Push image to Google Cloud Container Registry
      run: docker push eu.gcr.io/${{ secrets.GCLOUD_PROJECT }}/${{ secrets.GCLOUD_APP_NAME }}

    - id: get_version
      uses: battila7/get-version-action@v2

    - name: Deploy to Cloud Run
      uses: google-github-actions/deploy-cloudrun@v0.2.0
      with:
        service: ${{ secrets.GCLOUD_APP_NAME }}
        image: gcr.io/${{ secrets.GCLOUD_PROJECT }}/${{ secrets.GCLOUD_APP_NAME }}
        region: ${{ secrets.GCLOUD_REGION }}
        credentials: ${{ secrets.GCLOUD_AUTH }}
        tag: ${{ steps.get_version.outputs.version }}

Repository

Additional information

@maxkruger maxkruger added the bug Something isn't working label Jul 29, 2021
@averikitsch
Copy link
Contributor

hi @maxkruger please update to the latest release google-github-actions/deploy-cloudrun@v0.6.0.

@maxkruger
Copy link
Author

Thanks 👍

@igorkf
Copy link

igorkf commented Aug 18, 2021

Hi, @averikitsch
I tried to run the Github Actions using google-github-actions/deploy-cloudrun@v0.6.0 for setting environment variable with env_vars, but seems that env_vars is being ignored.
I'm doing this as follows:

- name: Deploy to Cloud Run
   id: deploy
   uses: google-github-actions/deploy-cloudrun@v0.6.0
   with:
       service: ${{ env.SERVICE }}
       image: gcr.io/${{ env.PROJECT_ID }}/${{ env.SERVICE }}:${{  github.sha }}
       region: ${{ env.REGION }}
       env_vars: MODE_TOKEN=${{ secrets.MODE_TOKEN }},MODE_PASS=${{ secrets.MODE_PASS }},DISC_WEBHOOK_DATACHANNEL=${{ secrets.DISC_WEBHOOK_DATACHANNEL }}

Am I doing something wrong?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Development

No branches or pull requests

3 participants