Skip to content

Commit

Permalink
CI
Browse files Browse the repository at this point in the history
  • Loading branch information
MotorTruck1221 committed Sep 19, 2024
1 parent 2c7d09e commit adaaed7
Showing 1 changed file with 41 additions and 0 deletions.
41 changes: 41 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
name: Build and push Docker images
on:
push:
tags:
- v*
workflow_dispatch:

env:
REGISTRY: ghcr.io

jobs:
server:
runs-on: ubuntu-latest
permissions: write-all
steps:
- name: Checkout repository
uses: actions/checkout@v3
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
with:
driver: docker
- name: Login to GitHub Container Registry
uses: docker/login-action@v3
with:
registry: ${{ env.REGISTRY }}
username: "motortruck1221"
password: ${{ secrets.GITHUB_TOKEN }}
- name: Extract Docker Metadata
id: meta
uses: docker/metadata-action@98669ae865ea3cffbcbaa878cf57c20bbf1c6c38
with:
images: ${{ env.REGISTRY }}/ruby-network/corlink-server
- name: Build and push Docker image
id: docker_build
uses: docker/build-push-action@v3
with:
context: .
file: ./Dockerfile
push: true
labels: ${{ steps.meta.outputs.labels }}
tags: ${{ env.REGISTRY }}/ruby-network/assets-server:latest, ${{ env.REGISTRY }}/ruby-network/assets-server:${{ github.sha }}

0 comments on commit adaaed7

Please sign in to comment.