twdbben created a new release #142
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: test-and-push-ecr | |
run-name: ${{ github.actor }} created a new release | |
on: | |
push: | |
tags: | |
- v*.*.*-* | |
jobs: | |
test-image: | |
runs-on: ubuntu-22.04 | |
steps: | |
- uses: actions/checkout@v3 | |
- name: name_branch_tags | |
id: name_branch_tags | |
run: | | |
echo ::set-output name=SOURCE_NAME::${GITHUB_REF#refs/*/} | |
echo ::set-output name=SOURCE_BRANCH::${GITHUB_REF#refs/heads/} | |
echo ::set-output name=SOURCE_TAG::${GITHUB_REF#refs/tags/} | |
- run: ls -la | |
- run: aws --version | |
- name: aws_config | |
run: aws configure set aws_access_key_id ${AWS_ACCESS_KEY_ID} && aws configure set aws_secret_access_key ${AWS_SECRET_ACCESS_KEY} | |
env: | |
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }} | |
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }} | |
- run: aws configure set default.region us-east-1 | |
- run: touch ./docker/.env-secrets.env | |
- name: aws_s3_key_id | |
run: echo CKANEXT__S3FILESTORE__AWS_ACCESS_KEY_ID=${AWS_ACCESS_KEY_ID} >> ./docker/.env-secrets.env | |
env: | |
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }} | |
- name: aws_s3_key | |
run: echo CKANEXT__S3FILESTORE__AWS_SECRET_ACCESS_KEY=${AWS_SECRET_ACCESS_KEY} >> ./docker/.env-secrets.env | |
env: | |
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }} | |
- run: cat ./docker/.env-secrets.env | |
- run: make --version | |
- run: docker compose version | |
- name: build | |
run: | | |
echo $SOURCE_NAME $SOURCE_BRANCH $SOURCE_TAG | |
make ecrBuild TAG=$SOURCE_TAG | |
cat build.log | |
env: | |
SOURCE_NAME: ${{ steps.name_branch_tags.outputs.SOURCE_NAME }} | |
SOURCE_BRANCH: ${{ steps.name_branch_tags.outputs.SOURCE_BRANCH }} | |
SOURCE_TAG: ${{ steps.name_branch_tags.outputs.SOURCE_TAG }} | |
- run: docker image ls | |
- run: | | |
cd docker && docker compose --file docker-compose_local.yml up -d --wait | |
- name: docker_log | |
uses: actions/upload-artifact@v3 | |
with: | |
name: build_log | |
path: build.log | |
- run: docker ps | |
- run: curl 0.0.0.0:5000/api/3/action/status_show | |
- name: push | |
run: | | |
echo $SOURCE_NAME $SOURCE_BRANCH $SOURCE_TAG | |
make ecrPush TAG=$SOURCE_TAG | |
env: | |
SOURCE_NAME: ${{ steps.name_branch_tags.outputs.SOURCE_NAME }} | |
SOURCE_BRANCH: ${{ steps.name_branch_tags.outputs.SOURCE_BRANCH }} | |
SOURCE_TAG: ${{ steps.name_branch_tags.outputs.SOURCE_TAG }} |