This commit is contained in:
parent
bff0b819e3
commit
27cd25a155
4 changed files with 33 additions and 8 deletions
|
@ -2,9 +2,7 @@ on:
|
||||||
push:
|
push:
|
||||||
tags:
|
tags:
|
||||||
- "latest"
|
- "latest"
|
||||||
- "v*"
|
|
||||||
env:
|
env:
|
||||||
IMAGE_TAG_PRIVATE: git.myservermanager.com/msm/forgejo-base-executor-image
|
|
||||||
FORGEJO_FQDN: git.myservermanager.com
|
FORGEJO_FQDN: git.myservermanager.com
|
||||||
jobs:
|
jobs:
|
||||||
build:
|
build:
|
||||||
|
@ -34,9 +32,18 @@ jobs:
|
||||||
username: ${{ secrets.FORGEJO_USER }}
|
username: ${{ secrets.FORGEJO_USER }}
|
||||||
password: ${{ secrets.FORGEJO_TOKEN }}
|
password: ${{ secrets.FORGEJO_TOKEN }}
|
||||||
|
|
||||||
- name: Build docker image
|
- name: Build docker image - base
|
||||||
uses: docker/build-push-action@v4
|
uses: docker/build-push-action@v4
|
||||||
with:
|
with:
|
||||||
|
file: Dockerfile
|
||||||
push: true
|
push: true
|
||||||
tags: |
|
tags: |
|
||||||
${{ env.IMAGE_TAG_PRIVATE }}:latest
|
git.myservermanager.com/msm/forgejo-base-executor-image:latest
|
||||||
|
|
||||||
|
- name: Build docker image - make cgo
|
||||||
|
uses: docker/build-push-action@v4
|
||||||
|
with:
|
||||||
|
file: Dockerfile-make-cgo
|
||||||
|
push: true
|
||||||
|
tags: |
|
||||||
|
git.myservermanager.com/msm/forgejo-base-executor-image-make-cgo:latest
|
||||||
|
|
|
@ -2,7 +2,6 @@ on:
|
||||||
schedule:
|
schedule:
|
||||||
- cron: "0 0 1 * *"
|
- cron: "0 0 1 * *"
|
||||||
env:
|
env:
|
||||||
IMAGE_TAG_PRIVATE: git.myservermanager.com/msm/forgejo-base-executor-image
|
|
||||||
FORGEJO_FQDN: git.myservermanager.com
|
FORGEJO_FQDN: git.myservermanager.com
|
||||||
jobs:
|
jobs:
|
||||||
build:
|
build:
|
||||||
|
@ -32,9 +31,18 @@ jobs:
|
||||||
username: ${{ secrets.FORGEJO_USER }}
|
username: ${{ secrets.FORGEJO_USER }}
|
||||||
password: ${{ secrets.FORGEJO_TOKEN }}
|
password: ${{ secrets.FORGEJO_TOKEN }}
|
||||||
|
|
||||||
- name: Build docker image
|
- name: Build docker image - base
|
||||||
uses: docker/build-push-action@v4
|
uses: docker/build-push-action@v4
|
||||||
with:
|
with:
|
||||||
|
file: Dockerfile
|
||||||
push: true
|
push: true
|
||||||
tags: |
|
tags: |
|
||||||
${{ env.IMAGE_TAG_PRIVATE }}:latest
|
git.myservermanager.com/msm/forgejo-base-executor-image:latest
|
||||||
|
|
||||||
|
- name: Build docker image - make cgo
|
||||||
|
uses: docker/build-push-action@v4
|
||||||
|
with:
|
||||||
|
file: Dockerfile-make-cgo
|
||||||
|
push: true
|
||||||
|
tags: |
|
||||||
|
git.myservermanager.com/msm/forgejo-base-executor-image-make-cgo:latest
|
||||||
|
|
|
@ -1,9 +1,11 @@
|
||||||
FROM ubuntu:24.04
|
FROM ubuntu:24.04
|
||||||
LABEL maintainer="msm <hostmaster@myservermanager.com>"
|
LABEL maintainer="msm <hostmaster@myservermanager.com>"
|
||||||
|
|
||||||
|
# base line required by Forgejo Runner: nodejs, npm, git
|
||||||
|
# added: docker and buildx
|
||||||
RUN <<EOF
|
RUN <<EOF
|
||||||
apt-get update
|
apt-get update
|
||||||
apt-get install -y --no-install-recommends curl wget bash apt-transport-https ca-certificates gnupg nodejs npm git zstd make clang
|
apt-get install -y --no-install-recommends curl wget bash apt-transport-https ca-certificates gnupg nodejs npm git zstd
|
||||||
curl -fsSL https://download.docker.com/linux/debian/gpg | gpg --dearmor -o /usr/share/keyrings/docker.gpg
|
curl -fsSL https://download.docker.com/linux/debian/gpg | gpg --dearmor -o /usr/share/keyrings/docker.gpg
|
||||||
echo "deb [arch=$(dpkg --print-architecture) signed-by=/usr/share/keyrings/docker.gpg] https://download.docker.com/linux/debian bookworm stable" | tee /etc/apt/sources.list.d/docker.list > /dev/null
|
echo "deb [arch=$(dpkg --print-architecture) signed-by=/usr/share/keyrings/docker.gpg] https://download.docker.com/linux/debian bookworm stable" | tee /etc/apt/sources.list.d/docker.list > /dev/null
|
||||||
apt-get update
|
apt-get update
|
||||||
|
|
8
Dockerfile-make-cgo
Normal file
8
Dockerfile-make-cgo
Normal file
|
@ -0,0 +1,8 @@
|
||||||
|
FROM git.myservermanager.com/msm/forgejo-base-executor-image
|
||||||
|
|
||||||
|
# added: make and clang for CGO compile
|
||||||
|
RUN <<EOF
|
||||||
|
apt-get update
|
||||||
|
apt-get install -y --no-install-recommends build-essential make clang
|
||||||
|
rm -rf /var/lib/apt/lists/\* /tmp/\* /var/tmp/*
|
||||||
|
EOF
|
Loading…
Reference in a new issue