Compare commits
5 Commits
6f0d10c99e
...
87bc4d22f0
| Author | SHA1 | Date | |
|---|---|---|---|
| 87bc4d22f0 | |||
| 29a4d9b0d0 | |||
| 50626df505 | |||
| 088e97b1d3 | |||
| c6e1975385 |
27
.gitea/workflows/build.yaml
Normal file
27
.gitea/workflows/build.yaml
Normal file
@ -0,0 +1,27 @@
|
|||||||
|
name: Build
|
||||||
|
|
||||||
|
on:
|
||||||
|
pull_request:
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
build:
|
||||||
|
runs-on: almalinux-8
|
||||||
|
container:
|
||||||
|
image: git.query.consul/unkin/almalinux9-actionsdind:latest
|
||||||
|
options: --privileged
|
||||||
|
|
||||||
|
steps:
|
||||||
|
- name: Checkout code
|
||||||
|
uses: actions/checkout@v3
|
||||||
|
with:
|
||||||
|
fetch-depth: 0
|
||||||
|
|
||||||
|
- name: Show changed files
|
||||||
|
run: |
|
||||||
|
git diff --name-only master
|
||||||
|
|
||||||
|
- name: Run Packer Builds
|
||||||
|
env:
|
||||||
|
VAULT_ROLEID: ${{ secrets.PACKER_BUILDER_VAULT_ROLEID }}
|
||||||
|
run: |
|
||||||
|
make
|
||||||
34
.gitea/workflows/deploy.yaml
Normal file
34
.gitea/workflows/deploy.yaml
Normal file
@ -0,0 +1,34 @@
|
|||||||
|
name: Deploy
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
branches:
|
||||||
|
- master
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
build:
|
||||||
|
runs-on: almalinux-8
|
||||||
|
container:
|
||||||
|
image: git.query.consul/unkin/almalinux8:latest
|
||||||
|
options: --privileged
|
||||||
|
|
||||||
|
steps:
|
||||||
|
- name: Set up environment
|
||||||
|
run: |
|
||||||
|
dnf install -y yum-utils
|
||||||
|
yum-config-manager --add-repo https://download.docker.com/linux/centos/docker-ce.repo
|
||||||
|
dnf module enable -y nodejs:20
|
||||||
|
dnf install -y docker-ce-cli make bash git nodejs
|
||||||
|
|
||||||
|
- name: Checkout code
|
||||||
|
uses: actions/checkout@v3
|
||||||
|
with:
|
||||||
|
fetch-depth: 0
|
||||||
|
|
||||||
|
- name: Run Packer Builds
|
||||||
|
env:
|
||||||
|
VAULT_ROLEID: ${{ secrets.PACKER_BUILDER_VAULT_ROLEID }}
|
||||||
|
DOCKER_USERNAME: ${{ secrets.UPLOAD_USER }}
|
||||||
|
DOCKER_PASSWORD: ${{ secrets.UPLOAD_PASS }}
|
||||||
|
run: |
|
||||||
|
make
|
||||||
2
Makefile
2
Makefile
@ -17,7 +17,7 @@ DIRS := $(shell find $(IMAGES_PATH) -mindepth 3 -maxdepth 3 -type d | sed 's|$(I
|
|||||||
.PHONY: list $(DIRS)
|
.PHONY: list $(DIRS)
|
||||||
|
|
||||||
.DEFAULT_GOAL := default
|
.DEFAULT_GOAL := default
|
||||||
default:
|
default: clean
|
||||||
./ci/build.sh
|
./ci/build.sh
|
||||||
|
|
||||||
# Make all images
|
# Make all images
|
||||||
|
|||||||
@ -1,6 +1,7 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
|
|
||||||
# Check for changes in images/ folder and the builds/ folder
|
# Check for changes in images/ folder and the builds/ folder
|
||||||
|
git fetch origin master:master
|
||||||
if [ "$(git branch --show-current)" = "master" ]; then
|
if [ "$(git branch --show-current)" = "master" ]; then
|
||||||
builds_changes=$(git diff --name-only HEAD^...master | grep -E '^builds/')
|
builds_changes=$(git diff --name-only HEAD^...master | grep -E '^builds/')
|
||||||
images_changes=$(git diff --name-only HEAD^...master | grep -E '^images/')
|
images_changes=$(git diff --name-only HEAD^...master | grep -E '^images/')
|
||||||
|
|||||||
@ -1,2 +1 @@
|
|||||||
docker
|
docker
|
||||||
incus
|
|
||||||
|
|||||||
@ -1,7 +1,7 @@
|
|||||||
# almalinux/8.10/base
|
# almalinux/8.10/base
|
||||||
deploy_files_from_image = true
|
deploy_files_from_image = true
|
||||||
deploy_files_from_common = true
|
deploy_files_from_common = true
|
||||||
use_incus = true
|
use_incus = false
|
||||||
packages = [
|
packages = [
|
||||||
"git",
|
"git",
|
||||||
"jq",
|
"jq",
|
||||||
|
|||||||
@ -1,2 +1 @@
|
|||||||
docker
|
docker
|
||||||
incus
|
|
||||||
|
|||||||
@ -1,7 +1,7 @@
|
|||||||
# almalinux/9.5/base
|
# almalinux/9.5/base
|
||||||
deploy_files_from_image = true
|
deploy_files_from_image = true
|
||||||
deploy_files_from_common = true
|
deploy_files_from_common = true
|
||||||
use_incus = true
|
use_incus = false
|
||||||
packages = [
|
packages = [
|
||||||
"git",
|
"git",
|
||||||
"jq",
|
"jq",
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user