commit 8e8703538393272f2806bafc509182d5fc2b1c44 Author: David Claeys Date: Fri Oct 30 11:16:35 2026 +0100 add initial commit and build action diff --git a/.gitea/workflows/action.yaml b/.gitea/workflows/action.yaml new file mode 100644 index 0000000..cc2a63f --- /dev/null +++ b/.gitea/workflows/action.yaml @@ -0,0 +1,68 @@ +name: Build JetKVM Cloud docker container +env: + UPSTREAM_DIR: ./upstream + +on: + push: + branches: + - main + paths: + - "upstream.conf" + + workflow_dispatch: + +jobs: + build: + runs-on: ubuntu-latest + defaults: + run: + working-directory: ${{ github.workspace }} + steps: + - name: Checkout + uses: actions/checkout@v4 + - name: Setup docker + uses: https://git.claeyscloud.com/david/gitea-actions/setup-docker@main + - name: Login to Gitea container registry + uses: https://github.com/docker/login-action@v3 + with: + registry: git.claeyscloud.com + username: nologin + password: ${{ secrets.PACKAGE_TOKEN }} + - name: Load upstream configuration + shell: bash + run: | + source upstream.conf + + echo "BRANCH=$BRANCH" >> "$GITHUB_ENV" + echo "COMMIT=$COMMIT" >> "$GITHUB_ENV" + echo "SHORT_COMMIT=${COMMIT:0:7}" >> "$GITHUB_ENV" + - name: Retrieve code + shell: bash + run: | + echo "Retrieving JetKVM cloud-api" + echo "Branch: $BRANCH" + echo "Commit: $COMMIT" + echo "Destination: $UPSTREAM_DIR" + + git clone --branch "$BRANCH" https://github.com/jetkvm/cloud-api.git "$UPSTREAM_DIR" + cd "$UPSTREAM_DIR" + git checkout "$COMMIT" + - name: Extract metadata (tags, labels) for Docker + id: meta + uses: docker/metadata-action@v5 + with: + labels: | + org.opencontainers.image.documentation=https://git.claeyscloud.com/david/jetkvm-cloud/README.md + images: | + git.claeyscloud.com/david/jetkvm-cloud + tags: | + type=raw,value=${{ env.BRANCH }} + type=raw,value=${{ env.SHORT_COMMIT }} + type=raw,value=latest + - name: Build and push + uses: https://github.com/docker/build-push-action@v5 + context: ${{ env.UPSTREAM_DIR }} + file: ${{ env.UPSTREAM_DIR }}/Dockerfile + push: true + tags: ${{ steps.meta.outputs.tags }} + labels: ${{ steps.meta.outputs.labels }} diff --git a/README.md b/README.md new file mode 100644 index 0000000..a7be737 --- /dev/null +++ b/README.md @@ -0,0 +1,5 @@ +# JetKVM Cloud +  +This repository provides prebuilt Docker images for the [JetKVM Cloud API](https://github.com/jetkvm/cloud-api). +  +These images make it easy to self-host JetKVM Cloud without having to build the Docker image yourself. \ No newline at end of file diff --git a/upstream.config b/upstream.config new file mode 100644 index 0000000..3a66047 --- /dev/null +++ b/upstream.config @@ -0,0 +1,2 @@ +BRANCH=main +COMMIT=ad33c712a4516b2e4e9941a77d6ba79f8747b4c5 \ No newline at end of file