final version of how packages will be installed on different OS versions

This commit is contained in:
2022-06-22 09:44:21 +02:00
parent b40905670a
commit a654b8c6f4
+13 -23
View File
@@ -30,7 +30,7 @@ base::pkg_group::java:
- 'java-17-openjdk'
base::package_groups:
- 'java'
- 'java'
```
### Install a Group of Packages
@@ -56,16 +56,6 @@ base::pkg_group::java:
### Install Packages only on Given OS Version
**to be implemented**
Certain packages are only used on a given OS Version, so a `=` with the OS name and the major version selects a package only for given OS, where as a `-` will filter away given package on hosts with given OS, so they are not installed there.
```
base::pkg_group::java:
- 'java-1.8.0-openjdk:=redhat7'
- 'java-11-openjdk'
- 'java-17-openjdk:-redhat7'
```
**possible alternative**
Certain packages are only used on a given OS Version, so a `os=` with the OS name and the major version selects a package only for given OS, where as a `os!` will filter away given package on hosts with given OS, so they are not installed there.
@@ -114,7 +104,7 @@ The default list (except for nodes with the `bootpc` and `appliances::lenovo::*`
If repositories are managed in Hiera, feel free to add them to `rpm_repos::default` like
```
rpm_repos::default:
- 'gfa'
- 'gfa'
```
Note that repositories for different versions of RHEL can be added and only the fitting ones will be configured on the node.
@@ -127,15 +117,15 @@ An individual package repository is configured in Hiera within the namespace `rp
```
rpm_repos::repo::epel_rhel8:
name: 'epel'
descr: "Extra Packages for Enterprise Linux 8"
baseurl: 'https://repo01.psi.ch/el8/tags/$pli_repo_tag/epel/'
gpgkey: 'https://repo01.psi.ch/el8/keys/RPM-GPG-KEY-EPEL-8'
disable: false
gpgcheck: true
osversion: 8
exclude:
- "slurm*"
name: 'epel'
descr: "Extra Packages for Enterprise Linux 8"
baseurl: 'https://repo01.psi.ch/el8/tags/$pli_repo_tag/epel/'
gpgkey: 'https://repo01.psi.ch/el8/keys/RPM-GPG-KEY-EPEL-8'
disable: false
gpgcheck: true
osversion: 8
exclude:
- "slurm*"
```
The legacy namespace `yum_client::repo::*` is currently used for RHEL7 repositories to be backward compatible as some Hiera configuration with higher precedence overwrites certain stuff.
@@ -177,8 +167,8 @@ The tags are different per major OS version and are definied in the Hiera hash `
yum_client::repo_tag: 'prod'
rpm_repos::tag:
redhat7: "%{lookup('yum_client::repo_tag')}"
redhat8: 'rhel-8'
redhat7: "%{lookup('yum_client::repo_tag')}"
redhat8: 'rhel-8'
```
So for RHEL 7 the default is `prod` and can be overriden on `yum_client::repo_tag` (backwards compatibility) or on the `redhat7` attribute of `rpm_repos::tag`.