build and push
This commit is contained in:
parent
b57edc642b
commit
9b28afcf91
@ -6,19 +6,32 @@ on:
|
||||
- master
|
||||
|
||||
jobs:
|
||||
docker:
|
||||
build:
|
||||
name: Build and push image
|
||||
runs-on: ubuntu-latest
|
||||
services:
|
||||
registry:
|
||||
image: registry:2
|
||||
ports:
|
||||
- 32000:32000
|
||||
container: catthehacker/ubuntu:act-latest
|
||||
|
||||
steps:
|
||||
- name: checkout code
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: Build Docker image
|
||||
run: docker build . --file Dockerfile --tag localhost:32000/scrapper:latest
|
||||
- name: Create Kubeconfig
|
||||
run: |
|
||||
mkdir $HOME/.kube
|
||||
echo "${{ secrets.KUBECONFIG_BUILDX }}" > $HOME/.kube/config
|
||||
|
||||
- name: push image to registry
|
||||
run: docker push localhost:32000/scrapper:latest
|
||||
- name: Set up Docker Buildx
|
||||
uses: docker/setup-buildx-action@v3
|
||||
with:
|
||||
driver: kubernetes
|
||||
driver-opts: |
|
||||
namespace=act-runner
|
||||
qemu.install=true
|
||||
- name: Build and push
|
||||
uses: docker/build-push-action@v5
|
||||
with:
|
||||
context: .
|
||||
push: true
|
||||
platforms: linux/arm64
|
||||
tags: |
|
||||
localhost:32000/scrapper:latest
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user