Skip to content

Commit

Permalink
tree-wide: Minor whitespace fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
travier committed Jun 9, 2022
1 parent aaab0d2 commit 1d9152d
Show file tree
Hide file tree
Showing 9 changed files with 19 additions and 20 deletions.
10 changes: 5 additions & 5 deletions docs/rhcos-oci-braindump.md
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ mechanism. This allows one to inject an arbitrary path from a pre-built
container into the build context of another container.

In particular, OpenShift Image Builds does this by creating a temporary directory at `/tmp/build/inputs/<relative
path>` for each image input ([source](https://github.com/openshift/builder/blob/37525a77fa07e26c420962dee47193d672ef0b35/pkg/build/builder/common.go#L72)) and parsing the Dockerfile to replace any references to the relative path with the absolute path.
path>` for each image input ([source](https://github.com/openshift/builder/blob/37525a77fa07e26c420962dee47193d672ef0b35/pkg/build/builder/common.go#L72)) and parsing the Dockerfile to replace any references to the relative path with the absolute path.

### Buildah

Expand Down Expand Up @@ -142,12 +142,12 @@ images:
This works thusly:
1. Build the `build-test-qemu-img` from the `ci/Dockerfile` present in this
repository. This copies in all of the scripts and configs as well as builds the
OS layering test binary.
OS layering test binary.
1. We build the `cosa-build` container which
effectively takes the `build-test-qemu-img` and runs `cosa fetch && cosa build`
as part of a container image build. This produces the OCI archive within
`$COSA_DIR/builds/latest/x86_64/rhcos.ociarchive`.
1. We use this image as the input for the `machine-os-oci-content` image.
1. We use this image as the input for the `machine-os-oci-content` image.

A downside of this mechanism is that the resulting container size for
`cosa-build` is 20+ GB on-disk when the resulting on-disk size of the RHCOS OCI
Expand All @@ -169,7 +169,7 @@ images:
# We copy the built OCI archive into the mounted build context.
RUN --mount=type=bind,rw=true,src=.,dst=/buildcontext,bind-propagation=shared cp "${COSA_DIR}/builds/latest/x86_64/rhcos.x86_64.ociarchive" "/buildcontext/rhcos.x86_64.ociarchive"
# Since we can mutate the build context and we know where the OpenShift
# Image Builder injects it into the build pod, we can take advantage of the
# mutated build context thusly.
Expand All @@ -187,7 +187,7 @@ images:
to: machine-oci-os-content
```

What is nice about the future solution is that we can largely bypass having to pass around a 20+ GB image since the final image will be around 2.75 GB or so.
What is nice about the future solution is that we can largely bypass having to pass around a 20+ GB image since the final image will be around 2.75 GB or so.

### Far-Future Solution

Expand Down
4 changes: 2 additions & 2 deletions live/README-devel.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
These files will be copied to the target live ISO
via the CoreOS Assembler buildextend-live call. It
picks up all files in the coreos/fedora-coreos-config/live/
directory and copies them to the base of the ISO.
directory and copies them to the base of the ISO.

Files currently copied are:

Expand All @@ -10,4 +10,4 @@ Files currently copied are:

Files that get copied into efiboot.img in the ISO:

- EFI/grub.cfg
- EFI/grub.cfg
2 changes: 1 addition & 1 deletion live/isolinux/isolinux.cfg
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Note this file mostly matches the isolinux.cfg file from the Fedora
# Note this file mostly matches the isolinux.cfg file from the Fedora
# Server DVD iso. Diff this file with that file in the future to pick up
# changes.
serial 0
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Prefer keyfiles by listing the keyfile plugin first in the plugin list. This
# Prefer keyfiles by listing the keyfile plugin first in the plugin list. This
# overrides the default plugins and will cause any new networking configuration
# written by NetworkManager in RHCOS to be written out to keyfiles instead of
# ifcfg files. User's can still bring their own ifcfg files and they will still
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,6 @@ install_unit() {
install() {
inst_script "$moddir/rhcos-fail-boot-for-legacy-luks-config" \
"/usr/libexec/rhcos-fail-boot-for-legacy-luks-config"

install_unit rhcos-fail-boot-for-legacy-luks-config.service
}
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
#!/bin/bash
set -euo pipefail

# This script tries to look for a `files` entry with the `/etc/clevis.json`
# path (used to enable LUKS in RHCOS 4.6 or earlier versions) in an
# This script tries to look for a `files` entry with the `/etc/clevis.json`
# path (used to enable LUKS in RHCOS 4.6 or earlier versions) in an
# Ignition config. If it exists, then the script ends with exit 1.

ignition_cfg="/run/ignition.json"
Expand All @@ -11,8 +11,8 @@ wanted_path="/etc/clevis.json"
# select the `/etc/clevis.json` entry from a given Ignition config
if jq -e ".storage.files[]? | select(.path==\"${wanted_path}\")" "${ignition_cfg}" > /dev/null; then
echo "Your Ignition config specifies LUKS filesystem encryption using the obsolete
${wanted_path} config file, which is no longer supported. Refusing to boot.
Please refer to https://github.com/openshift/openshift-docs/pull/27661 for more
${wanted_path} config file, which is no longer supported. Refusing to boot.
Please refer to https://github.com/openshift/openshift-docs/pull/27661 for more
information."
exit 1
fi
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
# Fail the boot if the user tries to use the legacy
# LUKS configuration in an Ignition config to enable
# LUKS in RHCOS, so they don't accidentally end up
# Fail the boot if the user tries to use the legacy LUKS configuration in an
# Ignition config to enable LUKS in RHCOS, so they don't accidentally end up
# with an unencrypted system.
[Unit]
Description=RHCOS Check For Legacy LUKS Configuration
Expand Down
2 changes: 1 addition & 1 deletion overlay.d/06gcp-routes/usr/sbin/gcp-routes.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

# Update iptables rules based on google cloud load balancer VIPS
#
# This is needed because the GCP L3 load balancer doesn't actually do DNAT;
# This is needed because the GCP L3 load balancer doesn't actually do DNAT;
# the destination IP address is still the VIP. Normally, there is an agent that
# adds the vip to the local routing table, tricking the kernel in to thinking
# it's a local IP and allowing processes doing an accept(0.0.0.0) to receive
Expand Down
4 changes: 2 additions & 2 deletions tests/kola/version/rhel-major-version
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,10 @@ fatal() {

# checks to ensure that the only packages from the RHEL major version are included

source /etc/os-release
source /etc/os-release
var=$(echo "${RHEL_VERSION}" | cut -d. -f1)
for x in $(rpm -qa --queryformat='%{RELEASE}\n' | grep -oP 'el\s*\K\d+'); do
if [[ "$var" -ne $((x)) ]]; then
if [[ "$var" -ne $((x)) ]]; then
fatal "Error RHEL packages do not match current version"
fi
done

0 comments on commit 1d9152d

Please sign in to comment.