forgejo workflow uses complete image now

This commit is contained in:
franz.germann1 2024-12-12 09:35:58 +01:00
parent c502b65940
commit 65ed6d6120

View file

@ -3,21 +3,30 @@ name: ci-workflow
on: [push] on: [push]
jobs: jobs:
ci: ci:
runs-on: docker runs-on: ubuntu-latest
container: container:
image: forgejo.edf-bootstrap.cx.fg1.ffm.osc.live/devfw-cicd/pipeline-container/kaniko:v1.23.2-2 image: forgejo.edf-bootstrap.cx.fg1.ffm.osc.live/devfw-cicd/complete:latest
steps: steps:
- uses: actions/checkout@v3
- name: Build and push - name: Clone Repository
uses: https://codeberg.org/umglurf/kaniko-action@main uses: https://forgejo.edf-bootstrap.cx.fg1.ffm.osc.live/DevFW-CICD/checkout@main
with:
cache: true - name: Lint the Repository
cache_repo: forgejo.edf-bootstrap.cx.fg1.ffm.osc.live/${{ github.repository }}/cache run: |
credentials: | golangci-lint run ./... --out-format=json --timeout 5m --issues-exit-code 1
https://forgejo.edf-bootstrap.cx.fg1.ffm.osc.live/v1/=${{ secrets.REGISTRY_USERNAME }}:${{ secrets.REGISTRY_PASSWORD }}
destinations: | - name: Build Credentials File
forgejo.edf-bootstrap.cx.fg1.ffm.osc.live/${{ github.repository }}:latest run: |
push: 'true' mkdir -p /kaniko/.docker
AUTHSTRING=$(echo -n "${{ secrets.REGISTRY_USERNAME }}:${{ secrets.REGISTRY_PASSWORD }}" | base64)
echo "{\"auths\":{\"https://gitea.cnoe.localtest.me\":{\"auth\":\"${AUTHSTRING}\"}}}" > /kaniko/.docker/config.json
- name: Build Docker Container
run: |
/kaniko/executor --skip-tls-verify --dockerfile=./Dockerfile --context=. --destination=gitea.cnoe.localtest.me/giteaadmin/fib:v0.0.1
- name: trivy
run: |
trivy ...