diff --git a/.github/workflows/build-push-docker-image.yml b/.github/workflows/build-push-docker-image.yml new file mode 100644 index 0000000..2265a33 --- /dev/null +++ b/.github/workflows/build-push-docker-image.yml @@ -0,0 +1,30 @@ +name: Blockbook docker image | Build and Push +run-name: Building and pushing blockbook docker image to DockerHub +on: [push] + +jobs: + build-push-blockbook-docker: + runs-on: self-hosted + + steps: + - name: Checkout code + uses: actions/checkout@v4 + + - name: Set up Docker Buildx + uses: docker/setup-buildx-action@v2 + + - name: Log in to Docker Hub + uses: docker/login-action@v2 + with: + username: ${{ secrets.DOCKER_HUB_USERNAME }} + password: ${{ secrets.DOCKER_HUB_ACCESS_TOKEN }} + + - name: Build and push Docker image + uses: docker/build-push-action@v4 + with: + context: . + push: true + tags: ${{ secrets.DOCKER_HUB_USERNAME }}/blockbook:1.0.0 + + - name: Log out from Docker Hub + run: docker logout diff --git a/.github/workflows/learn-github-actions.yml b/.github/workflows/learn-github-actions.yml new file mode 100644 index 0000000..ea79d98 --- /dev/null +++ b/.github/workflows/learn-github-actions.yml @@ -0,0 +1,13 @@ +name: learn-github-actions +run-name: ${{ github.actor }} is learning GitHub Actions +on: [push] +jobs: + check-bats-version: + runs-on: self-hosted + steps: + - uses: actions/checkout@v4 + - uses: actions/setup-node@v4 + with: + node-version: '20' + - run: npm install -g bats + - run: bats -v