Skip to content

Commit

Permalink
build rpm
Browse files Browse the repository at this point in the history
Signed-off-by: liulanzheng <[email protected]>
  • Loading branch information
liulanzheng committed Oct 23, 2024
1 parent 34588b4 commit cc88587
Show file tree
Hide file tree
Showing 3 changed files with 90 additions and 1 deletion.
38 changes: 37 additions & 1 deletion .github/workflows/buildx-package.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,4 +29,40 @@ jobs:
name: Create
run: |
make binaries
ls -l bin/build/
ls -l bin/build/
-
name: Package
run: |
echo 'deb [trusted=yes] https://repo.goreleaser.com/apt/ /' | sudo tee /etc/apt/sources.list.d/goreleaser.list
apt update
apt install -y nfpm
mkdir -p release_package
nfpm pkg --packager rpm --target release_package/
ls -l release_package/
-
name: Upload
uses: actions/upload-artifact@v4
with:
name: releases
path: release_package/*/*

acr-release:
name: ACR Release
runs-on: ubuntu-latest
needs: [build]
steps:
- name: Download builds and release notes
uses: actions/download-artifact@v4
- name: Display downloaded files
shell: bash
run: ls -l releases/*/
- name: Create Release
uses: "marvinpinto/action-automatic-releases@latest"
with:
repo_token: "${{ secrets.GITHUB_TOKEN }}"
automatic_release_tag: "latest"
prerelease: true
title: "ACR Release"
files: |
releases/*/*
22 changes: 22 additions & 0 deletions buildkit-overlaybd.service
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
[Unit]
Description=buildkit-overlaybd service
After=network.target local-fs.target
Before=shutdown.target
DefaultDependencies=no
Conflicts=shutdown.target

[Service]
LimitNOFILE=1048576
LimitCORE=infinity
Type=simple
ExecStartPre=overlay
ExecStart=/usr/bin/buildkit --oci-worker-snapshotter=overlaybd --oci-worker-proxy-snapshotter-path=/run/overlaybd-snapshotter/overlaybd.sock

GuessMainPID=no
Restart=always
RestartSec=1s
KillMode=process
OOMScoreAdjust=-999

[Install]
WantedBy=multi-user.target
31 changes: 31 additions & 0 deletions nfpm.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
# nfpm example config file
#
# check https://nfpm.goreleaser.com/configuration for detailed usage
#
name: "buildkit-overlaybd"
arch: amd64
platform: linux
version: 0.1.0
release: 1
section: "default"
priority: "extra"

maintainer: "overlaybd authors"
description: |
Buildkit for Overlaybd
vendor: "overlaybd"
homepage: "https://github.com/data-accelerator/buildkit"
license: "Apache-2.0"
contents:
- src: ./bin/build/*
dst: /usr/bin/
- src: ./dadi-gen
dst: /usr/bin/dadi-gen
- src: ./buildkit-overlaybd.service
dst: /opt/overlaybd/buildkit-overlaybd.service
type: config
overrides:
rpm:
scripts:
deb:
scripts:

0 comments on commit cc88587

Please sign in to comment.