Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(buildd): add support for ubuntu 24.04 #456

Merged
merged 4 commits into from
Jan 8, 2024
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions craft_providers/bases/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,7 @@ class BaseName(NamedTuple):
BaseName("ubuntu", "22.04"): ubuntu.BuilddBaseAlias.JAMMY,
BaseName("ubuntu", "23.04"): ubuntu.BuilddBaseAlias.LUNAR,
BaseName("ubuntu", "23.10"): ubuntu.BuilddBaseAlias.MANTIC,
BaseName("ubuntu", "24.04"): ubuntu.BuilddBaseAlias.NOBLE,
BaseName("ubuntu", "devel"): ubuntu.BuilddBaseAlias.DEVEL,
BaseName("centos", "7"): centos.CentOSBaseAlias.SEVEN,
BaseName("almalinux", "9"): almalinux.AlmaLinuxBaseAlias.NINE,
Expand Down
1 change: 1 addition & 0 deletions craft_providers/bases/ubuntu.py
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,7 @@ class BuilddBaseAlias(enum.Enum):
JAMMY = "22.04"
LUNAR = "23.04"
MANTIC = "23.10"
NOBLE = "24.04"
DEVEL = "devel"


Expand Down
6 changes: 6 additions & 0 deletions craft_providers/lxd/remotes.py
Original file line number Diff line number Diff line change
Expand Up @@ -144,6 +144,12 @@ def add_remote(self, lxc: LXC) -> None:
remote_address=BUILDD_RELEASES_REMOTE_ADDRESS,
remote_protocol=ProtocolType.SIMPLESTREAMS,
),
ubuntu.BuilddBaseAlias.NOBLE: RemoteImage(
image_name="core24",
mr-cal marked this conversation as resolved.
Show resolved Hide resolved
remote_name=DAILY_REMOTE_NAME,
mr-cal marked this conversation as resolved.
Show resolved Hide resolved
remote_address=DAILY_REMOTE_ADDRESS,
mr-cal marked this conversation as resolved.
Show resolved Hide resolved
remote_protocol=ProtocolType.SIMPLESTREAMS,
),
ubuntu.BuilddBaseAlias.LUNAR: RemoteImage(
image_name="lunar",
remote_name=DAILY_REMOTE_NAME,
Expand Down
3 changes: 3 additions & 0 deletions craft_providers/multipass/multipass_provider.py
Original file line number Diff line number Diff line change
Expand Up @@ -102,6 +102,9 @@ def name(self) -> str:
ubuntu.BuilddBaseAlias.MANTIC: RemoteImage(
remote=Remote.RELEASE, image_name="mantic"
),
ubuntu.BuilddBaseAlias.NOBLE: RemoteImage(
remote=Remote.RELEASE, image_name="noble"
),
# XXX: snapcraft:devel image is not working (LP #2007419)
# daily:devel image is not available on macos
ubuntu.BuilddBaseAlias.DEVEL: RemoteImage(remote=Remote.DAILY, image_name="devel"),
Expand Down
3 changes: 3 additions & 0 deletions tests/integration/multipass/test_multipass_provider.py
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,9 @@ def test_create_environment(installed_multipass, instance_name):
def test_launched_environment(alias, installed_multipass, instance_name, tmp_path):
"""Verify `launched_environment()` creates and starts an instance then stops
the instance when the method loses context."""
if sys.platform == "darwin" and alias == BuilddBaseAlias.NOBLE:
pytest.skip(reason="Noble on MacOS are not available")

if sys.platform == "darwin" and alias == BuilddBaseAlias.MANTIC:
pytest.skip(reason="Mantic on MacOS are not available")

Expand Down
Loading