feature/gitea-actions-update #2
@ -6,10 +6,7 @@ on:
|
|||||||
jobs:
|
jobs:
|
||||||
build:
|
build:
|
||||||
runs-on: docker
|
runs-on: docker
|
||||||
container:
|
|
||||||
image: docker:24-cli
|
|
||||||
steps:
|
steps:
|
||||||
- run: apk --no-cache add nodejs git
|
|
||||||
- uses: actions/checkout@v3
|
- uses: actions/checkout@v3
|
||||||
- name: docker login
|
- name: docker login
|
||||||
run: docker login -u $REGISTRY_USER -p $REGISTRY_PASSWORD gitea.sikorski.cloud
|
run: docker login -u $REGISTRY_USER -p $REGISTRY_PASSWORD gitea.sikorski.cloud
|
||||||
@ -17,12 +14,12 @@ jobs:
|
|||||||
REGISTRY_USER: ${{ secrets.REGISTRY_USER }}
|
REGISTRY_USER: ${{ secrets.REGISTRY_USER }}
|
||||||
REGISTRY_PASSWORD: ${{ secrets.REGISTRY_PASSWORD }}
|
REGISTRY_PASSWORD: ${{ secrets.REGISTRY_PASSWORD }}
|
||||||
- name: Pull Docker Image for caching
|
- name: Pull Docker Image for caching
|
||||||
run: docker pull gitea.sikorski.cloud/rogersik/docker-admin-helper:development || exit 0
|
run: docker pull gitea.sikorski.cloud/rogersik/devops-helper:development || exit 0
|
||||||
- name: Build docker image
|
- name: Build docker image
|
||||||
run: |
|
run: |
|
||||||
docker build . \
|
docker build . \
|
||||||
--cache-from gitea.sikorski.cloud/rogersik/docker-admin-helper:development \
|
--cache-from gitea.sikorski.cloud/rogersik/devops-helper:development \
|
||||||
--file Dockerfile \
|
--file Dockerfile \
|
||||||
--tag gitea.sikorski.cloud/rogersik/docker-admin-helper:development
|
--tag gitea.sikorski.cloud/rogersik/devops-helper:development
|
||||||
- name: Push docker image
|
- name: Push docker image
|
||||||
run: docker push gitea.sikorski.cloud/rogersik/docker-admin-helper --all-tags
|
run: docker push gitea.sikorski.cloud/rogersik/devops-helper --all-tags
|
||||||
|
24
.gitea/workflows/main.yaml
Normal file
24
.gitea/workflows/main.yaml
Normal file
@ -0,0 +1,24 @@
|
|||||||
|
on:
|
||||||
|
push:
|
||||||
|
- main
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
build:
|
||||||
|
runs-on: docker
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v3
|
||||||
|
- name: docker login
|
||||||
|
run: docker login -u $REGISTRY_USER -p $REGISTRY_PASSWORD gitea.sikorski.cloud
|
||||||
|
env:
|
||||||
|
REGISTRY_USER: ${{ secrets.REGISTRY_USER }}
|
||||||
|
REGISTRY_PASSWORD: ${{ secrets.REGISTRY_PASSWORD }}
|
||||||
|
- name: Pull Docker Image for caching
|
||||||
|
run: docker pull gitea.sikorski.cloud/rogersik/devops-helper:development || exit 0
|
||||||
|
- name: Build docker image
|
||||||
|
run: |
|
||||||
|
docker build . \
|
||||||
|
--cache-from gitea.sikorski.cloud/rogersik/devops-helper:development \
|
||||||
|
--file Dockerfile \
|
||||||
|
--tag gitea.sikorski.cloud/rogersik/devops-helper:latest
|
||||||
|
- name: Push docker image
|
||||||
|
run: docker push gitea.sikorski.cloud/rogersik/devops-helper --all-tags
|
Loading…
Reference in New Issue
Block a user