Skip to content

Commit 29e6e5e

Browse files
authored
Add nightly build of apt package (#50)
1 parent 48ee4d0 commit 29e6e5e

File tree

5 files changed

+53
-4
lines changed

5 files changed

+53
-4
lines changed

.github/workflows/nightly.yml

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
name: Publish-Nightly-Packages
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
8+
env:
9+
CARGO_TERM_COLOR: always
10+
11+
jobs:
12+
debian10:
13+
runs-on: debian10
14+
steps:
15+
- uses: actions/checkout@v2
16+
- name: Build
17+
run: ~/.cargo/bin/cargo +nightly build --verbose --release
18+
- name: Build apt package
19+
run: ~/.cargo/bin/cargo deb --manifest-path server/Cargo.toml --no-build
20+
- name: Publish apt package
21+
run: >-
22+
/usr/bin/curl
23+
-vvvv
24+
--fail
25+
-u 'github:${{ secrets.NEXUS_PASSWORD }}'
26+
-H "Content-Type: multipart/form-data"
27+
--data-binary "@./$(find target/debian/ -name *.deb)"
28+
"https://repo.stackable.tech/repository/deb-nightly/"

Cargo.lock

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

examples/simple-zookeepercluster.yaml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,5 +5,4 @@ metadata:
55
spec:
66
version: 3.4.14
77
servers:
8-
- node_name: soenke-laptop
9-
- node_name: lars-laptop
8+
- node_name: debian

server/Cargo.toml

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,21 @@
11
[package]
22
name = "stackable-zookeeper-operator-server"
3-
version = "0.1.0"
3+
description = "Stackable ZooKeeper Operator"
4+
version = "0.1.0-nightly"
45
authors = ["Lars Francke <lars.francke@stackable.de>"]
56
edition = "2018"
7+
license = "Apache-2.0"
68

79
[dependencies]
810
stackable-operator = { git = "https://github.com/stackabletech/operator-rs.git", branch = "main" }
911
stackable-zookeeper-crd = { path = "../crd" }
1012
stackable-zookeeper-operator = { path = "../operator" }
1113

1214
tokio = { version = "1.2", features = ["macros", "rt-multi-thread"] }
15+
16+
[package.metadata.deb]
17+
maintainer-scripts = "packaging/debian/"
18+
systemd-units = { enable = false }
19+
assets = [
20+
["../target/release/stackable-zookeeper-operator-server", "opt/stackable/zookeeper-operator/", "755"],
21+
]

server/packaging/debian/service

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
[Unit]
2+
Description=Stackable Zookeeper Operator
3+
Before=
4+
After=network.target
5+
[Service]
6+
User=root
7+
ExecStart=/opt/stackable/zookeeper-operator/stackable-zookeeper-operator-server
8+
Restart=on-abort
9+
StandardOutput=journal
10+
StandardError=journal
11+
Environment="ZOOKEEPER_OPERATOR_LOG=info"
12+
[Install]
13+
WantedBy=multi-user.target

0 commit comments

Comments
 (0)