Skip to content
/ os Public
forked from openshift/os

Commit

Permalink
manifests: Add initial c10s based variant
Browse files Browse the repository at this point in the history
  • Loading branch information
travier committed May 23, 2024
1 parent aa735d7 commit 1104203
Show file tree
Hide file tree
Showing 8 changed files with 299 additions and 4 deletions.
63 changes: 63 additions & 0 deletions c10s.repo
Original file line number Diff line number Diff line change
@@ -0,0 +1,63 @@
[baseos10]
name=CentOS Stream 10 - BaseOS
baseurl=https://composes.stream.centos.org/stream-10/production/latest-CentOS-Stream/compose/BaseOS/$basearch/os
gpgcheck=1
repo_gpgcheck=0
enabled=1
gpgkey=file:///usr/share/distribution-gpg-keys/centos/RPM-GPG-KEY-CentOS-Official

[appstream10]
name=CentOS Stream 10 - AppStream
baseurl=https://composes.stream.centos.org/stream-10/production/latest-CentOS-Stream/compose/AppStream/$basearch/os
gpgcheck=1
repo_gpgcheck=0
enabled=1
gpgkey=file:///usr/share/distribution-gpg-keys/centos/RPM-GPG-KEY-CentOS-Official

# [extras-common]
# name=CentOS Stream 10 - Extras packages
# baseurl=https://mirror.stream.centos.org/SIGs/10-stream/extras/$basearch/extras-common
# gpgcheck=1
# repo_gpgcheck=0
# enabled=1
# gpgkey=file:///usr/share/distribution-gpg-keys/centos/RPM-GPG-KEY-CentOS-SIG-Extras-SHA512

[nfv10]
name=CentOS Stream 10 - NFV
baseurl=https://composes.stream.centos.org/stream-10/production/latest-CentOS-Stream/compose/NFV/$basearch/os
gpgcheck=1
repo_gpgcheck=0
enabled=1
gpgkey=file:///usr/share/distribution-gpg-keys/centos/RPM-GPG-KEY-CentOS-Official

[rt10]
name=CentOS Stream 10 - RT
baseurl=https://composes.stream.centos.org/stream-10/production/latest-CentOS-Stream/compose/RT/$basearch/os
gpgcheck=1
repo_gpgcheck=0
enabled=1
gpgkey=file:///usr/share/distribution-gpg-keys/centos/RPM-GPG-KEY-CentOS-Official

# [sig-nfv10]
# name=CentOS Stream 10 - SIG NFV
# baseurl=https://mirror.stream.centos.org/SIGs/10-stream/nfv/$basearch/openvswitch-2/
# gpgcheck=1
# repo_gpgcheck=0
# enabled=1
# gpgkey=file:///usr/share/distribution-gpg-keys/centos/RPM-GPG-KEY-CentOS-SIG-NFV

# [sig-virtualization]
# name=CentOS Stream 10 - SIG Virtualization
# baseurl=https://mirror.stream.centos.org/SIGs/10-stream/virt/$basearch/kata-containers/
# gpgcheck=1
# repo_gpgcheck=0
# enabled=1
# gpgkey=file:///usr/share/distribution-gpg-keys/centos/RPM-GPG-KEY-CentOS-SIG-Virtualization

# [sig-cloud-okd]
# name=CentOS Stream 10 - SIG Cloud OKD 4.15
# baseurl=https://mirror.stream.centos.org/SIGs/10-stream/cloud/$basearch/okd-4.15/
# gpgcheck=1
# repo_gpgcheck=0
# enabled=1
# gpgkey=file:///usr/share/distribution-gpg-keys/centos/RPM-GPG-KEY-CentOS-SIG-Cloud
6 changes: 6 additions & 0 deletions common-el9.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
# Packages only common to EL 9 (RHEL 9 & C9S)
packages:
- containernetworking-plugins
# Gluster - Used for Openshift e2e gluster testcases
# Reverts https://gitlab.cee.redhat.com/coreos/redhat-coreos/merge_requests/367 and add it for all arches
- glusterfs-fuse
4 changes: 0 additions & 4 deletions common.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -201,7 +201,6 @@ packages:
# Bootloader updater
- bootupd
# Containers
- containernetworking-plugins
- container-selinux
# Needed for newer rpm-ostree
- "'skopeo >= 2:1.7.0'"
Expand Down Expand Up @@ -232,9 +231,6 @@ packages:
- qemu-guest-agent
# passwd was obsoleted by shadow-utils in F40+, but still needed here
- passwd
# Gluster - Used for Openshift e2e gluster testcases
# Reverts https://gitlab.cee.redhat.com/coreos/redhat-coreos/merge_requests/367 and add it for all arches
- glusterfs-fuse
# Needed for kernel-devel extension: https://bugzilla.redhat.com/show_bug.cgi?id=1885408
# x86_64 and s390x have these packages installed as dependencies of other packages, ppc64le does not
# FIXME: once the below BZs have been resolved to remove perl dependencies, this can be done in the extensions script
Expand Down
85 changes: 85 additions & 0 deletions extensions-c10s.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,85 @@
# RPMs as operating system extensions, distinct from the base ostree commit/image
# https://github.com/openshift/enhancements/blob/master/enhancements/rhcos/extensions.md
# and https://github.com/coreos/fedora-coreos-tracker/issues/401

