-
Notifications
You must be signed in to change notification settings - Fork 2
/
olman-pyinstaller-amd64.yml
85 lines (83 loc) · 2.35 KB
/
olman-pyinstaller-amd64.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
resource_types:
- name: rclone
type: docker-image
source:
repository: sothr/concourse-rclone-resource
tag: latest
- name: irc-notification
type: docker-image
source:
repository: flavorjones/irc-notification-resource
resources:
- name: olman.git
type: git
icon: github
source:
uri: https://github.com/openscad/openscad-library-manager.git
- name: rclone
type: rclone
source:
config: |
[sftp]
type = sftp
host = ((rclone-host))
user = ((rclone-username))
pass = ((rclone-password))
shell_type = unix
- name: libera-openscad-ci
type: irc-notification
source:
server: irc.libera.chat
port: 6697
join: true
channel: ((openscad-ci-bot-channel))
user: ((openscad-ci-bot-username))
password: ((openscad-ci-bot-password))
jobs:
- name: build
public: true
plan:
- put: libera-openscad-ci
params:
message: >
Starting ${BUILD_TEAM_NAME}/${BUILD_PIPELINE_NAME}: build ${BUILD_ID} ${BUILD_URL}
- get: olman.git
- task: build-package
config:
platform: linux
image_resource:
type: registry-image
source:
repository: openscad/olman-base
inputs:
- name: olman.git
outputs:
- name: out
run:
path: /bin/bash
args:
- -exc
- |
set -euo pipefail
pushd olman.git
git log --oneline -n 8
N=$(git log -1 --date=format:"%FT%H%M" --pretty=format:olman_%cd.g%h)
popd
. /etc/os-release
. /olman/.venv/bin/activate
pyinstaller --onefile --name "${N}.${ID}-${VERSION_ID:-${VERSION_CODENAME}}" --distpath ./out olman.git/olman-cli/olman.py
- put: rclone
params:
source: out
destination:
- dir: "sftp:share/olman/"
on_success:
put: libera-openscad-ci
params:
message: >
Build successful ${BUILD_TEAM_NAME}/${BUILD_PIPELINE_NAME}: build ${BUILD_ID} ${BUILD_URL}
on_failure:
put: libera-openscad-ci
params:
message: >
Build failed ${BUILD_TEAM_NAME}/${BUILD_PIPELINE_NAME}: build ${BUILD_ID} ${BUILD_URL}