Skip to content

Append to log file instead of truncate #20

Append to log file instead of truncate

Append to log file instead of truncate #20

Workflow file for this run

name: Build and Push Docker Images
on:
push:
branches: [ main ]
tags: [ 'v*' ]
env:
REGISTRY: ghcr.io
ORGANIZATION: 256-foundation
jobs:
build:
name: Build Docker Images
runs-on: ubuntu-latest
permissions:
contents: read
packages: write
strategy:
matrix:
component: [bitcoind, ckpool, p2pool]
include:
- component: bitcoind
dockerfile: docker/Dockerfile.bitcoind
context: docker/
- component: ckpool
dockerfile: docker/Dockerfile.ckpool
context: docker/
- component: p2pool
dockerfile: docker/Dockerfile.p2pool
context: docker/
steps:
- name: Checkout code
uses: actions/checkout@v3
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2
- name: Login to GitHub Container Registry
if: github.event_name != 'pull_request'
uses: docker/login-action@v2
with:
registry: ${{ env.REGISTRY }}
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Extract metadata
id: meta
uses: docker/metadata-action@v4
with:
images: ${{ env.REGISTRY }}/${{ env.ORGANIZATION }}/hydrapool-${{ matrix.component }}
tags: |
type=ref,event=branch
type=ref,event=pr
type=semver,pattern={{version}}
type=semver,pattern={{major}}.{{minor}}
type=sha
labels: |
org.opencontainers.image.description=Hydrapool ${{ matrix.component }} image
org.opencontainers.image.vendor=${{ env.ORGANIZATION }}
org.opencontainers.image.licenses=GPL-3.0
org.opencontainers.image.visibility=public
- name: Build and push
uses: docker/build-push-action@v3
with:
context: ${{ matrix.context }}
file: ${{ matrix.dockerfile }}
push: ${{ github.event_name != 'pull_request' }}
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}
cache-from: type=gha
cache-to: type=gha,mode=max