Skip to content

Commit

Permalink
Merge branch 'main' into depends/dotnet/8.0.402
Browse files Browse the repository at this point in the history
  • Loading branch information
credfeto authored Sep 25, 2024
2 parents 7bd700f + 5df86d3 commit 2fac4df
Show file tree
Hide file tree
Showing 3 changed files with 42 additions and 8 deletions.
1 change: 1 addition & 0 deletions .github/actions/build/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -418,6 +418,7 @@ runs:
API_PREFIX: ${{inputs.API_PREFIX}}
AWS_LOAD_BALANCER_HOSTNAME: ${{inputs.AWS_LOAD_BALANCER_HOSTNAME}}
AWS_LOAD_BALANCER_PRIORITY: ${{inputs.AWS_LOAD_BALANCER_PRIORITY}}
AWS_CONTAINER_REGISTRY: ${{inputs.AWS_CONTAINER_REGISTRY}}
GITHUB_TOKEN: ${{inputs.GITHUB_TOKEN}}

############################################################################################################
Expand Down
22 changes: 19 additions & 3 deletions .github/actions/dispatch-deploy/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,9 @@ inputs:
AWS_LOAD_BALANCER_PRIORITY:
description: "AWS Load Balancer match priority"
required: true
AWS_CONTAINER_REGISTRY:
description: "AWS container registry to retrieve package from"
required: true
BUILD_VERSION:
description: "Build Version"
required: true
Expand All @@ -41,6 +44,20 @@ runs:
using: "composite"
steps:

