Skip to content

Commit 5cafd24

Browse files
committed
Merge pull request 'feat: add obmondo repos upload workflow' (#186) from feat/add-obmondo-repos-upload into main
Reviewed-on: https://gitea.obmondo.com/EnableIT/Linuxaid-cli/pulls/186
2 parents 57e5297 + 28abff8 commit 5cafd24

2 files changed

Lines changed: 69 additions & 19 deletions

File tree

.gitea/workflows/release.yaml

Lines changed: 16 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,21 @@ jobs:
2626
uses: https://gitea.obmondo.com/Obmondo/goreleaser-action@v6.4.0
2727
with:
2828
version: "v2.12.7"
29-
args: release --clean -f .goreleaser-gitea.yaml
29+
args: release --clean --skip=archive,publish -f .goreleaser-gitea.yaml
3030
env:
3131
GITEA_TOKEN: ${{ secrets.GORELEASER_TOKEN }}
32+
- name: Upload to repo servers
33+
env:
34+
PUBLIC_PATH: /vol0/data/packagesign01_var/var/lib/packagesign/repos/incoming/public/
35+
USERNAME: ${{ secrets.PACKAGESIGN_USER }}
36+
SSH_KEY: ${{ secrets.PACKAGESIGN_SSH_KEY }}
37+
HOST: ${{ secrets.PACKAGESIGN_HOST }}
38+
run: |
39+
apt update && apt install -y rsync openssh-client
40+
echo "${SSH_KEY}" > /tmp/ssh_key
41+
chmod 600 /tmp/ssh_key
42+
eval $(ssh-agent)
43+
ssh-add /tmp/ssh_key
44+
echo "Uploading artifacts in dist/"
45+
ls -alh dist/
46+
rsync -azv dist/*.deb dist/*.rpm -e "ssh -o StrictHostKeyChecking=no" ${USERNAME}@${HOST}:${PUBLIC_PATH}

.goreleaser-gitea.yaml

Lines changed: 53 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,6 @@ archives:
3030
{{- .Tag }}_
3131
{{- .Os }}_
3232
{{- .Arch }}
33-
{{- if .Arm }}v{{ .Arm }}{{ end -}}
3433
builds_info:
3534
group: root
3635
owner: root
@@ -52,10 +51,6 @@ builds:
5251
goarch:
5352
- amd64
5453
- arm64
55-
- arm
56-
goarm:
57-
- "6"
58-
- "7"
5954
flags:
6055
- -v
6156
ldflags:
@@ -72,18 +67,15 @@ builds:
7267
goarch:
7368
- amd64
7469
- arm64
75-
- arm
76-
goarm:
77-
- "6"
78-
- "7"
7970
flags:
8071
- -v
8172
ldflags:
8273
- -X main.Version={{ .Tag }}
8374
- -s -w
8475

8576
nfpms:
86-
- id: linuxaid-cli-package
77+
# Deb
78+
- id: linuxaid-cli-package-deb
8779
package_name: linuxaid-cli
8880
ids:
8981
- linuxaid-cli
@@ -92,7 +84,6 @@ nfpms:
9284
{{- .Tag }}_
9385
{{- .Os }}_
9486
{{- .Arch }}
95-
{{- if .Arm }}v{{ .Arm }}{{ end -}}
9687
{{- .ConventionalExtension }}
9788
vendor: Obmondo
9889
homepage: https://gitea.obmondo.com/EnableIT/linuxaid-cli
@@ -103,12 +94,10 @@ nfpms:
10394
license: MIT
10495
formats:
10596
- deb
106-
- rpm
107-
- ipk
108-
bindir: /usr/bin
97+
bindir: /opt/obmondo/bin
10998
mtime: "{{ .CommitDate }}"
11099

111-
- id: linuxaid-install-package
100+
- id: linuxaid-install-package-deb
112101
package_name: linuxaid-install
113102
ids:
114103
- linuxaid-install
@@ -117,7 +106,6 @@ nfpms:
117106
{{- .Tag }}_
118107
{{- .Os }}_
119108
{{- .Arch }}
120-
{{- if .Arm }}v{{ .Arm }}{{ end -}}
121109
{{- .ConventionalExtension }}
122110
vendor: Obmondo
123111
homepage: https://gitea.obmondo.com/EnableIT/linuxaid-cli
@@ -128,9 +116,56 @@ nfpms:
128116
license: MIT
129117
formats:
130118
- deb
119+
bindir: /opt/obmondo/bin
120+
mtime: "{{ .CommitDate }}"
121+
122+
# Rpm
123+
- id: linuxaid-cli-package-rpm
124+
package_name: linuxaid-cli
125+
ids:
126+
- linuxaid-cli
127+
file_name_template: >-
128+
{{- .PackageName }}-
129+
{{- .Tag }}-
130+
{{- .Release }}-
131+
{{- .Os }}-
132+
{{- if eq .Arch "amd64" }}x86_64{{ else if eq .Arch "arm64" }}aarch64{{ else }}{{ .Arch }}{{ end }}
133+
{{- .ConventionalExtension }}
134+
vendor: Obmondo
135+
homepage: https://gitea.obmondo.com/EnableIT/linuxaid-cli
136+
maintainer: Obmondo <ops@obmondo.com>
137+
description: |-
138+
LinuxAid CLI tool.
139+
Command-line interface for LinuxAid.
140+
license: MIT
141+
release: "1"
142+
formats:
143+
- rpm
144+
bindir: /opt/obmondo/bin
145+
mtime: "{{ .CommitDate }}"
146+
147+
- id: linuxaid-install-package-rpm
148+
package_name: linuxaid-install
149+
ids:
150+
- linuxaid-install
151+
file_name_template: >-
152+
{{- .PackageName }}-
153+
{{- .Tag }}-
154+
{{- .Release }}-
155+
{{- .Os }}-
156+
{{- if eq .Arch "amd64" }}x86_64{{ else if eq .Arch "arm64" }}aarch64{{ else }}{{ .Arch }}{{ end }}
157+
{{- .ConventionalExtension }}
158+
vendor: Obmondo
159+
homepage: https://gitea.obmondo.com/EnableIT/linuxaid-cli
160+
maintainer: Obmondo <ops@obmondo.com>
161+
description: |-
162+
LinuxAid installer tool.
163+
Installation utility for Openvox via LinuxAid.
164+
license: MIT
165+
release: "1"
166+
formats:
131167
- rpm
132-
- ipk
133-
bindir: /usr/bin
168+
bindir: /opt/obmondo/bin
134169
mtime: "{{ .CommitDate }}"
135170

136171
gitea_urls:

0 commit comments

Comments
 (0)