mirror of
https://github.com/hrfee/jfa-go.git
synced 2024-06-18 07:27:49 +02:00
Harvey Tindall
92332206f0
If enabled, jfa-go pings buildrone (hosted at builds.hrfee.pw) every 30 min for new updates. If there is one, it gets information (and if applicable, a binary) from the appropriate source (buildrone, github, or dockerhub) and displays it on the admin page. You can switch update channels between stable and unstable. For binary releases, updates are downloaded automatically and installed when the user presses update. Since this obviously introduces some "phone-home" functionality into jfa-go, I just want to say IPs are not and will not be logged by buildrone, although I may later introduce functionality to give a rough idea of the number of users (again, no IPs stored). The whole thing can also be turned off in settings.
59 lines
1.7 KiB
YAML
59 lines
1.7 KiB
YAML
project_name: jfa-go
|
|
release:
|
|
github:
|
|
owner: hrfee
|
|
name: jfa-go
|
|
name_template: "v{{.Version}}"
|
|
before:
|
|
hooks:
|
|
- go mod download
|
|
- rm -rf data/web
|
|
- mkdir -p data
|
|
- cp -r static data/web
|
|
- npm install
|
|
- npm install esbuild
|
|
- mkdir -p data/web/css
|
|
- npx esbuild --bundle css/base.css --outfile=./data/web/css/bundle.css --external:remixicon.css --minify
|
|
- cp node_modules/remixicon/fonts/remixicon.css node_modules/remixicon/fonts/remixicon.woff2 data/web/css/
|
|
- cp -r html data/
|
|
- cp -r lang data/
|
|
- python3 scripts/enumerate_config.py -i config/config-base.json -o data/config-base.json
|
|
- python3 scripts/generate_ini.py -i config/config-base.json -o data/config-default.ini
|
|
- python3 scripts/compile_mjml.py -o data/
|
|
- npx esbuild --bundle ts/admin.ts --outfile=./data/web/js/admin.js --minify
|
|
- npx esbuild --bundle ts/form.ts --outfile=./data/web/js/form.js --minify
|
|
- npx esbuild --bundle ts/setup.ts --outfile=./data/web/js/setup.js --minify
|
|
- go get -u github.com/swaggo/swag/cmd/swag
|
|
- swag init -g main.go
|
|
- python3 scripts/embed.py internal
|
|
builds:
|
|
- dir: ./
|
|
env:
|
|
- CGO_ENABLED=0
|
|
ldflags:
|
|
- -s -w -X main.version={{.Env.VERSION}} -X main.commit={{.ShortCommit}} -X main.updater=binary
|
|
goos:
|
|
- linux
|
|
- windows
|
|
- darwin
|
|
goarch:
|
|
- amd64
|
|
- arm
|
|
- arm64
|
|
archives:
|
|
- replacements:
|
|
darwin: macOS
|
|
linux: Linux
|
|
windows: Windows
|
|
amd64: x86_64
|
|
checksum:
|
|
name_template: 'checksums.txt'
|
|
snapshot:
|
|
name_template: "git-{{.ShortCommit}}"
|
|
changelog:
|
|
sort: asc
|
|
filters:
|
|
exclude:
|
|
- '^docs:'
|
|
- '^test:'
|