Skip to content

Commit

Permalink
Merge pull request GoogleCloudPlatform#3940 from zmeyers-ampere:fedor…
Browse files Browse the repository at this point in the history
…a-mixin

PiperOrigin-RevId: 531020388
  • Loading branch information
copybara-github committed May 10, 2023
2 parents cc442b5 + 57ed756 commit 159c837
Show file tree
Hide file tree
Showing 4 changed files with 35 additions and 0 deletions.
1 change: 1 addition & 0 deletions CHANGES.next.md
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,7 @@

### New features:

- Add support for systems running fedora36 and fedora37
- Add support for AlloyDB on GCP
- Add support for static systems running debian11
- Add ibmcloud as a new provider.
Expand Down
20 changes: 20 additions & 0 deletions perfkitbenchmarker/linux_virtual_machine.py
Original file line number Diff line number Diff line change
Expand Up @@ -2058,6 +2058,26 @@ def SetupPackageManager(self):
self.RemoteCommand(f'sudo dnf install -y {_EPEL_URL.format(9)}')


class Fedora36Mixin(BaseRhelMixin):
"""Class holding Fedora36 specific methods and attributes."""

OS_TYPE = os_types.FEDORA36
PYTHON_2_PACKAGE = None

def SetupPackageManager(self):
"""Fedora does not need epel."""


class Fedora37Mixin(BaseRhelMixin):
"""Class holding Fedora37 specific methods and attributes."""

OS_TYPE = os_types.FEDORA37
PYTHON_2_PACKAGE = None

def SetupPackageManager(self):
"""Fedora does not need epel."""


class CentOs7Mixin(BaseRhelMixin):
"""Class holding CentOS 7 specific VM methods and attributes."""
OS_TYPE = os_types.CENTOS7
Expand Down
4 changes: 4 additions & 0 deletions perfkitbenchmarker/os_types.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,8 @@
DEBIAN10_BACKPORTS = 'debian10_backports'
DEBIAN11 = 'debian11'
DEBIAN11_BACKPORTS = 'debian11_backports'
FEDORA36 = 'fedora36'
FEDORA37 = 'fedora37'
JUJU = 'juju'
RHEL7 = 'rhel7'
RHEL8 = 'rhel8'
Expand Down Expand Up @@ -99,6 +101,8 @@
DEBIAN10_BACKPORTS,
DEBIAN11,
DEBIAN11_BACKPORTS,
FEDORA36,
FEDORA37,
JUJU,
RHEL7,
RHEL8,
Expand Down
10 changes: 10 additions & 0 deletions perfkitbenchmarker/static_virtual_machine.py
Original file line number Diff line number Diff line change
Expand Up @@ -360,6 +360,16 @@ class Rhel9BasedStaticVirtualMachine(StaticVirtualMachine,
pass


class Fedora36BasedStaticVirtualMachine(StaticVirtualMachine,
linux_virtual_machine.Fedora36Mixin):
pass


class Fedora37BasedStaticVirtualMachine(StaticVirtualMachine,
linux_virtual_machine.Fedora37Mixin):
pass


class CentOs7BasedStaticVirtualMachine(StaticVirtualMachine,
linux_virtual_machine.CentOs7Mixin):
pass
Expand Down

0 comments on commit 159c837

Please sign in to comment.