Skip to content

Commit 6729b2a

Browse files
authored
Merge pull request #57 from stackhpc/rl9_cloud_init_from_c9s
Add rocky-container-stackhpc element
2 parents c420f17 + 841947d commit 6729b2a

File tree

4 files changed

+28
-0
lines changed

4 files changed

+28
-0
lines changed

README.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,3 +30,4 @@ This repository provides the following DIB elements:
3030
* ``centos-linkup-extra``: Allows extra time for slow network links to come up.
3131
* ``centos7-vault``: Deploy older releases of CentOS 7
3232
* ``cloud-init-growpart-lvm``: Grows designated LVM partition.
33+
* ``rocky-container-stackhpc``: Custom containerfiles for usage with rocky-container element builds
Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
========================
2+
rocky-container-stackhpc
3+
========================
4+
Custom containerfiles for usage with ``rocky-container`` builds.
5+
Usage:
6+
Set ``DIB_CONTAINERFILE_DOCKERFILE`` environment variable to custom
7+
Containerfile path provided by this role, e.g.:
8+
DIB_CONTAINERFILE_DOCKERFILE: "/opt/kayobe/src/stackhpc-image-elements/elements/rocky-container-stackhpc/containerfiles/9-stackhpc"
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
# Based on https://github.com/openstack/diskimage-builder/blob/master/diskimage_builder/elements/rocky-container/containerfiles/9
2+
3+
FROM docker.io/rockylinux/rockylinux:9
4+
5+
RUN dnf group install -y 'Minimal Install' --allowerasing && \
6+
dnf install -y findutils util-linux \
7+
https://mirror.stream.centos.org/9-stream/AppStream/x86_64/os/Packages/cloud-init-23.1.1-12.el9.noarch.rpm
8+
9+
RUN sed -i "s/renderers:.*/renderers: ['network-manager']\n activators: ['network-manager']/" /etc/cloud/cloud.cfg
10+
11+
RUN systemctl unmask console-getty.service dev-hugepages.mount \
12+
getty.target sys-fs-fuse-connections.mount systemd-logind.service \
13+
systemd-remount-fs.service
14+
15+
# /etc/machine-id needs to be populated for /bin/kernel-install to
16+
# correctly copy kernels into /boot. We will clear this out in the
17+
# final image.
18+
RUN systemd-machine-id-setup
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
rocky-container

0 commit comments

Comments
 (0)