# repos:
# - sig-virtualization

extensions:
# https://issues.redhat.com/browse/RFE-4177
# wasm:
# architectures:
# - x86_64
# - aarch64
# repos:
# - appstream
# packages:
# - crun-wasm
# https://github.com/coreos/fedora-coreos-tracker/issues/1504
ipsec:
packages:
- libreswan
- NetworkManager-libreswan
# https://github.com/coreos/fedora-coreos-tracker/issues/326
usbguard:
packages:
- usbguard
kerberos:
packages:
- krb5-workstation
- libkadm5
# https://github.com/kmods-via-containers/kmods-via-containers/issues/3
# https://gitlab.cee.redhat.com/coreos/redhat-coreos/merge_requests/866
# These are currently overlaid onto the host so that they can be bind-mounted
# into build containers... in the future they should be a `development`
# extension: https://github.com/openshift/machine-config-operator/pull/2143.
kernel-devel:
packages:
- kernel-devel
- kernel-headers
match-base-evr: kernel
# These are already in the base, so they're not OS extensions, but they're
# useful to have in RPM form to install in kmod build containers.
kernel:
kind: development
packages:
- kernel
- kernel-core
- kernel-modules
- kernel-modules-extra
match-base-evr: kernel
# GRPA-2822
# https://github.com/openshift/machine-config-operator/pull/1330
# https://github.com/openshift/enhancements/blob/master/enhancements/support-for-realtime-kernel.md
kernel-rt:
architectures:
- x86_64
repos:
- nfv10
packages:
- kernel-rt-core
- kernel-rt-kvm
- kernel-rt-modules
- kernel-rt-modules-extra
- kernel-rt-devel
match-base-evr: kernel
# https://github.com/openshift/machine-config-operator/pull/2456
# https://github.com/openshift/enhancements/blob/master/enhancements/sandboxed-containers/sandboxed-containers-tech-preview.md
# GRPA-3123
# - kata-containers
# sandboxed-containers:
# architectures:
# - x86_64
# repos:
# - sig-virtualization10
# packages:
# - kata-containers
# https://issues.redhat.com/browse/COS-2402
kernel-64k:
architectures:
- aarch64
packages:
- kernel-64k-core
- kernel-64k-modules
- kernel-64k-modules-core
- kernel-64k-modules-extra
1 change: 1 addition & 0 deletions image-c10s.yaml
142 changes: 142 additions & 0 deletions manifest-c10s.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,142 @@
# Manifest for CentOS Stream CoreOS (SCOS)

rojig:
license: MIT
name: scos
summary: OKD 4

variables:
osversion: "c10s"

# Include manifests common to all RHEL and CentOS Stream versions and manifest
# common to RHEL 9 & C9S variants
include:
- common.yaml
- packages-openshift.yaml

# Starting from here, everything should be specific to SCOS

# CentOS Stream 9 repos + internal repos for now
repos:
- baseos10
- appstream10
# For containernetworking-plugins
- rhel-9.4-appstream
# CentOS Extras Common repo for SIG RPM GPG keys
# - extras-common10
# CentOS NFV SIG repo for openvswitch
# - sig-nfv10
# For openvswitch
- rhel-9.4-fast-datapath
# CentOS Cloud SIG repo for cri-o, cri-tools and conmon-rs
# - sig-cloud-okd
# Include RHCOS 9 repo for oc, hyperkube
- rhel-9.4-server-ose-4.16

# We include hours/minutes to avoid version number reuse
automatic-version-prefix: "416.10.<date:%Y%m%d%H%M>"
# This ensures we're semver-compatible which OpenShift wants
automatic-version-suffix: "-"
# Keep this is sync with the version in postprocess
mutate-os-release: "4.16"

