Remove everything except docker image
All checks were successful
Build and push docker image / build (push) Successful in 7m17s

This commit is contained in:
2026-01-19 04:26:23 +04:00
parent b1b4afb74c
commit 86551b78bb
58 changed files with 43 additions and 3927 deletions

View File

@@ -0,0 +1,42 @@
name: Build and push docker image
on:
push:
branches: master
concurrency:
group: "${{ gitea.workflow }}-${{ gitea.repository }}"
cancel-in-progress: true
jobs:
build:
if: gitea.event.pull_request.draft == false
runs-on: ubuntu-latest
env:
DOCKER_REGISTRY: git.aww.cloud
DOCKER_IMAGE: git.aww.cloud/${{ gitea.repository }}
steps:
- name: Login to Registry
uses: docker/login-action@v2
with:
registry: ${{ env.DOCKER_REGISTRY }}
username: ${{ secrets.DOCKER_REGISTRY_USERNAME }}
password: ${{ secrets.DOCKER_REGISTRY_PASSWORD }}
- name: Checkout repo
uses: actions/checkout@v4
- name: Build Docker Image
run: |
# Build the image with the commit hash tag
docker build -t ${{ env.DOCKER_IMAGE }}:${{ gitea.sha }} .
docker tag ${{ env.DOCKER_IMAGE }}:${{ gitea.sha }} ${{ env.DOCKER_IMAGE }}:latest
- name: Push Docker Images
run: |
docker push ${{ env.DOCKER_IMAGE }}:${{ gitea.sha }}
docker push ${{ env.DOCKER_IMAGE }}:latest
- name: Log out from registry
if: always()
run: docker logout ${{ env.DOCKER_REGISTRY }}

View File

@@ -1,51 +0,0 @@
name: "Check Releases"
on:
schedule:
- cron: '27 23 * * *'
push:
branches:
- master
jobs:
fetch:
name: Fetch Latest Godot Engine Release
runs-on: ubuntu-24.04
outputs:
release_tag: ${{ steps.parse.outputs.tag }}
steps:
- id: parse
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
TAG=$(gh release view --repo godotengine/godot --json tagName --jq .tagName)
echo "tag=$TAG" >> $GITHUB_OUTPUT
current:
name: Fetch Current Godot CI release
runs-on: ubuntu-24.04
outputs:
release_tag: ${{ steps.parse.outputs.tag }}
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0
- id: parse
run: echo "tag=$(git tag --list --sort=-creatordate | head --lines 1)" >> $GITHUB_OUTPUT
create:
needs: [fetch, current]
name: Create New Godot CI Release
runs-on: ubuntu-24.04
if: needs.fetch.outputs.release_tag != needs.current.outputs.release_tag
steps:
- uses: actions/checkout@v3
- run: gh release view --repo godotengine/godot --json body --jq .body | sed 's/\\r\\n/\n/g' > body.txt
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- run: |
git config user.name github-actions
git config user.email github-actions@github.com
git tag ${{ needs.fetch.outputs.release_tag }}
git push
- uses: softprops/action-gh-release@v0.1.14
with:
body_path: body.txt
tag_name: ${{ needs.fetch.outputs.release_tag }}
token: ${{ secrets.PAT }}

View File

