add workflows
This commit is contained in:
51
.gitea/workflows/gitea-actions-demo.yaml
Normal file
51
.gitea/workflows/gitea-actions-demo.yaml
Normal file
@@ -0,0 +1,51 @@
|
||||
name: Gitea Actions Centos
|
||||
run-name: ${{ gitea.actor }} is testing out Gitea Actions 🚀
|
||||
on:
|
||||
push:
|
||||
paths:
|
||||
- 'execution-environment.yml'
|
||||
- '.gitea/workflows/gitea-actions-demo.yaml'
|
||||
|
||||
|
||||
jobs:
|
||||
Bootstrap-runner:
|
||||
runs-on: docker
|
||||
steps:
|
||||
- run: echo "🎉 The job was automatically triggered by a ${{ gitea.event_name }} event."
|
||||
- run: apk add --no-cache nodejs python3 docker
|
||||
- run: python -m ensurepip --upgrade
|
||||
- run: python -m pip install ansible-builder
|
||||
- name: Check out repository code
|
||||
uses: actions/checkout@v4
|
||||
- run: echo "💡 The ${{ gitea.repository }} repository has been cloned to the runner."
|
||||
- name: List files in the repository
|
||||
run: |
|
||||
ls ${{ gitea.workspace }}
|
||||
- run: echo "🍏 This job's status is ${{ job.status }}."
|
||||
Create-dockerfile-with-ansible-builder:
|
||||
runs-on: docker
|
||||
steps:
|
||||
- name: Check out repository code
|
||||
uses: actions/checkout@v4
|
||||
- run: echo "💡 The ${{ gitea.repository }} repository has been cloned to the runner."
|
||||
- name: List files in the repository
|
||||
run: |
|
||||
ls ${{ gitea.workspace }}
|
||||
- name: build context
|
||||
run: ansible-builder create -f execution-environment.yml -c context
|
||||
- name: List files in the repository
|
||||
run: |
|
||||
ls ${{ gitea.workspace }}/context
|
||||
- name: Login to the Container registry
|
||||
uses: docker/login-action@v2
|
||||
with:
|
||||
registry: git.hyperon.be
|
||||
username: bramvandendaele1@gmail.com
|
||||
password: ${{ secrets.CI_TOKEN }}
|
||||
- name: build and push docker image
|
||||
uses: https://github.com/docker/build-push-action@v5
|
||||
with:
|
||||
context: context
|
||||
file: context/Dockerfile
|
||||
push: true
|
||||
tags: git.hyperon.be/bram/ultimate-ee-centos9
|
||||
50
.gitea/workflows/gitea-actions-minimal.yaml
Normal file
50
.gitea/workflows/gitea-actions-minimal.yaml
Normal file
@@ -0,0 +1,50 @@
|
||||
name: Gitea Actions Minimal EE
|
||||
run-name: ${{ gitea.actor }} is testing out Gitea Actions 🚀
|
||||
on:
|
||||
push:
|
||||
paths:
|
||||
- 'minimal-environment.yml'
|
||||
- '.gitea/workflows/gitea-actions-minimal.yaml'
|
||||
|
||||
jobs:
|
||||
Bootstrap-runner:
|
||||
runs-on: docker
|
||||
steps:
|
||||
- run: echo "🎉 The job was automatically triggered by a ${{ gitea.event_name }} event."
|
||||
- run: apk add --no-cache nodejs python3 docker
|
||||
- run: python -m ensurepip --upgrade
|
||||
- run: python -m pip install ansible-builder
|
||||
- name: Check out repository code
|
||||
uses: actions/checkout@v4
|
||||
- run: echo "💡 The ${{ gitea.repository }} repository has been cloned to the runner."
|
||||
- name: List files in the repository
|
||||
run: |
|
||||
ls ${{ gitea.workspace }}
|
||||
- run: echo "🍏 This job's status is ${{ job.status }}."
|
||||
Create-dockerfile-with-ansible-builder:
|
||||
runs-on: docker
|
||||
steps:
|
||||
- name: Check out repository code
|
||||
uses: actions/checkout@v4
|
||||
- run: echo "💡 The ${{ gitea.repository }} repository has been cloned to the runner."
|
||||
- name: List files in the repository
|
||||
run: |
|
||||
ls ${{ gitea.workspace }}
|
||||
- name: build context
|
||||
run: ansible-builder create -f minimal-environment.yml -c context-minimal
|
||||
- name: List files in the repository
|
||||
run: |
|
||||
ls ${{ gitea.workspace }}/context-minimal
|
||||
- name: Login to the Container registry
|
||||
uses: docker/login-action@v2
|
||||
with:
|
||||
registry: git.hyperon.be
|
||||
username: bramvandendaele1@gmail.com
|
||||
password: ${{ secrets.CI_TOKEN }}
|
||||
- name: build and push docker image
|
||||
uses: https://github.com/docker/build-push-action@v5
|
||||
with:
|
||||
context: context-minimal
|
||||
file: context-minimal/Dockerfile
|
||||
push: true
|
||||
tags: git.hyperon.be/bram/ultimate-ee-minimal
|
||||
50
.gitea/workflows/gitea-actions-rocky.yaml
Normal file
50
.gitea/workflows/gitea-actions-rocky.yaml
Normal file
@@ -0,0 +1,50 @@
|
||||
name: Gitea Actions Rocky
|
||||
run-name: ${{ gitea.actor }} is testing out Gitea Actions 🚀
|
||||
on:
|
||||
push:
|
||||
paths:
|
||||
- 'rocky-environment.yml'
|
||||
- '.gitea/workflows/gitea-actions-rocky.yaml'
|
||||
|
||||
jobs:
|
||||
Bootstrap-runner:
|
||||
runs-on: docker
|
||||
steps:
|
||||
- run: echo "🎉 The job was automatically triggered by a ${{ gitea.event_name }} event."
|
||||
- run: apk add --no-cache nodejs python3 docker
|
||||
- run: python -m ensurepip --upgrade
|
||||
- run: python -m pip install ansible-builder
|
||||
- name: Check out repository code
|
||||
uses: actions/checkout@v4
|
||||
- run: echo "💡 The ${{ gitea.repository }} repository has been cloned to the runner."
|
||||
- name: List files in the repository
|
||||
run: |
|
||||
ls ${{ gitea.workspace }}
|
||||
- run: echo "🍏 This job's status is ${{ job.status }}."
|
||||
Create-dockerfile-with-ansible-builder:
|
||||
runs-on: docker
|
||||
steps:
|
||||
- name: Check out repository code
|
||||
uses: actions/checkout@v4
|
||||
- run: echo "💡 The ${{ gitea.repository }} repository has been cloned to the runner."
|
||||
- name: List files in the repository
|
||||
run: |
|
||||
ls ${{ gitea.workspace }}
|
||||
- name: build context
|
||||
run: ansible-builder create -f rocky-environment.yml -c context-rocky
|
||||
- name: List files in the repository
|
||||
run: |
|
||||
ls ${{ gitea.workspace }}/context-rocky
|
||||
- name: Login to the Container registry
|
||||
uses: docker/login-action@v2
|
||||
with:
|
||||
registry: git.hyperon.be
|
||||
username: bramvandendaele1@gmail.com
|
||||
password: ${{ secrets.CI_TOKEN }}
|
||||
- name: build and push docker image
|
||||
uses: https://github.com/docker/build-push-action@v5
|
||||
with:
|
||||
context: context-rocky
|
||||
file: context-rocky/Dockerfile
|
||||
push: true
|
||||
tags: git.hyperon.be/bram/ultimate-ee-rocky
|
||||
27
.gitea/workflows/gitea-actions-sonarqube.yml
Normal file
27
.gitea/workflows/gitea-actions-sonarqube.yml
Normal file
@@ -0,0 +1,27 @@
|
||||
name: Build
|
||||
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- main
|
||||
|
||||
|
||||
jobs:
|
||||
build:
|
||||
name: Build and analyze
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
with:
|
||||
fetch-depth: 0 # Shallow clones should be disabled for a better relevancy of analysis
|
||||
- uses: sonarsource/sonarqube-scan-action@master
|
||||
env:
|
||||
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
|
||||
SONAR_HOST_URL: ${{ secrets.SONAR_HOST_URL }}
|
||||
# If you wish to fail your job when the Quality Gate is red, uncomment the
|
||||
# following lines. This would typically be used to fail a deployment.
|
||||
# - uses: sonarsource/sonarqube-quality-gate-action@master
|
||||
# timeout-minutes: 5
|
||||
# env:
|
||||
# SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
|
||||
Reference in New Issue
Block a user