- name: "Log parameters"
shell: bash
run: |
echo "CLOUD_FORMATION_STACK: ${{inputs.CLOUD_FORMATION_STACK}}"
echo "CLOUD_FORMATION_TEMPLATE_FILE: ${{inputs.CLOUD_FORMATION_TEMPLATE_FILE}}"
echo "DOCKER_APP_OWNER: ${{inputs.DOCKER_APP_OWNER}}"
echo "DOCKER_APP_NAME: ${{inputs.DOCKER_APP_NAME}}"
echo "BUILD_VERSION: ${{inputs.BUILD_VERSION}}"
echo "API_HOST: ${{inputs.API_HOST}}"
echo "API_PREFIX: ${{inputs.API_PREFIX}}"
echo "AWS_LOAD_BALANCER_HOSTNAME: ${{inputs.AWS_LOAD_BALANCER_HOSTNAME}}"
echo "AWS_CONTAINER_REGISTRY: ${{inputs.AWS_CONTAINER_REGISTRY}}"
echo "AWS_LOAD_BALANCER_PRIORITY: ${{inputs.AWS_LOAD_BALANCER_PRIORITY}}"
- name: "Trigger Deployment Workflow"
uses: actions/github-script@v6
with:
Expand All @@ -54,12 +71,11 @@ runs:
inputs: {
CLOUD_FORMATION_STACK: "${{inputs.CLOUD_FORMATION_STACK}}",
CLOUD_FORMATION_TEMPLATE_FILE: "${{inputs.CLOUD_FORMATION_TEMPLATE_FILE}}",
CLOUD_FORMATION_TEMPLATE_FILE: "${{github.workspace}}/deploy/${{inputs.APP_NAME}}.json",
DOCKER_APP_OWNER: "${{inputs.DOCKER_APP_OWNER}}",
DOCKER_APP_NAME: "${{inputs.DOCKER_APP_NAME}}",
BUILD_VERSION: "${{inputs.BUILD_VERSION}}",
API_HOST: "${{inputs.API_HOST}},
API_PREFIX: "/${{inputs.APP_NAME}}",
API_HOST: "${{inputs.API_HOST}}",
API_PREFIX: "${{inputs.API_PREFIX}}",
AWS_LOAD_BALANCER_HOSTNAME: "${{inputs.AWS_LOAD_BALANCER_HOSTNAME}}",
AWS_CONTAINER_REGISTRY: "${{inputs.AWS_CONTAINER_REGISTRY}}",
AWS_LOAD_BALANCER_PRIORITY: "${{inputs.AWS_LOAD_BALANCER_PRIORITY}}",
Expand Down
27 changes: 22 additions & 5 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -48,10 +48,28 @@ jobs:
runs-on: [self-hosted, linux, deploy]

steps:
- name: "Hello World"
- name: "Correct ownership"
run: sudo chown -R "$USER:$USER" "$GITHUB_WORKSPACE"

- name: "Checkout"
uses: actions/[email protected]
with:
fetch-depth: 0
fetch-tags: true

- name: "Log parameters"
shell: bash
run: |
echo "Hello World: ${{inputs.CLOUD_FORMATION_STACK}}"
echo "CLOUD_FORMATION_STACK: ${{inputs.CLOUD_FORMATION_STACK}}"
echo "CLOUD_FORMATION_TEMPLATE_FILE: ${{inputs.CLOUD_FORMATION_TEMPLATE_FILE}}"
echo "DOCKER_APP_OWNER: ${{inputs.DOCKER_APP_OWNER}}"
echo "DOCKER_APP_NAME: ${{inputs.DOCKER_APP_NAME}}"
echo "BUILD_VERSION: ${{inputs.BUILD_VERSION}}"
echo "API_HOST: ${{inputs.API_HOST}}"
echo "API_PREFIX: ${{inputs.API_PREFIX}}"
echo "AWS_LOAD_BALANCER_HOSTNAME: ${{inputs.AWS_LOAD_BALANCER_HOSTNAME}}"
echo "AWS_CONTAINER_REGISTRY: ${{inputs.AWS_CONTAINER_REGISTRY}}"
echo "AWS_LOAD_BALANCER_PRIORITY: ${{inputs.AWS_LOAD_BALANCER_PRIORITY}}"
- name: "Configure AWS Credentials"
uses: aws-actions/[email protected]
Expand All @@ -60,18 +78,17 @@ jobs:
aws-secret-access-key: ${{secrets.AWS_DOCKER_CONTAINER_REGISTRY_SECRET_ACCESS_KEY}}
aws-region: ${{vars.AWS_REGION}}

## AWS_CONTAINER_REGISTRY: ${{vars.AWS_CONTAINER_REGISTRY}}
- name: "Cloudformation Deploy"
uses: ./.github/actions/cloudformation-deploy
with:
CLOUD_FORMATION_STACK: ${{inputs.CLOUD_FORMATION_STACK}}
CLOUDFORMATION_SNS_ARN: ${{inputs.CLOUDFORMATION_SNS_ARN}}
CLOUD_FORMATION_TEMPLATE_FILE: ${{inputs.CLOUD_FORMATION_TEMPLATE_FILE}}
CLOUD_FORMATION_TEMPLATE_FILE: "${{github.workspace}}/${{inputs.CLOUD_FORMATION_TEMPLATE_FILE}}"
DOCKER_APP_OWNER: ${{inputs.DOCKER_APP_OWNER}}
DOCKER_APP_NAME: ${{inputs.DOCKER_APP_NAME}}
BUILD_VERSION: ${{inputs.BUILD_VERSION}}
API_HOST: ${{inputs.API_HOST}}
API_PREFIX: ${{inputs.API_PREFIX}}
AWS_LOAD_BALANCER_HOSTNAME: ${{inputs.AWS_LOAD_BALANCER_HOSTNAME}}
AWS_LOAD_BALANCER_PRIORITY: ${{inputs.AWS_LOAD_BALANCER_PRIORITY}}
AWS_CONTAINER_REGISTRY: ${{vars.AWS_CONTAINER_REGISTRY}}
AWS_CONTAINER_REGISTRY: ${{inputs.AWS_CONTAINER_REGISTRY}}

0 comments on commit 2fac4df

Please sign in to comment.