Adapted release Pipeline
Some checks failed
Build Docker Linux ARM64 Release / build-docker-linux-arm64-release (push) Failing after 4m42s
Build ARM64 Linux / build-arm64 (push) Has been cancelled
Build Docker Linux ARM64 / build-docker-linux-arm64 (push) Has been cancelled
Build Linux x64 / build-linux-x64 (push) Has been cancelled
Build Windows x64 / build-windows-x64 (push) Has been cancelled
Some checks failed
Build Docker Linux ARM64 Release / build-docker-linux-arm64-release (push) Failing after 4m42s
Build ARM64 Linux / build-arm64 (push) Has been cancelled
Build Docker Linux ARM64 / build-docker-linux-arm64 (push) Has been cancelled
Build Linux x64 / build-linux-x64 (push) Has been cancelled
Build Windows x64 / build-windows-x64 (push) Has been cancelled
This commit is contained in:
@@ -1,103 +1,37 @@
|
||||
name: Build Docker Linux ARM64 Release
|
||||
run-name: Release-Docker-Linux-ARM64
|
||||
|
||||
on:
|
||||
push:
|
||||
tags:
|
||||
- 'v*'
|
||||
on: [push]
|
||||
|
||||
jobs:
|
||||
build-docker-linux-arm64-release:
|
||||
runs-on: [self-hosted, linux, arm64, docker]
|
||||
|
||||
permissions:
|
||||
contents: write
|
||||
packages: write
|
||||
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Install required packages
|
||||
shell: bash
|
||||
run: |
|
||||
set -e
|
||||
if command -v apk >/dev/null 2>&1; then
|
||||
echo "Using apk (Alpine)"
|
||||
apk add --no-cache \
|
||||
git curl wget unzip bash nodejs npm docker
|
||||
elif command -v apt-get >/dev/null 2>&1; then
|
||||
echo "Using apt (Debian/Ubuntu)"
|
||||
sudo apt-get update
|
||||
sudo apt-get install -y \
|
||||
git curl wget unzip bash nodejs npm docker.io
|
||||
else
|
||||
echo "Unsupported OS package manager"
|
||||
exit 1
|
||||
fi
|
||||
- name: Updating apt-get
|
||||
run: apt-get update -y
|
||||
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v4
|
||||
- name: Install packages
|
||||
run: apt-get install git curl wget unzip bash nodejs npm docker -y
|
||||
|
||||
# Login to Gitea Container Registry
|
||||
- name: Login to Gitea Container Registry
|
||||
uses: docker/login-action@v3
|
||||
- name: Login container registry
|
||||
run: docker login gitea.penry.de
|
||||
|
||||
- name: Setup .NET10
|
||||
uses: actions/setup-dotnet@v3
|
||||
with:
|
||||
registry: http://172.19.0.2:3000
|
||||
username: ${{ github.actor }}
|
||||
password: ${{ secrets.GITHUB_TOKEN }}
|
||||
dotnet-version: '10.0.x'
|
||||
|
||||
# Docker metadata
|
||||
- name: Extract Docker metadata
|
||||
id: meta
|
||||
uses: docker/metadata-action@v5
|
||||
- name: Clone the repository
|
||||
run: actions/checkout@v4
|
||||
|
||||
- name: Build Linux ARM64 Docker Image
|
||||
run: docker build -t gitea.penry.de/couchlog/linux-arm64 .
|
||||
|
||||
- name: Make Tar from image
|
||||
run: docker save -o couchlog-linux-arm64.tar gitea.penry.de/couchlog/linux-arm64
|
||||
|
||||
- name: Release
|
||||
uses: akkuman/gitea-release-action@v1
|
||||
with:
|
||||
images: ${{ github.server_url }}/${{ github.repository }}
|
||||
tags: |
|
||||
type=ref,event=tag
|
||||
type=raw,value=latest
|
||||
|
||||
# Buildx
|
||||
- name: Setup Docker Buildx
|
||||
uses: docker/setup-buildx-action@v3
|
||||
|
||||
# Build & Push
|
||||
- name: Build and Push Docker Image
|
||||
uses: docker/build-push-action@v6
|
||||
with:
|
||||
context: .
|
||||
platforms: linux/arm64
|
||||
push: true
|
||||
tags: ${{ steps.meta.outputs.tags }}
|
||||
labels: ${{ steps.meta.outputs.labels }}
|
||||
|
||||
# Build local image for tarball
|
||||
- name: Build local Docker image
|
||||
run: docker build -t couchlog-linux-arm64 .
|
||||
|
||||
- name: Save Docker image as tar
|
||||
run: docker save couchlog-linux-arm64 -o CouchLog-Linux-ARM64-Docker-Image.tar
|
||||
|
||||
# Create Release (Gitea compatible)
|
||||
- name: Create Release
|
||||
id: create_release
|
||||
uses: actions/create-release@v1
|
||||
env:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
with:
|
||||
tag_name: ${{ github.ref_name }}
|
||||
release_name: ${{ github.ref_name }}
|
||||
draft: false
|
||||
prerelease: false
|
||||
body: |
|
||||
## Docker Image (ARM64)
|
||||
|
||||
```bash
|
||||
docker pull ${{ github.server_url }}/${{ github.repository }}:${{ github.ref_name }}
|
||||
```
|
||||
|
||||
- name: Upload Docker Image Tarball
|
||||
uses: actions/upload-release-asset@v1
|
||||
env:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
with:
|
||||
upload_url: ${{ steps.create_release.outputs.upload_url }}
|
||||
asset_path: CouchLog-Linux-ARM64-Docker-Image.tar
|
||||
asset_name: CouchLog-Linux-ARM64-Docker-Image.tar
|
||||
asset_content_type: application/x-tar
|
||||
files: |-
|
||||
couchlog-linux-arm64.tar
|
||||
Reference in New Issue
Block a user