diff --git a/.gitignore b/.gitignore index e146bab..0f96d17 100644 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1,2 @@ +steamcmd-fedora-*.img* *.swp -*.img -*.img.xz diff --git a/Dockerfile b/Dockerfile index 99015d2..9c06293 100644 --- a/Dockerfile +++ b/Dockerfile @@ -19,9 +19,6 @@ RUN set -x ; \ dnf --setopt=logdir=/tmp/dnf-prep-logs --setopt=cachedir=/tmp/dnf-prep-cache -qy up ; \ dnf --setopt=logdir=/tmp/dnf-prep-logs --setopt=cachedir=/tmp/dnf-prep-cache -qy install \ util-linux \ - wget \ - less \ - findutils \ ca-certificates \ libgcc.{x86_64,i686} \ libstdc++.{x86_64,i686} \ diff --git a/README.md b/README.md index 4a177b1..8460978 100644 --- a/README.md +++ b/README.md @@ -9,12 +9,13 @@ use. Some utilities have been left in for convenience (*ie:* `wget`, `less`, `fi Size is *not* a priority for this image/project. Currency *(time, not money)* and convenience *are* the priorities. -## Tweaks +The `steamcmd` libraries are made available using `ld.so.conf.d`. +Most other images juggle symlinks instead. -The `steamcmd` libraries are made available using `ld.so.conf.d`. This *should* be -preferable to the usual solution: *juggling copies/symlinks*. +## Fedora tweaks -Below are the adjustments made to the package manager `dnf`. +These are all for the package manager, `dnf`. +The goal is to both reduce resource usage *and* improve performance: - `max_parallel_downloads`: Raised to the limit of 20. Leverages faster networks / more connections. diff --git a/build-image-files.sh b/build-image-files.sh index 8e7c16e..e2f10cc 100755 --- a/build-image-files.sh +++ b/build-image-files.sh @@ -1,14 +1,17 @@ #!/bin/bash # base vars -IMAGE_FILE="steamcmd-latest.img" +NOW=$(date +%s) # epoch timestamp, eg: 1622772927 +BASE_TAG=$(awk '$1 == "FROM" {print $2}' Dockerfile | cut -d\: -f2) # eg: 2.7.1 +BUILD_TAG="fedora-${BASE_TAG}-${NOW}" +IMAGE_FILE="steamcmd-${BUILD_TAG}.img" -echo "Building image steamcmd:latest" -podman build --no-cache --tag steamcmd:latest . -podman save localhost/steamcmd:latest > "${IMAGE_FILE}" +echo "Building image steamcmd:${BUILD_TAG}" +podman build --tag steamcmd:"${BUILD_TAG}" . +podman save localhost/steamcmd:"${BUILD_TAG}" > "${IMAGE_FILE}" echo "" echo "Wrote ${IMAGE_FILE}, cleaning up" -podman rmi steamcmd:latest +podman rmi steamcmd:"${BUILD_TAG}" echo "" echo "Attempting to compress the image (begin comforting music)" xz --keep --compress -9 --extreme --threads="$(nproc)" "${IMAGE_FILE}"