actions-test/.woodpecker.yml

72 lines
2 KiB
YAML
Raw Normal View History

2023-03-07 21:16:53 +01:00
# .woodpecker.yml
platform: linux/arm64
pipeline:
build:
image: node:18-alpine
commands:
2023-03-07 23:27:13 +01:00
- apk add git
2023-03-08 12:52:57 +01:00
- npm ci
2023-03-07 21:34:12 +01:00
- mkdir build
2023-03-07 21:16:53 +01:00
- npm run prepublish
2023-03-07 22:02:19 +01:00
- npm run bundleRelease
2023-03-10 12:44:23 +01:00
test:
image: node:18-alpine
commands:
- apk add openssl
- sh genSelfSignedCert.sh
2023-03-10 16:28:24 +01:00
- node tests/ws.js ci
- node tests/post.js ci
2023-03-08 12:52:57 +01:00
buildBin:
2023-03-08 13:29:50 +01:00
image: node:18
2023-03-07 21:16:53 +01:00
commands:
2023-03-26 11:43:43 +02:00
- apt install git zip tar
2023-03-26 11:32:41 +02:00
- npm run build-all
2023-03-07 21:16:53 +01:00
- mkdir outbag_server
- mkdir outbag_server/dist
- mkdir upload
2023-03-07 23:21:14 +01:00
- cp -r dist/* outbag_server/dist
2023-03-07 21:16:53 +01:00
- cp package.json outbag_server
- cp package-lock.json outbag_server
- cp readme.md outbag_server
- zip -r upload/OutbagServer.zip outbag_server/*
- tar -czvf upload/OutbagServer.tar.gz outbag_server/*
- cp build/bin/* upload
2023-03-26 11:32:41 +02:00
publish:
image: woodpeckerci/plugin-gitea-release
settings:
base_url: https://codeberg.org
files:
- "upload/*"
api_key:
from_secret: gitea_token
# publish:
# image: node:18-alpine
# commands:
# - apk add git zip tar
# - npm install git+https://jusax.de/git/jusax23/gitea-release.git
# - mkdir outbag_server
# - mkdir outbag_server/dist
# - mkdir upload
# - cp -r dist/* outbag_server/dist
# - cp package.json outbag_server
# - cp package-lock.json outbag_server
# - cp readme.md outbag_server
# - zip -r upload/OutbagServer.zip outbag_server/*
# - tar -czvf upload/OutbagServer.tar.gz outbag_server/*
# - cp build/bin/* upload
# - npx gitea-release "$${API_URL}" "$${GITEA_TOKEN}" "$${CI_REPO}" "$${CI_COMMIT_BRANCH}" "$${CI_COMMIT_TAG}" "upload" "$${CI_COMMIT_MESSAGE}"
# when:
# event: tag
# secrets: [ gitea_token, api_url ]
2023-03-10 12:44:23 +01:00
services:
database:
2023-03-10 13:09:21 +01:00
image: mariadb
2023-03-10 12:44:23 +01:00
environment:
- MYSQL_DATABASE=outbag
- MYSQL_USER=outbag
2023-03-10 12:46:42 +01:00
- MYSQL_PASSWORD=12345678
- MYSQL_ROOT_PASSWORD=12345678