@@ -1,124 +0,0 @@
name: "godot-ci export"
on: push
# NOTE: If your `project.godot` is at the repository root, set `PROJECT_PATH` below to ".".
env:
GODOT_VERSION: 4.3
EXPORT_NAME: test-project
PROJECT_PATH: test-project
jobs:
export-windows:
name: Windows Export
runs-on: ubuntu-24.04 # Use 24.04 with godot 4
container:
image: barichello/godot-ci:4.3
steps:
- name: Checkout
uses: actions/checkout@v4
with:
lfs: true
- name: Setup
run: |
mkdir -v -p ~/.local/share/godot/export_templates/
mkdir -v -p ~/.config/
mv /root/.config/godot ~/.config/godot
mv /root/.local/share/godot/export_templates/${GODOT_VERSION}.stable ~/.local/share/godot/export_templates/${GODOT_VERSION}.stable
- name: Windows Build
run: |
mkdir -v -p build/windows
EXPORT_DIR="$(readlink -f build)"
cd $PROJECT_PATH
godot --headless --verbose --export-release "Windows Desktop" "$EXPORT_DIR/windows/$EXPORT_NAME.exe"
- name: Upload Artifact
uses: actions/upload-artifact@v4
with:
name: windows
path: build/windows
export-linux:
name: Linux Export
runs-on: ubuntu-24.04 # Use 24.04 with godot 4
container:
image: barichello/godot-ci:4.3
steps:
- name: Checkout
uses: actions/checkout@v4
with:
lfs: true
- name: Setup
run: |
mkdir -v -p ~/.local/share/godot/export_templates/
mv /root/.local/share/godot/export_templates/${GODOT_VERSION}.stable ~/.local/share/godot/export_templates/${GODOT_VERSION}.stable
- name: Linux Build
run: |
mkdir -v -p build/linux
EXPORT_DIR="$(readlink -f build)"
cd $PROJECT_PATH
godot --headless --verbose --export-release "Linux/X11" "$EXPORT_DIR/linux/$EXPORT_NAME.x86_64"
- name: Upload Artifact
uses: actions/upload-artifact@v4
with:
name: linux
path: build/linux
export-web:
name: Web Export
runs-on: ubuntu-24.04 # Use 24.04 with godot 4
container:
image: barichello/godot-ci:4.3
steps:
- name: Checkout
uses: actions/checkout@v4
with:
lfs: true
- name: Setup
run: |
mkdir -v -p ~/.local/share/godot/export_templates/
mv /root/.local/share/godot/export_templates/${GODOT_VERSION}.stable ~/.local/share/godot/export_templates/${GODOT_VERSION}.stable
- name: Web Build
run: |
mkdir -v -p build/web
EXPORT_DIR="$(readlink -f build)"
cd $PROJECT_PATH
godot --headless --verbose --export-release "Web" "$EXPORT_DIR/web/index.html"
- name: Upload Artifact
uses: actions/upload-artifact@v4
with:
name: web
path: build/web
- name: Install rsync 📚
run: |
apt-get update && apt-get install -y rsync
- name: Deploy to GitHub Pages 🚀
uses: JamesIves/github-pages-deploy-action@releases/v4
with:
branch: gh-pages # The branch the action should deploy to.
folder: build/web # The folder the action should deploy.
export-mac:
name: Mac Export
runs-on: ubuntu-24.04 # Use 24.04 with godot 4
container:
image: barichello/godot-ci:4.3
steps:
- name: Checkout
uses: actions/checkout@v4
with:
lfs: true
- name: Setup
run: |
mkdir -v -p ~/.local/share/godot/export_templates/
mv /root/.local/share/godot/export_templates/${GODOT_VERSION}.stable ~/.local/share/godot/export_templates/${GODOT_VERSION}.stable
- name: Mac Build
run: |
mkdir -v -p build/mac
EXPORT_DIR="$(readlink -f build)"
cd $PROJECT_PATH
godot --headless --verbose --export-release "macOS" "$EXPORT_DIR/mac/$EXPORT_NAME.zip"
- name: Upload Artifact
uses: actions/upload-artifact@v4
with:
name: mac
path: build/mac

View File

