From 8142732f99a7d1ab2baaf7a0fc20e3e623733328 Mon Sep 17 00:00:00 2001 From: Kosala Gangabadage Date: Tue, 2 Feb 2021 08:13:26 +0530 Subject: [PATCH] Platformer GitHub Action Created --- ...r-565cc184-9d2c-4eca-b107-8aa0d9e1ef7c.yml | 38 +++++++++++++++++++ 1 file changed, 38 insertions(+) create mode 100644 .github/workflows/platformer-565cc184-9d2c-4eca-b107-8aa0d9e1ef7c.yml diff --git a/.github/workflows/platformer-565cc184-9d2c-4eca-b107-8aa0d9e1ef7c.yml b/.github/workflows/platformer-565cc184-9d2c-4eca-b107-8aa0d9e1ef7c.yml new file mode 100644 index 0000000..16336b5 --- /dev/null +++ b/.github/workflows/platformer-565cc184-9d2c-4eca-b107-8aa0d9e1ef7c.yml @@ -0,0 +1,38 @@ +name: Platformer Generated staging-tag-push Build +on: + push: + tags: + - "*" +jobs: + build: + runs-on: + - ubuntu-latest + env: + SERVICE_NAME: ghcr.io/eclk/auth-app + CONTAINER_REGISTRY: ghcr.io + steps: + - uses: actions/checkout@v2 + - name: Set Version + id: event-version + run: echo ::set-output name=SOURCE_TAG::${GITHUB_REF#refs/tags/} + - name: Login to GitHub Container Registry + uses: docker/login-action@v1 + with: + registry: ${{ env.CONTAINER_REGISTRY }} + username: ${{ github.actor }} + password: ${{ secrets.DOCKER_PASSWORD }} + - name: Build the Docker image + run: docker build --tag + ${SERVICE_NAME}:${{steps.event-version.outputs.SOURCE_TAG }} --file + Dockerfile . + - name: GitHub Image Push + run: docker push $SERVICE_NAME:${{steps.event-version.outputs.SOURCE_TAG }} + - name: Platformer Deploy + uses: platformer-com/build-deploy-action@v1 + with: + org-id: ${{secrets.ORG_ID_7E09F3BF_15EF_441C_A40F_4F98A975A067}} + project-id: ${{secrets.PROJECT_ID_7E09F3BF_15EF_441C_A40F_4F98A975A067}} + token: ${{secrets.AUTOGENERATED_CICD_7E09F3BF_15EF_441C_A40F_4F98A975A067}} + image-name: ${{env.SERVICE_NAME}} + tag: ${{steps.event-version.outputs.SOURCE_TAG }} + container-id: 1e46180e-a271-4f6f-9549-651e9a1dff13