GoogleCloudPlatform / python-docs-samples

Code samples used on cloud.google.com
Apache License 2.0
7.47k stars 6.45k forks source link

Not able to deploy the app to Google Cloud #11097

Open Akshit-Trivedi-Inferenz opened 10 months ago

Akshit-Trivedi-Inferenz commented 10 months ago

I am facing the error that app.yaml not found, but I have app.yaml in my path. You can see the tree structure of my app.

Expected behavior: Simply I want the django app to deploy to App Engine in GCP.

Observed behavior: Giving this error: Error: google-github-actions/deploy-appengine failed with: deliverable akki_django_app/app.yaml not found or the caller does not have permission, check "working_directory" and "deliverables" inputs: ENOENT: no such file or directory, access 'akki_django_app/app.yaml'

Action YAML:

`name: Deploy to Google App Engine

on: push: branches:

permissions: id-token: write

jobs: deploy: name: Deploy to App Engine runs-on: ubuntu-latest

steps:
- name: Checkout code
  uses: actions/checkout@v2

# - name: Setup Python
#   uses: actions/setup-python@v2
#   with:
#     python-version: 3.8

# - name: Install dependencies
#   run: pip install -r requirements.txt

- name: Print Current Path
  run: pwd

- name: List Files in Directory
  run: ls akki_django_app

- name: List Directory Structure
  run: tree

# - name: Run tests
#   run: python manage.py test

- name: Setup GCP Authentication
  uses: google-github-actions/auth@v0.4.0
  with:
    workload_identity_provider: '' # removed the value intentionally for here
    service_account: '' # removed the value intentionally for here

- name: Deploy to Google App Engine
  uses: google-github-actions/deploy-appengine@v2
  with:
    project_id: nomadic-vehicle-404406
    version: v1
    deliverables: akki_django_app/app.yaml
    working_directory: akki_django_app`

Log output: Run google-github-actions/deploy-appengine@v2 with: project_id: nomadic-vehicle-404406 version: v1 deliverables: akki_django_app/app.yaml working_directory: akki_django_app promote: true env: CLOUDSDK_AUTH_CREDENTIAL_FILE_OVERRIDE: /home/runner/work/_temp/a12af541b0c8fcae27086ed1 GOOGLE_APPLICATION_CREDENTIALS: /home/runner/work/_temp/a12af541b0c8fcae27086ed1 CLOUDSDK_PROJECT: nomadic-vehicle-404406 CLOUDSDK_CORE_PROJECT: nomadic-vehicle-404406 GCP_PROJECT: nomadic-vehicle-404406 GCLOUD_PROJECT: nomadic-vehicle-404406 GOOGLE_CLOUD_PROJECT: nomadic-vehicle-404406 Changing into working directory: akki_django_app Error: google-github-actions/deploy-appengine failed with: deliverable akki_django_app/app.yaml not found or the caller does not have permission, check "working_directory" and "deliverables" inputs: ENOENT: no such file or directory, access 'akki_django_app/app.yaml'

Additional information: this is my Tree Structure: . ├── README.md ├── akki_django_app │ ├── akki_django_app │ │ ├── init.py │ │ ├── pycache │ │ │ ├── init.cpython-310.pyc │ │ │ ├── settings.cpython-310.pyc │ │ │ ├── urls.cpython-310.pyc │ │ │ ├── views.cpython-310.pyc │ │ │ └── wsgi.cpython-310.pyc │ │ ├── asgi.py │ │ ├── settings.py │ │ ├── templates │ │ │ └── index.html │ │ ├── urls.py │ │ ├── views.py │ │ └── wsgi.py │ ├── app.yaml │ ├── db.sqlite3 │ ├── manage.py │ ├── openai_base_client.py │ ├── openai_blacken-docs.py │ └── test_format.py └── requirements.txt

dandhlee commented 10 months ago

@Akshit-Trivedi-Inferenz is this an issue with a file in this repository? Note that this github repository is not for general support for Google Cloud. If you're having an issue with a file in this repository please help tell us which one it is.