feat(workflow): add Docker build and push automation
This commit is contained in:
parent
5f79671aa5
commit
e903df067b
51
.github/workflows/docker-build-and-push.yml
vendored
Normal file
51
.github/workflows/docker-build-and-push.yml
vendored
Normal file
@ -0,0 +1,51 @@
|
||||
name: Docker Build and Push
|
||||
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- main
|
||||
|
||||
jobs:
|
||||
docker-build-and-push:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Login to Docker Hub
|
||||
uses: docker/login-action@v3
|
||||
with:
|
||||
username: ${{ vars.DOCKERHUB_USERNAME }}
|
||||
password: ${{ secrets.DOCKERHUB_TOKEN }}
|
||||
|
||||
- name: Set up QEMU
|
||||
uses: docker/setup-qemu-action@v3
|
||||
with:
|
||||
platforms: amd64,arm64
|
||||
|
||||
- name: Set up Docker Buildx
|
||||
uses: docker/setup-buildx-action@v3
|
||||
|
||||
- name: Build and push monaco-editor-lsp-next
|
||||
uses: docker/build-push-action@v6
|
||||
with:
|
||||
context: ./
|
||||
dockerfile: Dockerfile
|
||||
push: true
|
||||
tags: ${{ vars.DOCKERHUB_USERNAME }}/monaco-editor-lsp-next:latest
|
||||
platforms: linux/amd64,linux/arm64
|
||||
|
||||
- name: Build and push lsp-c
|
||||
uses: docker/build-push-action@v6
|
||||
with:
|
||||
context: ./docker/lsp/clangd
|
||||
dockerfile: Dockerfile
|
||||
push: true
|
||||
tags: ${{ vars.DOCKERHUB_USERNAME }}/lsp-c:latest
|
||||
platforms: linux/amd64,linux/arm64
|
||||
|
||||
- name: Build and push lsp-cpp
|
||||
uses: docker/build-push-action@v6
|
||||
with:
|
||||
context: ./docker/lsp/clangd
|
||||
dockerfile: Dockerfile
|
||||
push: true
|
||||
tags: ${{ vars.DOCKERHUB_USERNAME }}/lsp-cpp:latest
|
||||
platforms: linux/amd64,linux/arm64
|
Loading…
Reference in New Issue
Block a user