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

Error: ConfigurationSource cannot be changed from REPOSITORY to API for CREATE_FAILED services. #47

Open
daniel-fulgido opened this issue Oct 23, 2023 · 2 comments

Comments

@daniel-fulgido
Copy link

daniel-fulgido commented Oct 23, 2023

My pipeline is this:

` name: Deploy to App Runner
on:
push:
branches: [main]

jobs:
deploy:
name: Deploy
runs-on: ubuntu-latest

steps:
- name: Checkout
  uses: actions/checkout@v3

- name: Configure AWS credentials
  uses: aws-actions/configure-aws-credentials@v1
  with:
    aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }}
    aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
    aws-region: ${{ secrets.AWS_REGION }}
      
- name: Deploy to App Runner
  id: deploy-apprunner
  uses: awslabs/amazon-app-runner-deploy@main
  env:
    SERVER_PORT: 80
    SECRET_ENV: secret_env
  with:
    service: DEVOPS-NA-INFRA
    source-connection-arn: ${{ secrets.AWS_CONNECTION_SOURCE_ARN }}
    repo: https://github.com/${{ github.repository }}
    branch: ${{ github.ref }}
    runtime: NODEJS_16
    build-command: npm install
    start-command: npm start
    port: 80
    region: ${{ secrets.AWS_REGION }}
    cpu : 1
    memory : 2
    copy-env-vars: |
      SERVER_PORT
    copy-secret-env-vars: |
      SECRET_ENV
  
- name: App Runner URL
  run: echo "App runner URL ${{ steps.deploy-apprunner.outputs.service-url }}" `

I used this blog post as an example: https://aws.amazon.com/pt/blogs/containers/deploy-applications-in-aws-app-runner-with-github-actions/ and it's not working.
My service user has maximum permission to deploy to App Runner

@hariohmprasath
Copy link
Contributor

Hi @daniel-fulgido,
Thanks for reaching out. A few followup questions:

  1. Are you updating an existing service? or creating a new service with the name DEVOPS-NA-INFRA?
  2. Is the creation/update failing with just this github repo? Did you try with any other github repositories?

@valcarcexyz
Copy link
Contributor

valcarcexyz commented May 14, 2024

As a notice, in my case was due to having set the AppRunner instance to configuration through the apprunner.yml, whereas to work with the API, it must be to set up for the be configured through the console or the API

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants