summaryrefslogtreecommitdiff
path: root/base
diff options
context:
space:
mode:
Diffstat (limited to 'base')
-rw-r--r--base/Containerfile66
-rwxr-xr-xbase/initial_setup.sh25
-rw-r--r--base/packages.yaml14
3 files changed, 105 insertions, 0 deletions
diff --git a/base/Containerfile b/base/Containerfile
new file mode 100644
index 0000000..ae51051
--- /dev/null
+++ b/base/Containerfile
@@ -0,0 +1,66 @@
+ARG IMAGE_FLAVOR="${IMAGE_FLAVOR:-silverblue}"
+ARG BASE_IMAGE="quay.io/fedora-ostree-desktops/${IMAGE_FLAVOR}"
+ARG FEDORA_VERSION="${FEDORA_VERSION:-39}"
+
+FROM ${BASE_IMAGE}:${FEDORA_VERSION}
+ARG FEDORA_VERSION="${FEDORA_VERSION:-39}"
+
+
+COPY initial_setup.sh /usr/bin/
+COPY packages.yaml /tmp/
+COPY --from=docker.io/mikefarah/yq /usr/bin/yq /tmp/
+
+# remove non-flatpak firefox
+RUN rpm-ostree override remove firefox firefox-langpacks
+
+# setup third party repos
+RUN rpm-ostree install \
+ https://mirrors.rpmfusion.org/free/fedora/rpmfusion-free-release-${FEDORA_VERSION}.noarch.rpm \
+ https://mirrors.rpmfusion.org/nonfree/fedora/rpmfusion-nonfree-release-${FEDORA_VERSION}.noarch.rpm
+
+# install software/hardware codecs
+RUN rpm-ostree override remove \
+ mesa-va-drivers \
+ libavcodec-free \
+ libavfilter-free \
+ libavformat-free \
+ libavutil-free \
+ libpostproc-free \
+ libswresample-free \
+ libswscale-free && \
+ rpm-ostree install \
+ mesa-va-drivers-freeworld \
+ mesa-vdpau-drivers-freeworld \
+ gstreamer1-plugin-libav \
+ gstreamer1-plugins-bad-free-extras \
+ gstreamer1-plugins-bad-freeworld \
+ gstreamer1-plugins-ugly \
+ gstreamer1-vaapi \
+ ffmpeg
+
+
+# install third party packages & repos
+RUN cd /etc/yum.repos.d/ && \
+ curl -LO https://pkgs.tailscale.com/stable/fedora/tailscale.repo \
+ echo -e '\
+ [code]\n\
+ name=Visual Studio Code\n\
+ baseurl=https://packages.microsoft.com/yumrepos/vscode\n\
+ enabled=1\n\
+ gpgcheck=1\n\
+ gpgkey=https://packages.microsoft.com/keys/microsoft.asc\
+ ' > vscode.repo && \
+ rpm-ostree install code tailscale && \
+ systemctl enable tailscaled
+
+
+# install fedora rpms
+RUN readarray -td '' pkgs < <(/tmp/yq '.install[]' /tmp/packages.yaml) && \
+ rpm-ostree install "${pkgs[@]}"
+
+RUN sed -i 's/#AutomaticUpdatePolicy.*/AutomaticUpdatePolicy=stage/' /etc/rpm-ostreed.conf
+
+
+RUN rpm-ostree cleanup -m && \
+ rm -rf /tmp/* /var/* && \
+ ostree container commit
diff --git a/base/initial_setup.sh b/base/initial_setup.sh
new file mode 100755
index 0000000..0d60ddc
--- /dev/null
+++ b/base/initial_setup.sh
@@ -0,0 +1,25 @@
+#!/usr/bin/env bash
+set -euxo pipefail
+
+# make sure we're using the right flathub
+flatpak remote-delete flathub --force
+flatpak remote-add --system --if-not-exists flathub https://flathub.org/repo/flathub.flatpakrepo
+flatpak remote-add --user --if-not-exists flathub https://flathub.org/repo/flathub.flatpakrepo
+
+# add all of our stuff :)
+to_install=(
+ "com.raggesilver.BlackBox"
+ "io.github.celluloid_player.Celluloid"
+ "com.spotify.Client"
+ "com.discordapp.Discord"
+ "com.mattjakeman.ExtensionManager"
+ "org.mozilla.firefox"
+ "com.github.tchx84.Flatseal"
+ "org.freedesktop.Platform.VulkanLayer.MangoHud"
+ "org.prismlauncher.PrismLauncher"
+ "io.github.flattool.Warehouse"
+)
+
+for id in "${to_install[@]}"; do
+ flatpak install --user --noninteractive flathub "$id"
+done
diff --git a/base/packages.yaml b/base/packages.yaml
new file mode 100644
index 0000000..2d8b10e
--- /dev/null
+++ b/base/packages.yaml
@@ -0,0 +1,14 @@
+install:
+ - chromium
+ - fish # > bash
+ # gnome stuff
+ - adw-gtk3-theme
+ - gnome-tweaks
+ - gnome-shell-extension-caffeine
+ - qadwaitadecorations-qt5
+ - qadwaitadecorations-qt6
+ # maybe one day these will be good on flatpak :p
+ - lutris
+ - mangohud
+ - steam
+remove: []