First cut at CI workflows (#6)
Co-authored-by: Shrukan <shrukan@shrukanslab.xyz> Reviewed-on: sl-devs/CppTemplate#6
This commit is contained in:
36
.gitea/workflows/build_image.yml
Normal file
36
.gitea/workflows/build_image.yml
Normal file
@ -0,0 +1,36 @@
|
||||
name: Build Image
|
||||
run-name: ${{ gitea.ref }} Build
|
||||
on:
|
||||
push:
|
||||
|
||||
jobs:
|
||||
build-dev-image:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Check out repository code
|
||||
uses: actions/checkout@v3
|
||||
|
||||
- name: Install Docker
|
||||
run: curl -fsSL https://get.docker.com | sh
|
||||
|
||||
- name: Set up Docker Buildx
|
||||
uses: docker/setup-buildx-action@v2
|
||||
|
||||
- name: Log into Gitea
|
||||
uses: docker/login-action@v1
|
||||
with:
|
||||
registry: gitea.shrukanslab.xyz
|
||||
username: ${{ secrets.ROBOT_USERNAME }}
|
||||
password: ${{ secrets.ROBOT_PASSWORD }}
|
||||
|
||||
- name: Build and push
|
||||
uses: docker/build-push-action@v4
|
||||
with:
|
||||
context: .
|
||||
platforms: linux/amd64
|
||||
push: true
|
||||
tags: |
|
||||
gitea.shrukanslab.xyz/CppTemplate/dev-environment:latest
|
||||
|
||||
- name: Logout from Docker Registry
|
||||
run: docker logout gitea.shrukanslab.xyz
|
||||
Reference in New Issue
Block a user