aws / apprunner-roadmap

This is the public roadmap for AWS App Runner.
https://aws.amazon.com/apprunner/
Other
292 stars 13 forks source link

Deployment Ignoring apprunner.yaml File #240

Closed pihish closed 3 months ago

pihish commented 3 months ago

I have been following this guide to integrate a custom apprunner.yaml file into my Node 18 application. I added apprunner.yaml to the root folder of my ExpressJS repo. The file looks like:

version: 1.0
runtime: nodejs18
build:
  commands:
    build:
      - npm install
    post-build:
      - knex migrate:latest
      - knex seed:run

After adding this to my repo and triggering a build, the App Runner instance deploys without any errors. But when I look at the Postgres instance that's connected to my app, I notice that the migration and seed commands under the post-build section of my apprunner.yaml file did not run.

Looking through the deployment logs, I also don't see any mention of the post-build commands of knex migrate:latest or knex seed:run. There are also no errors reported in the logs.

It seems like App Runner is ignoring the apprunner.yaml file in my repo. Is there another step that needs to be taken into account to get it to use the apprunner.yaml file?