Compare commits
4 commits
Author | SHA1 | Date | |
---|---|---|---|
4c4f5e4322 | |||
731b70f9e6 | |||
425cc54356 | |||
060942051f |
5 changed files with 35 additions and 48 deletions
|
@ -1,4 +1,6 @@
|
|||
---
|
||||
name: 'main'
|
||||
|
||||
on:
|
||||
push:
|
||||
workflow_dispatch:
|
||||
|
@ -17,7 +19,7 @@ jobs:
|
|||
- name: 'check'
|
||||
run: |
|
||||
make check no-dirty
|
||||
build:
|
||||
main:
|
||||
if: "${{ startsWith(github.ref, 'refs/tags/') }}"
|
||||
needs:
|
||||
- 'test'
|
||||
|
@ -34,44 +36,8 @@ jobs:
|
|||
make build
|
||||
env:
|
||||
GIT_CRYPT_SECRET: '${{ secrets.GIT_CRYPT }}'
|
||||
#- uses: 'actions/upload-artifact@v4'
|
||||
- uses: 'forgejo/upload-artifact@v4'
|
||||
with:
|
||||
if-no-files-found: 'error'
|
||||
name: 'ods'
|
||||
path: 'ods'
|
||||
deploy:
|
||||
needs:
|
||||
- 'build'
|
||||
runs-on: 'self-hosted'
|
||||
steps:
|
||||
#- uses: 'actions/download-artifact@v4'
|
||||
- uses: 'forgejo/download-artifact@v4'
|
||||
with:
|
||||
name: 'ods'
|
||||
- run: |
|
||||
umask 077
|
||||
printf '%s' "$SSH_PRIVATE_KEY" | base64 -d > private_key
|
||||
SSHOPTS="-i private_key -o StrictHostKeyChecking=accept-new"
|
||||
rsync -e "ssh ${SSHOPTS}" ods ods@ods.adyxax.org:
|
||||
ssh ${SSHOPTS} ods@ods.adyxax.org "chmod +x ods; systemctl --user restart ods"
|
||||
- name: 'deploy'
|
||||
run: |
|
||||
make deploy
|
||||
env:
|
||||
SSH_PRIVATE_KEY: '${{ secrets.SSH_PRIVATE_KEY }}'
|
||||
publish:
|
||||
needs:
|
||||
- 'build'
|
||||
runs-on: 'self-hosted'
|
||||
steps:
|
||||
#- uses: 'actions/download-artifact@v4'
|
||||
- uses: 'forgejo/download-artifact@v4'
|
||||
with:
|
||||
name: 'ods'
|
||||
- uses: 'actions/forgejo-release@v2'
|
||||
with:
|
||||
direction: 'upload'
|
||||
tag: '${{ github.ref_name }}'
|
||||
sha: '${{ github.sha }}'
|
||||
release-dir: './'
|
||||
token: '${{ env.GITHUB_TOKEN }}'
|
||||
hide-archive-link: true
|
||||
prerelease: true
|
||||
|
|
16
CHANGELOG.md
16
CHANGELOG.md
|
@ -2,11 +2,23 @@
|
|||
|
||||
All notable changes to this project will be documented in this file.
|
||||
|
||||
## 1.0.1 - 2024-04-07
|
||||
## 1.0.3 - 2025-06-06
|
||||
|
||||
### Changed
|
||||
|
||||
- Upgrade dependencies.
|
||||
- Updated dependencies.
|
||||
|
||||
## 1.0.2 - 2025-05-11
|
||||
|
||||
### Changed
|
||||
|
||||
- Updated dependencies.
|
||||
|
||||
## 1.0.1 - 2025-04-07
|
||||
|
||||
### Changed
|
||||
|
||||
- Updated dependencies.
|
||||
|
||||
## 1.0.0 - 2025-03-15
|
||||
|
||||
|
|
13
GNUmakefile
13
GNUmakefile
|
@ -37,8 +37,17 @@ push: tidy no-dirty check ## push changes to git remote
|
|||
|
||||
.PHONY: deploy
|
||||
deploy: build ## deploy changes to the production server
|
||||
rsync ./ods ods@ods.adyxax.org:
|
||||
ssh ods@ods.adyxax.org "systemctl --user restart ods"
|
||||
umask 077
|
||||
if [ -n "$${SSH_PRIVATE_KEY:-}" ]; then
|
||||
cleanup() {
|
||||
rm -f private_key
|
||||
}
|
||||
trap cleanup EXIT
|
||||
printf '%s' "$$SSH_PRIVATE_KEY" | base64 -d > private_key
|
||||
SSHOPTS="-i private_key -o StrictHostKeyChecking=accept-new"
|
||||
fi
|
||||
rsync -e "ssh $${SSHOPTS:-}" ./ods ods@ods.adyxax.org:
|
||||
ssh $${SSHOPTS:-} ods@ods.adyxax.org "chmod +x ods; systemctl --user restart ods"
|
||||
|
||||
##### Utils ####################################################################
|
||||
.PHONY: confirm
|
||||
|
|
4
go.mod
4
go.mod
|
@ -1,5 +1,5 @@
|
|||
module git.adyxax.org/adyxax/ods
|
||||
|
||||
go 1.24.2
|
||||
go 1.24.4
|
||||
|
||||
require golang.org/x/text v0.24.0
|
||||
require golang.org/x/text v0.26.0
|
||||
|
|
4
go.sum
4
go.sum
|
@ -1,2 +1,2 @@
|
|||
golang.org/x/text v0.24.0 h1:dd5Bzh4yt5KYA8f9CJHCP4FB4D51c2c6JvN37xJJkJ0=
|
||||
golang.org/x/text v0.24.0/go.mod h1:L8rBsPeo2pSS+xqN0d5u2ikmjtmoJbDBT1b7nHvFCdU=
|
||||
golang.org/x/text v0.26.0 h1:P42AVeLghgTYr4+xUnTRKDMqpar+PtX7KWuNQL21L8M=
|
||||
golang.org/x/text v0.26.0/go.mod h1:QK15LZJUUQVJxhz7wXgxSy/CJaTFjd0G+YLonydOVQA=
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue