Skip to content

Commit

Permalink
fix: ajusta pipeline
Browse files Browse the repository at this point in the history
  • Loading branch information
nathansouzaa3 committed Oct 8, 2024
1 parent 6913580 commit 9bf16c7
Showing 1 changed file with 25 additions and 22 deletions.
47 changes: 25 additions & 22 deletions .github/workflows/pipeline_deploy_lambda.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,25 +15,28 @@ jobs:
runs-on: ubuntu-latest

steps:
- name: Check out code
uses: actions/checkout@v4

- name: Set up Terraform
uses: hashicorp/setup-terraform@v3

- name: Configure AWS Credentials
uses: aws-actions/configure-aws-credentials@v4
with:
role-to-assume: "arn:aws:iam::340752815603:role/oidc-github-framework-eml-role"
role-session-name: GitHub_to_AWS_via_FederatedOIDC
aws-region: "us-east-1"

- name: Login to Amazon ECR
id: login-ecr
uses: aws-actions/amazon-ecr-login@v2

- name: Run Terraform init
run: |
cd deployment/lambda/terraform-lambda
terraform init
terraform plan
- name: Check out code
uses: actions/checkout@v4
with:
ref: ${{ github.ref }}

- name: Set up Terraform
uses: hashicorp/setup-terraform@v3
with:
terraform_version: 1.8.0

- name: Configure AWS Credentials
uses: aws-actions/configure-aws-credentials@v4
with:
role-to-assume: "arn:aws:iam::340752815603:role/oidc-github-framework-eml-role"
role-session-name: GitHub_to_AWS_via_FederatedOIDC
aws-region: ${{ env.AWS_REGION }}

- name: Create ECR
run: |
chmod +x deployment/scripts/create_ecr.sh
./deployment/scripts/create_ecr.sh ${{ env.REPO_NAME }} ${{ env.AWS_REGION }}
env:
REPO_NAME: "prediction-eml"
AWS_REGION: "us-east-1"

0 comments on commit 9bf16c7

Please sign in to comment.