Skip to content

martin-binance 3.0.16 #42

martin-binance 3.0.16

martin-binance 3.0.16 #42

Workflow file for this run

name: Docker Image CI
on:
workflow_dispatch:
release:
types: [published]
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
- name: PrepareReg Names
run: |
echo IMAGE_REPOSITORY=$(echo ${{ github.repository }} | tr '[:upper:]' '[:lower:]') >> $GITHUB_ENV
echo IMAGE_TAG=$(echo ${{ github.ref }} | tr '[:upper:]' '[:lower:]' | awk '{split($0,a,"/"); print a[3]}') >> $GITHUB_ENV
- name: Login to GHCR
uses: docker/login-action@v2
with:
registry: ghcr.io
username: ${{ github.repository_owner }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Build and push
run: |
docker build . --tag ghcr.io/$IMAGE_REPOSITORY:$IMAGE_TAG
docker push ghcr.io/$IMAGE_REPOSITORY:$IMAGE_TAG
docker build . --tag ghcr.io/$IMAGE_REPOSITORY:latest
docker push ghcr.io/$IMAGE_REPOSITORY:latest