decrease snapshot backup poller frequency #330
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: build_image_spdk_core_arm | |
on: | |
workflow_dispatch: | |
push: | |
jobs: | |
build: | |
runs-on: linux-arm | |
steps: | |
- name: Checkout the triggered branch | |
uses: actions/checkout@v3 | |
with: | |
ref: ${{ github.event.workflow_run.head_branch }} | |
- name: Set docker image tag | |
id: get_info | |
run: | | |
if [[ "${{github.ref}}" == refs/pull/* ]]; then | |
tag=${GITHUB_REF/\/merge/} | |
echo "TAG=$(echo pr-${tag:10})" >> $GITHUB_ENV | |
else | |
echo "TAG=$(echo ${GITHUB_REF#refs/*/} | sed 's/\//-/g')" >> $GITHUB_ENV | |
fi | |
echo "BRANCH=$([ -z '${{ github.event.pull_request.head.sha }}' ] && echo ${GITHUB_REF#refs/*/} || echo $GITHUB_HEAD_REF)" >> $GITHUB_ENV | |
echo "SHA=$([ -z '${{ github.event.pull_request.head.sha }}' ] && echo $GITHUB_SHA || echo '${{ github.event.pull_request.head.sha }}')" >> $GITHUB_ENV | |
- name: Build the docker image | |
run: docker build --file docker/Dockerfile_spdk_arm --tag simplyblock/spdk-core:$TAG-arm64 . | |
- name: Login to Docker Hub | |
uses: docker/login-action@v1 | |
with: | |
username: hamdysimplyblock | |
password: ${{ secrets.DOCKER_PASS }} | |
- name: Push Images | |
run: docker push simplyblock/spdk-core:$TAG-arm64 | |
- name: Configure AWS Credentials | |
uses: aws-actions/configure-aws-credentials@v1 | |
with: | |
aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID_HAMDI }} | |
aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY_HAMDI }} | |
aws-region: us-east-1 | |
- name: Login to ECR | |
id: login-ecr | |
uses: aws-actions/amazon-ecr-login@v2 | |
- name: Tag docker image | |
run: docker tag simplyblock/spdk-core:$TAG-arm64 565979732541.dkr.ecr.us-east-1.amazonaws.com/spdk-core:$TAG-arm64 | |
- name: Push the docker image | |
run: docker image push 565979732541.dkr.ecr.us-east-1.amazonaws.com/spdk-core:$TAG-arm64 |