Skip to content

Commit f6b83b8

Browse files
MONGOCRYPT-622 publish Debian 12 packages (#762)
* add debian12 config * set expansion for python3 * remove minor versions in Debian variant display names to match Evergreen distros --------- Co-authored-by: Roberto C. Sánchez <[email protected]>
1 parent cd15ef2 commit f6b83b8

File tree

5 files changed

+55
-4
lines changed

5 files changed

+55
-4
lines changed

.evergreen/config.yml

Lines changed: 34 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -664,6 +664,8 @@ tasks:
664664
name: build-and-test-and-upload
665665
- variant: amazon2023-arm64
666666
name: build-and-test-and-upload
667+
- variant: debian12
668+
name: build-and-test-and-upload
667669
- variant: debian11
668670
name: build-and-test-and-upload
669671
- variant: debian10
@@ -731,6 +733,8 @@ tasks:
731733
vars: { variant_name: "amazon2023" }
732734
- func: "download tarball"
733735
vars: { variant_name: "amazon2023-arm64" }
736+
- func: "download tarball"
737+
vars: { variant_name: "debian12" }
734738
- func: "download tarball"
735739
vars: { variant_name: "debian11" }
736740
- func: "download tarball"
@@ -1215,7 +1219,7 @@ buildvariants:
12151219
distros:
12161220
- rhel70-small
12171221
- name: debian11
1218-
display_name: "Debian 11.0"
1222+
display_name: "Debian 11"
12191223
run_on: debian11-large
12201224
expansions:
12211225
has_packages: true
@@ -1230,8 +1234,21 @@ buildvariants:
12301234
- name: publish-packages
12311235
distros:
12321236
- ubuntu2004-small
1237+
- name: debian12
1238+
display_name: "Debian 12"
1239+
run_on: debian12-large
1240+
expansions:
1241+
has_packages: true
1242+
packager_distro: debian12
1243+
packager_arch: x86_64
1244+
python: python3
1245+
tasks:
1246+
- build-and-test-and-upload
1247+
- name: publish-packages
1248+
distros:
1249+
- ubuntu2004-small
12331250
- name: debian10
1234-
display_name: "Debian 10.0"
1251+
display_name: "Debian 10"
12351252
run_on: debian10-test
12361253
expansions:
12371254
has_packages: true
@@ -1612,6 +1629,21 @@ buildvariants:
16121629
# Use a distro suitable for running curator to publish .deb packages.
16131630
run_on: ubuntu2004-small
16141631

1632+
- name: debian12-arm64-earthly
1633+
display_name: "Debian 12 arm64 (via Earthly)"
1634+
expansions:
1635+
has_packages: true
1636+
packager_distro: debian12
1637+
packager_arch: arm64
1638+
earthly_env: deb12
1639+
tasks:
1640+
- name: build-deb-packages-with-earthly
1641+
# Use an arm64 distro to match the intended target architecture of .deb packages.
1642+
run_on: ubuntu2204-arm64-small
1643+
- name: publish-deb-packages-with-earthly
1644+
# Use a distro suitable for running curator to publish .deb packages.
1645+
run_on: ubuntu2004-small
1646+
16151647
- name: debian10-arm64-earthly
16161648
display_name: "Debian 10 arm64 (via Earthly)"
16171649
expansions:

Earthfile

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -46,6 +46,7 @@
4646
# • deb9 - Debian 9.2
4747
# • deb10 - Debian 10.0
4848
# • deb11 - Debian 11.0
49+
# • deb12 - Debian 12.0
4950
# • sles15 - OpenSUSE Leap 15.0
5051
# • alpine - Alpine Linux 3.18
5152
#
@@ -201,6 +202,10 @@ env.deb11:
201202
# A Debian 11.0 environment
202203
DO +ENV_DEBIAN --version 11.0
203204

205+
env.deb12:
206+
# A Debian 12.0 environment
207+
DO +ENV_DEBIAN --version 12.0
208+
204209
env.sles15:
205210
# An OpenSUSE Leap 15.0 environment.
206211
FROM +init --base=docker.io/opensuse/leap:15.0

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -153,7 +153,7 @@ Second, create a list entry for the repository. For Ubuntu systems (be sure to
153153
echo "deb https://libmongocrypt.s3.amazonaws.com/apt/ubuntu <release>/libmongocrypt/1.9 universe" | sudo tee /etc/apt/sources.list.d/libmongocrypt.list
154154
```
155155

156-
For Debian systems (be sure to change `<release>` to `stretch`, `buster`, or `bullseye`, as appropriate to your system):
156+
For Debian systems (be sure to change `<release>` to `stretch`, `buster`, `bullseye`, or `bookworm` as appropriate to your system):
157157

158158
```
159159
echo "deb https://libmongocrypt.s3.amazonaws.com/apt/debian <release>/libmongocrypt/1.9 main" | sudo tee /etc/apt/sources.list.d/libmongocrypt.list

etc/packager.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -338,6 +338,8 @@ def repo_os_version(self, build_os):
338338
return 'buster'
339339
elif build_os == 'debian11':
340340
return 'bullseye'
341+
elif build_os == 'debian12':
342+
return 'bookworm'
341343
else:
342344
raise Exception("unsupported build_os: %s" % build_os)
343345
else:
@@ -390,7 +392,7 @@ def build_os(self, arch):
390392
"ubuntu2204",
391393
]
392394
elif self.dname == 'debian':
393-
return ["debian81", "debian92", "debian10", "debian11"]
395+
return ["debian81", "debian92", "debian10", "debian11", "debian12"]
394396
else:
395397
raise Exception("BUG: unsupported platform?")
396398

etc/repo_config.yaml

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -231,6 +231,18 @@ repos:
231231
repos:
232232
- apt/debian/dists/bullseye/libmongocrypt
233233

234+
- name: debian12
235+
type: deb
236+
code_name: "bookworm"
237+
bucket: libmongocrypt
238+
region: us-east-1
239+
edition: org
240+
component: main
241+
architectures:
242+
- amd64
243+
repos:
244+
- apt/debian/dists/bookworm/libmongocrypt
245+
234246
- name: ubuntu1404
235247
type: deb
236248
code_name: "trusty"

0 commit comments

Comments
 (0)