Fix workflow to use standard buildx
This commit is contained in:
parent
5311eeb1b5
commit
0edbb9c728
|
|
@ -4,45 +4,32 @@ on: [push]
|
||||||
jobs:
|
jobs:
|
||||||
build-backend:
|
build-backend:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
env:
|
|
||||||
DOCKER_HOST: tcp://172.17.0.1:2375
|
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout
|
- name: Checkout
|
||||||
uses: actions/checkout@v3
|
uses: actions/checkout@v3
|
||||||
|
|
||||||
- name: Build and push Backend (Kaniko)
|
- name: Set up Docker Buildx
|
||||||
run: |
|
uses: docker/setup-buildx-action@v2
|
||||||
# Find this job container by its known name pattern
|
|
||||||
JOB_CONTAINER=$(docker ps --format '{{.Names}}' | grep 'GITEA-ACTIONS-TASK' | head -1)
|
|
||||||
echo "Using volumes from: $JOB_CONTAINER"
|
|
||||||
|
|
||||||
docker run --rm \
|
- name: Build and push Backend
|
||||||
--volumes-from "$JOB_CONTAINER" \
|
uses: docker/build-push-action@v4
|
||||||
gcr.io/kaniko-project/executor:latest \
|
with:
|
||||||
--context=dir:///workspace/deepkoluguri/chitfund/backend \
|
context: ./backend
|
||||||
--dockerfile=Dockerfile \
|
push: true
|
||||||
--destination=192.168.8.250:5000/chitfund-backend:latest \
|
tags: 192.168.8.250:5000/chitfund-backend:latest
|
||||||
--insecure \
|
|
||||||
--skip-tls-verify
|
|
||||||
|
|
||||||
build-frontend:
|
build-frontend:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
env:
|
|
||||||
DOCKER_HOST: tcp://172.17.0.1:2375
|
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout
|
- name: Checkout
|
||||||
uses: actions/checkout@v3
|
uses: actions/checkout@v3
|
||||||
|
|
||||||
- name: Build and push Frontend (Kaniko)
|
- name: Set up Docker Buildx
|
||||||
run: |
|
uses: docker/setup-buildx-action@v2
|
||||||
JOB_CONTAINER=$(docker ps --format '{{.Names}}' | grep 'GITEA-ACTIONS-TASK' | head -1)
|
|
||||||
echo "Using volumes from: $JOB_CONTAINER"
|
|
||||||
|
|
||||||
docker run --rm \
|
- name: Build and push Frontend
|
||||||
--volumes-from "$JOB_CONTAINER" \
|
uses: docker/build-push-action@v4
|
||||||
gcr.io/kaniko-project/executor:latest \
|
with:
|
||||||
--context=dir:///workspace/deepkoluguri/chitfund/luckychit \
|
context: ./luckychit
|
||||||
--dockerfile=Dockerfile \
|
push: true
|
||||||
--destination=192.168.8.250:5000/chitfund-frontend:latest \
|
tags: 192.168.8.250:5000/chitfund-frontend:latest
|
||||||
--insecure \
|
|
||||||
--skip-tls-verify
|
|
||||||
Loading…
Reference in New Issue