dhollerbach / actions.serverless-with-python-requirements

Installs Serverless and runs a deploy using the serverless-python-requirements plugin
23 stars 32 forks source link

working-directory #10

Closed craig-dae closed 3 years ago

craig-dae commented 4 years ago

Is there a way to do this with a working-directory option? Our serverless.yml is not in the root of the project.

dhollerbach commented 3 years ago

I'm sure that could be added, though it is certainly easiest to have your serverless.yml at your root level if possible.

clarencenpy commented 3 years ago

@craig-dae As a workaround, you could specify the location of your serverless.yml file using --config flag.

- name: Serverless Deploy
  uses: dhollerbach/github-action-serverless-with-python-requirements@master
  with:
    args: "--stage dev --config path/to/your/serverless.yml"
  env:
    AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
    AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}