mirror of https://github.com/statping/statping
dockerhub push
parent
2920aede9c
commit
aadffa2be4
|
@ -18,22 +18,43 @@ jobs:
|
||||||
run: |
|
run: |
|
||||||
echo "Don't cancel old workflow"
|
echo "Don't cancel old workflow"
|
||||||
|
|
||||||
|
|
||||||
build-statping-docker-image:
|
build-statping-docker-image:
|
||||||
name: Docker image - statping
|
name: Docker image - statping
|
||||||
runs-on: [ubuntu-latest]
|
runs-on: [ubuntu-latest]
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v2
|
- name: checkout
|
||||||
- name: Build and push
|
id: checkout
|
||||||
uses: docker/build-push-action@v1
|
uses: actions/checkout@v2
|
||||||
with:
|
with:
|
||||||
registry: c.rzp.io/proxy_dockerhub
|
submodules: true
|
||||||
username: ${{ secrets.PUBLIC_DOCKER_USERNAME }}
|
- name: Set up Docker Buildx
|
||||||
password: ${{ secrets.PUBLIC_DOCKER_PASSWORD }}
|
uses: docker/setup-buildx-action@v1
|
||||||
repository: ${{ github.repository }}
|
- name: Cache Docker layers
|
||||||
dockerfile: ./Dockerfile
|
uses: actions/cache@v2
|
||||||
build_args: GIT_COMMIT_HASH=${{ github.sha }},GIT_TOKEN=${{ secrets.GIT_TOKEN }}
|
with:
|
||||||
|
path: /tmp/.buildx-cache
|
||||||
|
key: ${{ runner.os }}-buildx-${{ github.sha }}
|
||||||
|
restore-keys: |
|
||||||
|
${{ runner.os }}-buildx-
|
||||||
|
- name: docker login
|
||||||
|
uses: docker/login-action@v1
|
||||||
|
with:
|
||||||
|
username: ${{ secrets.DOCKER_USERNAME }}
|
||||||
|
password: ${{ secrets.DOCKER_PASSWORD }}
|
||||||
|
- name: build statping image
|
||||||
|
uses: docker/build-push-action@v2
|
||||||
|
with:
|
||||||
|
tags: razorpay/statping:service_${{ github.sha }}
|
||||||
push: true
|
push: true
|
||||||
tags: service_${{ github.sha }}
|
file: ./Dockerfile
|
||||||
|
build-args: GIT_COMMIT_HASH=${{ github.sha }}
|
||||||
|
cache-from: type=local,src=/tmp/.buildx-cache
|
||||||
|
cache-to: type=local,dest=/tmp/.buildx-cache
|
||||||
|
env:
|
||||||
|
GIT_COMMIT_HASH: ${{ github.sha }}
|
||||||
|
APP_ENV: dev_docker
|
||||||
|
EXEC_MODE: test
|
||||||
|
|
||||||
fmt:
|
fmt:
|
||||||
name: fmt
|
name: fmt
|
||||||
|
|
Loading…
Reference in New Issue