forked from scylladb/cpp-rs-driver
-
Notifications
You must be signed in to change notification settings - Fork 0
141 lines (119 loc) · 4.04 KB
/
Copy pathbuild-cpack-packages.yml
File metadata and controls
141 lines (119 loc) · 4.04 KB
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
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
name: Build CPack Packages
on:
workflow_call:
inputs:
build-type:
description: CMake build type used for packaging
type: string
default: Release
extra-cmake-flags:
description: Additional flags passed to CMake configure step
type: string
default: ""
save-artifacts:
description: Save built packages as artifacts
type: boolean
default: false
secrets: {}
workflow_dispatch:
inputs:
build-type:
description: CMake build type used for packaging
type: string
default: Release
extra-cmake-flags:
description: Additional flags passed to CMake configure step
type: string
default: ""
save-artifacts:
description: Save built packages as artifacts
type: boolean
default: false
secrets: {}
env:
CARGO_TERM_COLOR: always
CMAKE_BUILD_TYPE: ${{ inputs.build-type }}
CMAKE_FLAGS: ${{ inputs.extra-cmake-flags }}
jobs:
linux-deb:
name: Linux DEB packages
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4
- name: Build and test DEB packages
run: make test-package-deb
- name: Collect artifacts
if: inputs.save-artifacts
run: make collect-package-artifacts
- uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4
if: inputs.save-artifacts
with:
name: linux-deb-packages
path: artifacts/linux
retention-days: 7
linux-rpm:
name: Linux RPM packages
runs-on: ubuntu-24.04
container:
image: fedora:latest
services:
scylla:
image: scylladb/scylla
ports:
- 9042:9042
options: >-
--health-cmd "cqlsh scylla -e \"select * from system.local WHERE key='local'\""
--health-interval 5s
--health-timeout 5s
--health-retries 60
steps:
- name: Install dependencies
run: dnf -y install git make cmake gcc-c++ findutils rpm-build ninja-build pkgconf-pkg-config openssl-devel clang
- uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4
- uses: actions-rust-lang/setup-rust-toolchain@46268bd060767258de96ed93c1251119784f2ab6 # v1
- name: Build and test RPM packages
run: make test-package-rpm-native SCYLLA_HOST=scylla SKIP_DOCKER_COMPOSE=1
- name: Collect artifacts
if: inputs.save-artifacts
run: make collect-package-artifacts
- uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4
if: inputs.save-artifacts
with:
name: linux-rpm-packages
path: artifacts/linux
retention-days: 7
macos:
name: macOS packages
runs-on: macos-15-intel
steps:
- uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4
- uses: actions-rust-lang/setup-rust-toolchain@46268bd060767258de96ed93c1251119784f2ab6 # v1
- name: Install GNU make
run: brew install make
- name: Build and test macOS packages (PKG + DMG)
run: gmake test-package-macos
- name: Collect artifacts
if: inputs.save-artifacts
run: gmake collect-package-artifacts
- uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4
if: inputs.save-artifacts
with:
name: macos-packages
path: artifacts/macos
retention-days: 7
windows:
name: Windows packages
runs-on: windows-2022
steps:
- uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4
- name: Build and test Windows packages (MSI)
run: make test-package-windows
- name: Collect artifacts
if: inputs.save-artifacts
run: make collect-package-artifacts
- uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4
if: inputs.save-artifacts
with:
name: windows-packages
path: artifacts/windows
retention-days: 7