Skip to content

Commit aba58ae

Browse files
committed
Add logically bound images for EDPM services
This change adds logically bound images for use with bootc. This is implementing based on: https://containers.github.io/bootc/logically-bound-images.html Signed-off-by: Brendan Shephard <[email protected]>
1 parent 1f6b557 commit aba58ae

File tree

16 files changed

+911
-28
lines changed

16 files changed

+911
-28
lines changed

bootc/Containerfile.centos9

Lines changed: 58 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -4,34 +4,64 @@ RUN rm -rf /etc/yum.repos.d/*.repo
44
COPY output/yum.repos.d /etc/yum.repos.d
55

66
ARG PACKAGES="\
7-
bind-utils \
8-
buildah \
9-
cephadm \
10-
chrony \
11-
cloud-init \
12-
crudini \
13-
crypto-policies-scripts \
14-
device-mapper-multipath \
15-
driverctl \
16-
grubby \
17-
iproute-tc \
18-
iptables-services \
19-
iscsi-initiator-utils \
20-
jq \
21-
lvm2 \
22-
nftables \
23-
numactl \
24-
openssh-server \
25-
openstack-selinux \
26-
openvswitch \
27-
os-net-config \
28-
podman \
29-
python3-libselinux \
30-
python3-pyyaml \
31-
rsync \
32-
tmpwatch \
33-
tuned-profiles-cpu-partitioning \
34-
sysstat"
7+
bind-utils \
8+
buildah \
9+
cephadm \
10+
chrony \
11+
cloud-init \
12+
crudini \
13+
crypto-policies-scripts \
14+
device-mapper-multipath \
15+
driverctl \
16+
grubby \
17+
iproute-tc \
18+
iptables-services \
19+
iscsi-initiator-utils \
20+
jq \
21+
lvm2 \
22+
NetworkManager-ovs \
23+
nftables \
24+
numactl \
25+
openssh-server \
26+
openstack-selinux \
27+
openvswitch \
28+
os-net-config \
29+
podman \
30+
python3-libselinux \
31+
python3-pyyaml \
32+
rsync \
33+
sysstat \
34+
tmpwatch \
35+
tuned-profiles-cpu-partitioning"
36+
3537
ARG ENABLE_UNITS="openvswitch"
3638

3739
RUN dnf -y update && dnf -y install $PACKAGES && dnf clean all && systemctl enable $ENABLE_UNITS
40+
41+
# Template systemd service for services
42+
COPY embedded-services/quadlets/systemd/service-template.kube /usr/share/containers/systemd/[email protected]
43+
44+
## Service specific quadlets
45+
COPY embedded-services/quadlets/ovn-controller/ovn_controller.yaml /usr/share/containers/systemd/ovn_controller.yaml
46+
COPY embedded-services/quadlets/ovn-controller/ovn_controller.image /usr/share/containers/systemd/ovn_controller.image
47+
COPY embedded-services/quadlets/iscsid/iscsid.yaml /usr/share/containers/systemd/iscsid.yaml
48+
COPY embedded-services/quadlets/iscsid/iscsid.image /usr/share/containers/systemd/iscsid.image
49+
COPY embedded-services/quadlets/nova_compute/nova_compute.yaml /usr/share/containers/systemd/nova_compute.yaml
50+
COPY embedded-services/quadlets/nova_compute/nova_compute.image /usr/share/containers/systemd/nova_compute.image
51+
COPY embedded-services/quadlets/ovn_metadata_agent/ovn_metadata_agent.yaml /usr/share/containers/systemd/ovn_metadata_agent.yaml
52+
COPY embedded-services/quadlets/ovn_metadata_agent/ovn_metadata_agent.image /usr/share/containers/systemd/ovn_metadata_agent.image
53+
COPY embedded-services/quadlets/logrotate_crond/logrotate_crond.yaml /usr/share/containers/systemd/logrotate_crond.yaml
54+
COPY embedded-services/quadlets/logrotate_crond/logrotate_crond.image /usr/share/containers/systemd/logrotate_crond.image
55+
COPY embedded-services/quadlets/multipathd/multipathd.yaml /usr/share/containers/systemd/multipathd.yaml
56+
COPY embedded-services/quadlets/multipathd/multipathd.image /usr/share/containers/systemd/multipathd.image
57+
COPY embedded-services/quadlets/ceilometer_agent_compute/ceilometer_agent_compute.yaml /usr/share/containers/systemd/ceilometer_agent_compute.yaml
58+
COPY embedded-services/quadlets/ceilometer_agent_compute/ceilometer_agent_compute.image /usr/share/containers/systemd/ceilometer_agent_compute.image
59+
60+
# Pre-cache containers for each service
61+
RUN podman pull quay.io/podified-antelope-centos9/openstack-ceilometer-compute:current-podified
62+
RUN podman pull quay.io/podified-antelope-centos9/openstack-iscsid:current-podified
63+
RUN podman pull quay.io/podified-antelope-centos9/openstack-cron:current-podified
64+
RUN podman pull quay.io/podified-antelope-centos9/openstack-multipathd:current-podified
65+
RUN podman pull quay.io/podified-antelope-centos9/openstack-nova-compute:current-podified
66+
RUN podman pull quay.io/podified-antelope-centos9/openstack-ovn-controller:current-podified
67+
RUN podman pull quay.io/podified-antelope-centos9/openstack-neutron-metadata-agent-ovn:current-podified
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
[install]
2+
WantedBy=edpm-compute@ceilometer_agent_compute.service
3+
4+
[Image]
5+
Image=quay.io/podified-antelope-centos9/openstack-ceilometer-compute:current-podified
Lines changed: 95 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,95 @@
1+
---
2+
apiVersion: v1
3+
kind: Pod
4+
metadata:
5+
annotations:
6+
bind-mount-options: /var/lib/openstack/cacerts/telemetry/tls-ca-bundle.pem:z
7+
labels:
8+
app: ceilometeragentcompute
9+
name: ceilometeragentcompute
10+
spec:
11+
containers:
12+
- args:
13+
- kolla_start
14+
env:
15+
- name: KOLLA_CONFIG_STRATEGY
16+
value: COPY_ALWAYS
17+
- name: OS_ENDPOINT_TYPE
18+
value: internal
19+
image: quay.io/podified-antelope-centos9/openstack-ceilometer-compute@sha256:f6bba9df7ce1d877daa7fe2cd36e5149b99ded1f3e9b88576944d83a4429f25b
20+
name: ceilometeragentcompute
21+
securityContext:
22+
runAsGroup: 42405
23+
runAsUser: 42405
24+
seLinuxOptions:
25+
type: ceilometer_polling_t
26+
volumeMounts:
27+
- mountPath: /openstack
28+
name: var-lib-openstack-healthchecks-ceilometer_agent_compute-host-0
29+
readOnly: true
30+
- mountPath: /etc/pki/tls/certs/ca-bundle.trust.crt
31+
name: etc-pki-tls-certs-ca-bundle.trust.crt-host-1
32+
readOnly: true
33+
- mountPath: /run/libvirt
34+
name: run-libvirt-host-2
35+
readOnly: true
36+
- mountPath: /dev/log
37+
name: dev-log-host-3
38+
- mountPath: /etc/pki/ca-trust/source/anchors
39+
name: etc-pki-ca-trust-source-anchors-host-4
40+
readOnly: true
41+
- mountPath: /etc/pki/ca-trust/extracted/pem/tls-ca-bundle.pem
42+
name: var-lib-openstack-cacerts-telemetry-tls-ca-bundle.pem-host-5
43+
readOnly: true
44+
- mountPath: /var/lib/kolla/config_files/config.json
45+
name: var-lib-openstack-config-telemetry-ceilometer-agent-compute.json-host-6
46+
- mountPath: /etc/hosts
47+
name: etc-hosts-host-7
48+
readOnly: true
49+
- mountPath: /var/lib/openstack/config/
50+
name: var-lib-openstack-config-telemetry-host-8
51+
- mountPath: /etc/localtime
52+
name: etc-localtime-host-9
53+
readOnly: true
54+
hostNetwork: true
55+
volumes:
56+
- hostPath:
57+
path: /var/lib/openstack/healthchecks/ceilometer_agent_compute
58+
type: Directory
59+
name: var-lib-openstack-healthchecks-ceilometer_agent_compute-host-0
60+
- hostPath:
61+
path: /etc/pki/tls/certs/ca-bundle.trust.crt
62+
type: File
63+
name: etc-pki-tls-certs-ca-bundle.trust.crt-host-1
64+
- hostPath:
65+
path: /run/libvirt
66+
type: Directory
67+
name: run-libvirt-host-2
68+
- hostPath:
69+
path: /dev/log
70+
type: File
71+
name: dev-log-host-3
72+
- hostPath:
73+
path: /etc/pki/ca-trust/source/anchors
74+
type: Directory
75+
name: etc-pki-ca-trust-source-anchors-host-4
76+
- hostPath:
77+
path: /var/lib/openstack/cacerts/telemetry/tls-ca-bundle.pem
78+
type: File
79+
name: var-lib-openstack-cacerts-telemetry-tls-ca-bundle.pem-host-5
80+
- hostPath:
81+
path: /var/lib/openstack/config/telemetry/ceilometer-agent-compute.json
82+
type: File
83+
name: var-lib-openstack-config-telemetry-ceilometer-agent-compute.json-host-6
84+
- hostPath:
85+
path: /etc/hosts
86+
type: File
87+
name: etc-hosts-host-7
88+
- hostPath:
89+
path: /var/lib/openstack/config/telemetry
90+
type: Directory
91+
name: var-lib-openstack-config-telemetry-host-8
92+
- hostPath:
93+
path: /etc/localtime
94+
type: File
95+
name: etc-localtime-host-9
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
[install]
2+
3+
4+
[Image]
5+
Image=quay.io/podified-antelope-centos9/openstack-iscsid:current-podified
Lines changed: 137 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,137 @@
1+
---
2+
apiVersion: v1
3+
kind: Pod
4+
metadata:
5+
annotations:
6+
bind-mount-options: /etc/iscsi:z
7+
creationTimestamp: "2024-12-09T02:00:14Z"
8+
labels:
9+
app: iscsid
10+
name: iscsid
11+
spec:
12+
containers:
13+
- args:
14+
- kolla_start
15+
env:
16+
- name: KOLLA_CONFIG_STRATEGY
17+
value: COPY_ALWAYS
18+
image: quay.io/podified-antelope-centos9/openstack-iscsid@sha256:4c9b5389a2564388e7a862d5756c37dc7d9739472b8d822dd6faae868a483a2d
19+
name: iscsid
20+
securityContext:
21+
privileged: true
22+
procMount: Unmasked
23+
volumeMounts:
24+
- mountPath: /etc/pki/ca-trust/source/anchors
25+
name: etc-pki-ca-trust-source-anchors-host-0
26+
readOnly: true
27+
- mountPath: /etc/target
28+
name: etc-target-host-1
29+
- mountPath: /etc/pki/tls/cert.pem
30+
name: etc-pki-tls-cert.pem-host-2
31+
readOnly: true
32+
- mountPath: /sys
33+
name: sys-host-3
34+
- mountPath: /dev/log
35+
name: dev-log-host-4
36+
- mountPath: /lib/modules
37+
name: lib-modules-host-5
38+
readOnly: true
39+
- mountPath: /var/lib/iscsi
40+
name: var-lib-iscsi-host-6
41+
- mountPath: /etc/hosts
42+
name: etc-hosts-host-7
43+
readOnly: true
44+
- mountPath: /etc/localtime
45+
name: etc-localtime-host-8
46+
readOnly: true
47+
- mountPath: /etc/pki/tls/certs/ca-bundle.crt
48+
name: etc-pki-tls-certs-ca-bundle.crt-host-9
49+
readOnly: true
50+
- mountPath: /etc/pki/tls/certs/ca-bundle.trust.crt
51+
name: etc-pki-tls-certs-ca-bundle.trust.crt-host-10
52+
readOnly: true
53+
- mountPath: /etc/pki/ca-trust/extracted
54+
name: etc-pki-ca-trust-extracted-host-11
55+
readOnly: true
56+
- mountPath: /var/lib/kolla/config_files/config.json
57+
name: var-lib-kolla-config_files-iscsid.json-host-12
58+
readOnly: true
59+
- mountPath: /etc/iscsi
60+
name: etc-iscsi-host-13
61+
- mountPath: /run
62+
name: run-host-14
63+
- mountPath: /dev
64+
name: dev-host-15
65+
- mountPath: /openstack
66+
name: var-lib-openstack-healthchecks-iscsid-host-16
67+
readOnly: true
68+
hostNetwork: true
69+
volumes:
70+
- hostPath:
71+
path: /etc/pki/ca-trust/source/anchors
72+
type: Directory
73+
name: etc-pki-ca-trust-source-anchors-host-0
74+
- hostPath:
75+
path: /etc/target
76+
type: Directory
77+
name: etc-target-host-1
78+
- hostPath:
79+
path: /etc/pki/tls/cert.pem
80+
type: File
81+
name: etc-pki-tls-cert.pem-host-2
82+
- hostPath:
83+
path: /sys
84+
type: Directory
85+
name: sys-host-3
86+
- hostPath:
87+
path: /dev/log
88+
type: File
89+
name: dev-log-host-4
90+
- hostPath:
91+
path: /lib/modules
92+
type: Directory
93+
name: lib-modules-host-5
94+
- hostPath:
95+
path: /var/lib/iscsi
96+
type: Directory
97+
name: var-lib-iscsi-host-6
98+
- hostPath:
99+
path: /etc/hosts
100+
type: File
101+
name: etc-hosts-host-7
102+
- hostPath:
103+
path: /etc/localtime
104+
type: File
105+
name: etc-localtime-host-8
106+
- hostPath:
107+
path: /etc/pki/tls/certs/ca-bundle.crt
108+
type: File
109+
name: etc-pki-tls-certs-ca-bundle.crt-host-9
110+
- hostPath:
111+
path: /etc/pki/tls/certs/ca-bundle.trust.crt
112+
type: File
113+
name: etc-pki-tls-certs-ca-bundle.trust.crt-host-10
114+
- hostPath:
115+
path: /etc/pki/ca-trust/extracted
116+
type: Directory
117+
name: etc-pki-ca-trust-extracted-host-11
118+
- hostPath:
119+
path: /var/lib/kolla/config_files/iscsid.json
120+
type: File
121+
name: var-lib-kolla-config_files-iscsid.json-host-12
122+
- hostPath:
123+
path: /etc/iscsi
124+
type: Directory
125+
name: etc-iscsi-host-13
126+
- hostPath:
127+
path: /run
128+
type: Directory
129+
name: run-host-14
130+
- hostPath:
131+
path: /dev
132+
type: Directory
133+
name: dev-host-15
134+
- hostPath:
135+
path: /var/lib/openstack/healthchecks/iscsid
136+
type: Directory
137+
name: var-lib-openstack-healthchecks-iscsid-host-16
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
[install]
2+
WantedBy=edpm-compute@logrotate_crond.service
3+
4+
[Image]
5+
Image=quay.io/podified-antelope-centos9/openstack-cron:current-podified

0 commit comments

Comments
 (0)