postprocess:
- |
#!/usr/bin/env bash
set -xeo pipefail
# Tweak /usr/lib/os-release
grep -v "OSTREE_VERSION" /etc/os-release > /usr/lib/os-release.stream
OCP_RELEASE="4.16"
(
. /etc/os-release
cat > /usr/lib/os-release <<EOF
NAME="${NAME} CoreOS"
ID="scos"
ID_LIKE="rhel fedora"
VERSION="${OSTREE_VERSION}"
VERSION_ID="${OCP_RELEASE}"
VARIANT="CoreOS"
VARIANT_ID=coreos
PLATFORM_ID="${PLATFORM_ID}"
PRETTY_NAME="${NAME} CoreOS ${OSTREE_VERSION}"
ANSI_COLOR="${ANSI_COLOR}"
CPE_NAME="${CPE_NAME}::coreos"
HOME_URL="${HOME_URL}"
DOCUMENTATION_URL="https://docs.okd.io/latest/welcome/index.html"
BUG_REPORT_URL="https://access.redhat.com/labs/rhir/"
REDHAT_BUGZILLA_PRODUCT="OpenShift Container Platform"
REDHAT_BUGZILLA_PRODUCT_VERSION="${OCP_RELEASE}"
REDHAT_SUPPORT_PRODUCT="OpenShift Container Platform"
REDHAT_SUPPORT_PRODUCT_VERSION="${OCP_RELEASE}"
OPENSHIFT_VERSION="${OCP_RELEASE}"
OSTREE_VERSION="${OSTREE_VERSION}"
EOF
)
rm -f /etc/os-release
ln -s ../usr/lib/os-release /etc/os-release
# Tweak /etc/system-release, /etc/system-release-cpe & /etc/redhat-release
(
. /etc/os-release
cat > /usr/lib/system-release-cpe <<EOF
${CPE_NAME}
EOF
cat > /usr/lib/system-release <<EOF
${NAME} release ${VERSION_ID}
EOF
rm -f /etc/system-release-cpe /etc/system-release /etc/redhat-release
ln -s /usr/lib/system-release-cpe /etc/system-release-cpe
ln -s /usr/lib/system-release /etc/system-release
ln -s /usr/lib/system-release /etc/redhat-release
)
# Tweak /usr/lib/issue
cat > /usr/lib/issue <<EOF
\S \S{VERSION_ID}
EOF
rm -f /etc/issue /etc/issue.net
ln -s /usr/lib/issue /etc/issue
ln -s /usr/lib/issue /etc/issue.net
# Let's have a non-boring motd, just like CL (although theirs is more subdued
# nowadays compared to early versions with ASCII art). One thing we do here
# is add --- as a "separator"; the idea is that any "dynamic" information should
# be below that.
# See: https://projects.engineering.redhat.com/browse/COREOS-1029
. /etc/os-release
cat > /etc/motd <<EOF
CentOS Stream CoreOS $VERSION
Part of OKD ${OPENSHIFT_VERSION}, SCOS is a Kubernetes native operating system
managed by the Machine Config Operator (\`clusteroperator/machine-config\`).
WARNING: Direct SSH access to machines is not recommended; instead,
make configuration changes via \`machineconfig\` objects:
https://docs.openshift.com/container-platform/${OPENSHIFT_VERSION}/architecture/architecture-rhcos.html
---
EOF
# Packages that are only in SCOS and not in RHCOS or that have special
# constraints that do not apply to RHCOS
packages:
# We include the generic release package and tweak the os-release info in a
# post-proces script
- centos-stream-release
# RPM GPG keys for CentOS SIG repos
# - centos-release-cloud-common
# - centos-release-nfv-common
# - centos-release-virt-common

# Packages pinned to specific repos in SCOS 9
repo-packages:
# We always want the kernel from BaseOS
- repo: baseos10
packages:
- kernel
- repo: appstream10
packages:
# We want the one shipping in C9S, not the equivalently versioned one in RHAOS
- nss-altfiles
# Use the new containers/toolbox
- toolbox
1 change: 1 addition & 0 deletions manifest-c9s.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ variables:
# common to RHEL 9 & C9S variants
include:
- common.yaml
- common-el9.yaml
- packages-openshift.yaml

# Starting from here, everything should be specific to SCOS
Expand Down
1 change: 1 addition & 0 deletions manifest-rhel-9.4.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ variables:
# common to RHEL 9 & C9S variants
include:
- common.yaml
- common-el9.yaml
- packages-openshift.yaml

# Starting from here, everything should be specific to RHCOS based on RHEL 9.4 content
Expand Down

0 comments on commit 1104203

Please sign in to comment.