From ac0e6b954ecb28a4a27365c46e4cf10cb3596fbe Mon Sep 17 00:00:00 2001 From: Snoweuph Date: Wed, 29 Jan 2025 14:12:42 +0100 Subject: [PATCH] Add Redot --- .forgejo/workflows/base.yml | 2 +- .forgejo/workflows/csharp.yml | 2 +- .forgejo/workflows/go.yml | 2 +- .forgejo/workflows/godot.yml | 6 +++--- .forgejo/workflows/java.yml | 2 +- .forgejo/workflows/js.yml | 2 +- .forgejo/workflows/lua.yml | 4 ++-- .forgejo/workflows/php.yml | 4 ++-- .forgejo/workflows/redot.yml | 38 +++++++++++++++++++++++++++++++++ images/actions/redot/Dockerfile | 13 +++++++++++ 10 files changed, 63 insertions(+), 12 deletions(-) create mode 100644 .forgejo/workflows/redot.yml create mode 100644 images/actions/redot/Dockerfile diff --git a/.forgejo/workflows/base.yml b/.forgejo/workflows/base.yml index 1d8daff..7025577 100644 --- a/.forgejo/workflows/base.yml +++ b/.forgejo/workflows/base.yml @@ -32,4 +32,4 @@ jobs: push: true tags: | git.euph.dev/actions/runner-basic:latest - git.euph.dev/actions/runner-basic:${{ gitea.run_number }} + git.euph.dev/actions/runner-basic:${{ forgejo.run_number }} diff --git a/.forgejo/workflows/csharp.yml b/.forgejo/workflows/csharp.yml index 27dfee8..6a94648 100644 --- a/.forgejo/workflows/csharp.yml +++ b/.forgejo/workflows/csharp.yml @@ -34,4 +34,4 @@ jobs: build-args: PACKAGE_VERSION=${{ matrix.version }} tags: | git.euph.dev/actions/runner-csharp-${{ matrix.version }}:latest - git.euph.dev/actions/runner-csharp-${{ matrix.version }}:${{ gitea.run_number }} + git.euph.dev/actions/runner-csharp-${{ matrix.version }}:${{ forgejo.run_number }} diff --git a/.forgejo/workflows/go.yml b/.forgejo/workflows/go.yml index 52d7dd9..80a1c65 100644 --- a/.forgejo/workflows/go.yml +++ b/.forgejo/workflows/go.yml @@ -31,4 +31,4 @@ jobs: push: true tags: | git.euph.dev/actions/runner-go:latest - git.euph.dev/actions/runner-go:${{ gitea.run_number }} + git.euph.dev/actions/runner-go:${{ forgejo.run_number }} diff --git a/.forgejo/workflows/godot.yml b/.forgejo/workflows/godot.yml index e6c3d88..7a71e07 100644 --- a/.forgejo/workflows/godot.yml +++ b/.forgejo/workflows/godot.yml @@ -6,7 +6,7 @@ on: push: branches: - 'master' - + jobs: build_godot: runs-on: 'priviliged' @@ -16,7 +16,7 @@ jobs: steps: - name: Install Docker run: | - rm $(which docker) && curl -fsSL https://get.docker.com | sh + rm $(which docker) && curl -fsSL https://get.docker.com | sh - name: Set up QEMU uses: 'https://git.euph.dev/actions/docker-setup-qemu@v3' - name: Setup Buildx @@ -35,4 +35,4 @@ jobs: build-args: PACKAGE_VERSION=${{ matrix.version }} tags: | git.euph.dev/actions/runner-godot-${{ matrix.version }}:latest - git.euph.dev/actions/runner-godot-${{ matrix.version }}:${{ gitea.run_number }} \ No newline at end of file + git.euph.dev/actions/runner-godot-${{ matrix.version }}:${{ forgejo.run_number }} diff --git a/.forgejo/workflows/java.yml b/.forgejo/workflows/java.yml index 7f63100..ab32fa4 100644 --- a/.forgejo/workflows/java.yml +++ b/.forgejo/workflows/java.yml @@ -35,4 +35,4 @@ jobs: build-args: PACKAGE_VERSION=${{ matrix.version }} tags: | git.euph.dev/actions/runner-java-${{ matrix.version }}:latest - git.euph.dev/actions/runner-java-${{ matrix.version }}:${{ gitea.run_number }} \ No newline at end of file + git.euph.dev/actions/runner-java-${{ matrix.version }}:${{ forgejo.run_number }} diff --git a/.forgejo/workflows/js.yml b/.forgejo/workflows/js.yml index 278eac0..3e43ec9 100644 --- a/.forgejo/workflows/js.yml +++ b/.forgejo/workflows/js.yml @@ -35,4 +35,4 @@ jobs: build-args: PACKAGE_VERSION=${{ matrix.version }} tags: | git.euph.dev/actions/runner-js-${{ matrix.version }}:latest - git.euph.dev/actions/runner-js-${{ matrix.version }}:${{ gitea.run_number }} + git.euph.dev/actions/runner-js-${{ matrix.version }}:${{ forgejo.run_number }} diff --git a/.forgejo/workflows/lua.yml b/.forgejo/workflows/lua.yml index 6dec8fa..d30db73 100644 --- a/.forgejo/workflows/lua.yml +++ b/.forgejo/workflows/lua.yml @@ -6,7 +6,7 @@ on: push: branches: - 'master' - + jobs: build_lua: runs-on: 'priviliged' @@ -35,4 +35,4 @@ jobs: build-args: PACKAGE_VERSION=${{ matrix.version }} tags: | git.euph.dev/actions/runner-lua-${{ matrix.version }}:latest - git.euph.dev/actions/runner-lua-${{ matrix.version }}:${{ gitea.run_number }} + git.euph.dev/actions/runner-lua-${{ matrix.version }}:${{ forgejo.run_number }} diff --git a/.forgejo/workflows/php.yml b/.forgejo/workflows/php.yml index d35338f..8ae415d 100644 --- a/.forgejo/workflows/php.yml +++ b/.forgejo/workflows/php.yml @@ -6,7 +6,7 @@ on: push: branches: - 'master' - + jobs: build_php: runs-on: 'priviliged' @@ -35,4 +35,4 @@ jobs: build-args: PACKAGE_VERSION=${{ matrix.version }} tags: | git.euph.dev/actions/runner-php-${{ matrix.version }}:latest - git.euph.dev/actions/runner-php-${{ matrix.version }}:${{ gitea.run_number }} \ No newline at end of file + git.euph.dev/actions/runner-php-${{ matrix.version }}:${{ forgejo.run_number }} diff --git a/.forgejo/workflows/redot.yml b/.forgejo/workflows/redot.yml new file mode 100644 index 0000000..cca14a1 --- /dev/null +++ b/.forgejo/workflows/redot.yml @@ -0,0 +1,38 @@ +name: Build Runner Redot + +on: + schedule: + - cron: '0 2 * * *' + push: + branches: + - 'master' + +jobs: + build_redot: + runs-on: 'priviliged' + strategy: + matrix: + version: [4.3] + steps: + - name: Install Docker + run: | + rm $(which docker) && curl -fsSL https://get.docker.com | sh + - name: Set up QEMU + uses: 'https://git.euph.dev/actions/docker-setup-qemu@v3' + - name: Setup Buildx + uses: 'https://git.euph.dev/actions/docker-setup-buildx@v3' + - name: Login to Registry + uses: 'https://git.euph.dev/actions/docker-login@v3' + with: + registry: git.euph.dev + username: ${{ secrets.DEPLOY_USER }} + password: ${{ secrets.DEPLOY_SECRET }} + - name: Build and push Godot image + uses: 'https://git.euph.dev/actions/docker-build-push@v5' + with: + context: "{{defaultContext}}:images/actions/redot" + push: true + build-args: PACKAGE_VERSION=${{ matrix.version }} + tags: | + git.euph.dev/actions/runner-redot-${{ matrix.version }}:latest + git.euph.dev/actions/runner-redot-${{ matrix.version }}:${{ forgejo.run_number }} diff --git a/images/actions/redot/Dockerfile b/images/actions/redot/Dockerfile new file mode 100644 index 0000000..e6822ca --- /dev/null +++ b/images/actions/redot/Dockerfile @@ -0,0 +1,13 @@ +FROM git.euph.dev/actions/runner-basic:latest + +ARG PACKAGE_VERSION + +RUN wget $( \ + curl -s https://api.github.com/repos/Redot-Engine/redot-engine/releases/tags/$PACKAGE_VERSION-stable \ + | grep "browser_download_url.*Redot_v.*-stable_linux_x86_64.zip" \ + | cut -d '"' -f 4 - \ + | head -n 1 \ + ) -O Redot.zip \ + && sudo unzip Redot.zip \ + && sudo mv ./Redot_v*-stable_linux_x86_64/Redot_v*-stable_linux.x86_64 /usr/local/bin/redot \ + && rm Redot.zip