2024-03-30 02:03:15 -04:00
|
|
|
steps:
|
|
|
|
- name: build-release
|
|
|
|
image: alpine
|
|
|
|
secrets: [GITEA_TOKEN]
|
|
|
|
when:
|
|
|
|
- event: push
|
|
|
|
- branch: main
|
|
|
|
commands:
|
|
|
|
- apk add openjdk21
|
|
|
|
- apk add wget
|
|
|
|
- apk add tar
|
|
|
|
- wget https://github.com/demonnic/muddler/releases/download/0.13/muddle-shadow-0.13.tar
|
|
|
|
- tar -xvf muddle-shadow-0.13.tar
|
|
|
|
- mv muddle-shadow-0.13/lib/muddle-0.13-all.jar muddle.jar
|
|
|
|
- java -jar muddle.jar
|
|
|
|
|
|
|
|
- name: deploy-build
|
2024-03-30 03:32:41 -04:00
|
|
|
image: alpine
|
2024-03-30 02:03:15 -04:00
|
|
|
when:
|
2024-03-30 03:47:12 -04:00
|
|
|
- event: [push, tag]
|
2024-03-30 03:32:41 -04:00
|
|
|
environment:
|
|
|
|
GITEATKN:
|
2024-03-30 02:03:15 -04:00
|
|
|
from_secret: GITEA_TOKEN
|
2024-03-30 04:02:03 -04:00
|
|
|
GOTOKEN:
|
|
|
|
from_secret: GOTIFY_TOKEN
|
2024-03-30 02:03:15 -04:00
|
|
|
depends_on: build-release
|
2024-03-30 03:32:41 -04:00
|
|
|
commands:
|
2024-03-30 03:54:39 -04:00
|
|
|
- apk add tea
|
2024-03-30 04:02:03 -04:00
|
|
|
- apk add wget
|
|
|
|
- tea login add --name=temp --url=https://git.vertinext.com/ --token=$GITEATKN
|
2024-03-30 04:08:25 -04:00
|
|
|
- tea releases create --asset "build/lotj-ui.mpackage" --asset "build/lotj-ui.xml" --tag latest --title "Latest Compiled Release"
|
2024-03-30 04:04:28 -04:00
|
|
|
- wget "https://gotify.vertinext.com/message?token=$GOTOKEN" --post-data "title=${CI} - ${CI_REPO_NAME}&message=New release ${CI_COMMIT_TAG} built and deployed.&priority=0" -O /dev/null
|
2024-03-30 02:03:15 -04:00
|
|
|
|
|
|
|
- name: notify-on-branch-push
|
|
|
|
image: alpine
|
|
|
|
when:
|
|
|
|
- event: push
|
|
|
|
- status: [success, failure]
|
|
|
|
environment:
|
|
|
|
GOTOKEN:
|
|
|
|
from_secret: GOTIFY_TOKEN
|
|
|
|
commands:
|
|
|
|
- apk add wget
|
|
|
|
- wget "https://gotify.vertinext.com/message?token=$GOTOKEN" --post-data "title=${CI} - ${CI_REPO_NAME}&message=New pipeline running.&priority=0" -O /dev/null
|