@@ -1,158 +0,0 @@
name: Manual Build
on:
workflow_dispatch:
inputs:
version:
description: 'Version of engine to build e.g. "3.4.4", "3.5"'
required: true
type: string
release_name:
description: 'Release name, usually "stable", but can also be something like "rc3", "beta1"'
type: string
default: "stable"
required: true
set_latest:
description: 'Tag as latest'
type: boolean
default: false
env:
IMAGE_NAME: godot-ci
jobs:
version:
name: Get Version
runs-on: ubuntu-24.04
outputs:
dotnet_version: ${{ steps.calculate.outputs.dotnet_version }}
steps:
- id: calculate
run: |
MAJOR_VERSION=$(echo ${{ github.event.inputs.version }} | cut -c -1)
MINOR_VERSION=$(echo ${{ github.event.inputs.version }} | cut -c -3)
if [ "$MAJOR_VERSION" = "3" ]
then
echo "dotnet_version=mono:latest" >> $GITHUB_OUTPUT
elif [ "$MINOR_VERSION" = "4.0" ] || [ "$MINOR_VERSION" = "4.1" ] || [ "$MINOR_VERSION" = "4.2" ] || [ "$MINOR_VERSION" = "4.3" ]
then
echo "dotnet_version=mcr.microsoft.com/dotnet/sdk:6.0-jammy" >> $GITHUB_OUTPUT
elif [ "$MINOR_VERSION" = "4.4" ]
then
echo "dotnet_version=mcr.microsoft.com/dotnet/sdk:8.0-jammy" >> $GITHUB_OUTPUT
else
echo "dotnet_version=mcr.microsoft.com/dotnet/sdk:9.0-noble" >> $GITHUB_OUTPUT
fi
get_tags:
name: Get Tags
runs-on: ubuntu-24.04
outputs:
tags: ${{steps.write_tags.outputs.tags}}
tags_mono: ${{steps.write_tags_mono.outputs.tags}}
steps:
- run: echo IMAGE_OWNER=$(echo ${{ github.repository_owner }} | tr '[:upper:]' '[:lower:]') >> $GITHUB_ENV
- run: echo IMAGE_TAG=$(echo ${{ github.event.inputs.release_name != 'stable' && format('.{0}', github.event.inputs.release_name) || '' }}) >> $GITHUB_ENV
- name: Set tags
run: |
echo "ghcr.io/${{ env.IMAGE_OWNER }}/${{ env.IMAGE_NAME }}:${{ github.event.inputs.version }}${{ env.IMAGE_TAG }}" >> tags.txt
echo "${{ secrets.DOCKERHUB_USERNAME }}/${{ env.IMAGE_NAME }}:${{ github.event.inputs.version }}${{ env.IMAGE_TAG }}" >> tags.txt
- name: Set latest tags
if: ${{inputs.set_latest}}
run: |
echo "ghcr.io/${{ env.IMAGE_OWNER }}/${{ env.IMAGE_NAME }}:latest" >> tags.txt
echo "${{ secrets.DOCKERHUB_USERNAME }}/${{ env.IMAGE_NAME }}:latest" >> tags.txt
- name: Set Mono tags
run: |
echo "ghcr.io/${{ env.IMAGE_OWNER }}/${{ env.IMAGE_NAME }}:mono-${{ github.event.inputs.version }}${{ env.IMAGE_TAG }}" >> tags_mono.txt
echo "${{ secrets.DOCKERHUB_USERNAME }}/${{ env.IMAGE_NAME }}:mono-${{ github.event.inputs.version }}${{ env.IMAGE_TAG }}" >> tags_mono.txt
- name: Set Mono latest tags
if: ${{inputs.set_latest}}
run: |
echo "ghcr.io/${{ env.IMAGE_OWNER }}/${{ env.IMAGE_NAME }}:mono-latest" >> tags_mono.txt
echo "${{ secrets.DOCKERHUB_USERNAME }}/${{ env.IMAGE_NAME }}:mono-latest" >> tags_mono.txt
- uses: actions/upload-artifact@v4
with:
name: image_tags
path: tags.txt
retention-days: 1
- uses: actions/upload-artifact@v4
with:
name: image_tags_mono
path: tags_mono.txt
retention-days: 1
build:
name: Build Image
runs-on: ubuntu-24.04
needs: get_tags
steps:
- uses: actions/download-artifact@v4
with:
name: image_tags
- run: |
{
echo 'TAGS<<EOF'
cat tags.txt
echo EOF
} >> "$GITHUB_ENV"
- uses: actions/checkout@v3
- name: Login to GitHub Container Registry
uses: docker/login-action@v1.14.1
with:
registry: ghcr.io
username: ${{ github.repository_owner }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Login to DockerHub
uses: docker/login-action@v1
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: Build and push Docker images
uses: docker/build-push-action@v2.9.0
with:
context: .
file: Dockerfile
push: true
tags: ${{ env.TAGS }}
build-args: |
GODOT_VERSION=${{ github.event.inputs.version }}
RELEASE_NAME=${{ github.event.inputs.release_name }}
SUBDIR=${{ github.event.inputs.release_name != 'stable' && format('/{0}', github.event.inputs.release_name) || '' }}
GODOT_TEST_ARGS=${{ startsWith( github.event.inputs.version, '3.' ) && '' || '--headless --quit' }}
GODOT_PLATFORM=${{ startsWith( github.event.inputs.version, '3.' ) && 'linux_headless.64' || 'linux.x86_64' }}
build-mono:
name: Build Mono Image
runs-on: ubuntu-24.04
needs: [version, get_tags]
steps:
- uses: actions/download-artifact@v4
with:
name: image_tags_mono
- run: |
{
echo 'TAGS<<EOF'
cat tags_mono.txt
echo EOF
} >> "$GITHUB_ENV"
- uses: actions/checkout@v3
- name: Login to GitHub Container Registry
uses: docker/login-action@v1.14.1
with:
registry: ghcr.io
username: ${{ github.repository_owner }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Login to DockerHub
uses: docker/login-action@v1
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: Build and push Docker images
uses: docker/build-push-action@v2.9.0
with:
context: .
file: mono.Dockerfile
push: true
tags: ${{ env.TAGS }}
build-args: |
IMAGE=${{ needs.version.outputs.dotnet_version }}
GODOT_VERSION=${{ github.event.inputs.version }}
RELEASE_NAME=${{ github.event.inputs.release_name }}
SUBDIR=${{ github.event.inputs.release_name != 'stable' && format('/{0}', github.event.inputs.release_name) || '' }}
ZIP_GODOT_PLATFORM=${{ startsWith( github.event.inputs.version, '3.' ) && 'linux_headless_64' || 'linux_x86_64' }}
FILENAME_GODOT_PLATFORM=${{ startsWith( github.event.inputs.version, '3.' ) && 'linux_headless.64' || 'linux.x86_64' }}

View File

@@ -1,101 +0,0 @@
name: Release
on:
release:
types: [released]
env:
IMAGE_NAME: godot-ci
jobs:
version:
name: Get Version
runs-on: ubuntu-24.04
outputs:
version: ${{ steps.calculate.outputs.version }}
release_name: ${{ steps.calculate.outputs.release_name }}
dotnet_version: ${{ steps.calculate.outputs.dotnet_version }}
steps:
- id: calculate
run: |
REF_NAME=${{ github.ref_name }}
echo "version=${REF_NAME%-*}" >> $GITHUB_OUTPUT
echo "release_name=${REF_NAME#*-}" >> $GITHUB_OUTPUT
MAJOR_VERSION=$(echo ${REF_NAME%-*} | cut -c -1)
MINOR_VERSION=$(echo ${REF_NAME%-*} | cut -c -3)
if [ "$MAJOR_VERSION" = "3" ]
then
echo "dotnet_version=mono:latest" >> $GITHUB_OUTPUT
elif [ "$MINOR_VERSION" = "4.0" ] || [ "$MINOR_VERSION" = "4.1" ] || [ "$MINOR_VERSION" = "4.2" ] || [ "$MINOR_VERSION" = "4.3" ]
then
echo "dotnet_version=mcr.microsoft.com/dotnet/sdk:6.0-jammy" >> $GITHUB_OUTPUT
else
echo "dotnet_version=mcr.microsoft.com/dotnet/sdk:8.0-jammy" >> $GITHUB_OUTPUT
fi
build:
name: Build Image
runs-on: ubuntu-24.04
needs: [version]
steps:
- uses: actions/checkout@v3
- run: echo IMAGE_OWNER=$(echo ${{ github.repository_owner }} | tr '[:upper:]' '[:lower:]') >> $GITHUB_ENV
- name: Login to GitHub Container Registry
uses: docker/login-action@v1.14.1
with:
registry: ghcr.io
username: ${{ github.repository_owner }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Login to DockerHub
uses: docker/login-action@v1
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: Build and push Docker images
uses: docker/build-push-action@v2.9.0
with:
context: .
file: Dockerfile
push: true
tags: |
ghcr.io/${{ env.IMAGE_OWNER }}/${{ env.IMAGE_NAME }}:${{ needs.version.outputs.version }}
ghcr.io/${{ env.IMAGE_OWNER }}/${{ env.IMAGE_NAME }}:latest
${{ secrets.DOCKERHUB_USERNAME }}/${{ env.IMAGE_NAME }}:latest
${{ secrets.DOCKERHUB_USERNAME }}/${{ env.IMAGE_NAME }}:${{ needs.version.outputs.version }}
build-args: |
GODOT_VERSION=${{ needs.version.outputs.version }}
RELEASE_NAME=${{ needs.version.outputs.release_name }}
GODOT_TEST_ARGS=${{ startsWith( needs.version.outputs.version, '3.' ) && '' || '--headless --quit' }}
GODOT_PLATFORM=${{ startsWith( needs.version.outputs.version, '3.' ) && 'linux_headless.64' || 'linux.x86_64' }}
build-mono:
name: Build Mono Image
runs-on: ubuntu-24.04
needs: [version]
steps:
- uses: actions/checkout@v3
- run: echo IMAGE_OWNER=$(echo ${{ github.repository_owner }} | tr '[:upper:]' '[:lower:]') >> $GITHUB_ENV
- name: Login to GitHub Container Registry
uses: docker/login-action@v1.14.1
with:
registry: ghcr.io
username: ${{ github.repository_owner }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Login to DockerHub
uses: docker/login-action@v1
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: Build and push Docker images
uses: docker/build-push-action@v2.9.0
with:
context: .
file: mono.Dockerfile
push: true
tags: |
ghcr.io/${{ env.IMAGE_OWNER }}/${{ env.IMAGE_NAME }}:mono-${{ needs.version.outputs.version }}
ghcr.io/${{ env.IMAGE_OWNER }}/${{ env.IMAGE_NAME }}:mono-latest
${{ secrets.DOCKERHUB_USERNAME }}/${{ env.IMAGE_NAME }}:mono-latest
${{ secrets.DOCKERHUB_USERNAME }}/${{ env.IMAGE_NAME }}:mono-${{ needs.version.outputs.version }}
build-args: |
IMAGE=${{ needs.version.outputs.dotnet_version }}
GODOT_VERSION=${{ needs.version.outputs.version }}
RELEASE_NAME=${{ needs.version.outputs.release_name }}
ZIP_GODOT_PLATFORM=${{ startsWith( needs.version.outputs.version, '3.' ) && 'linux_headless_64' || 'linux_x86_64' }}
FILENAME_GODOT_PLATFORM=${{ startsWith( needs.version.outputs.version, '3.' ) && 'linux_headless.64' || 'linux.x86_64' }}