Skip to content

Commit

Permalink
os: patch udev rules to keep the iso root partition first
Browse files Browse the repository at this point in the history
    - we need to mount correct root partition with type iso-9660
      when installation

Signed-off-by: Vicente Cheng <vicente.cheng@suse.com>
  • Loading branch information
Vicente-Cheng committed Dec 12, 2023
1 parent 022243e commit e619bd9
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,12 @@ RUN cat /tmp/os-release >> /usr/lib/os-release && rm -f /tmp/os-release
# Remove /etc/cos/config to use default values
RUN rm -f /etc/cos/config

# patch udev, we need to make sure the iso root first priority for installation
# related to
# - https://github.com/systemd/systemd/pull/28481
# - https://github.com/harvester/harvester/issues/4851
RUN sed -i 's/^\([^#]*iso9660.*\)/#\1/' /usr/lib/udev/rules.d/60-persistent-storage.rules

# Download rancherd
ARG RANCHERD_VERSION=v0.0.1-alpha14
RUN curl -o /usr/bin/rancherd -sfL "https://github.com/rancher/rancherd/releases/download/${RANCHERD_VERSION}/rancherd-amd64" && chmod 0755 /usr/bin/rancherd
Expand All @@ -45,4 +51,4 @@ RUN curl -o /usr/bin/rancherd -sfL "https://github.com/rancher/rancherd/releases
ARG NERDCTL_VERSION=1.2.1
RUN curl -o ./nerdctl-bin.tar.gz -sfL "https://github.com/containerd/nerdctl/releases/download/v${NERDCTL_VERSION}/nerdctl-${NERDCTL_VERSION}-linux-amd64.tar.gz"
RUN tar -zxvf nerdctl-bin.tar.gz && mv nerdctl /usr/bin/
RUN rm -f nerdctl-bin.tar.gz containerd-rootless-setuptool.sh containerd-rootless.sh
RUN rm -f nerdctl-bin.tar.gz containerd-rootless-setuptool.sh containerd-rootless.sh

0 comments on commit e619bd9

Please sign in to comment.