mirror of
https://github.com/ublue-os/bazzite.git
synced 2025-04-17 20:43:04 +00:00
Initial commit of bazzite-desktop package
Add CODEOWNERS file
This commit is contained in:
parent
35d12d59ad
commit
868a019ca1
2
.github/CODEOWNERS
vendored
Normal file
2
.github/CODEOWNERS
vendored
Normal file
@ -0,0 +1,2 @@
|
||||
* @KyleGospo
|
||||
* @cyrv6737
|
11
.github/workflows/build.yml
vendored
11
.github/workflows/build.yml
vendored
@ -9,7 +9,6 @@ on:
|
||||
branches:
|
||||
- main
|
||||
env:
|
||||
IMAGE_NAME: bazzite
|
||||
IMAGE_REGISTRY: ghcr.io/${{ github.repository_owner }}
|
||||
|
||||
jobs:
|
||||
@ -23,6 +22,7 @@ jobs:
|
||||
strategy:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
image_name: ['', '-desktop']
|
||||
major_version: [37]
|
||||
include:
|
||||
- major_version: 37
|
||||
@ -61,13 +61,14 @@ jobs:
|
||||
uses: redhat-actions/buildah-build@v2
|
||||
with:
|
||||
containerfiles: |
|
||||
./Containerfile
|
||||
image: ${{ env.IMAGE_NAME }}
|
||||
${{ format('./Containerfile{0}', matrix.image_name) }}
|
||||
image: ${{ format('bazzite{0}', matrix.image_name) }}
|
||||
tags: |
|
||||
${{ steps.generate-tags.outputs.alias_tags }}
|
||||
${{ steps.generate-tags.outputs.date }}
|
||||
${{ steps.generate-tags.outputs.sha_short }}
|
||||
build-args: |
|
||||
IMAGE_NAME=${{ matrix.image_name }}
|
||||
FEDORA_MAJOR_VERSION=${{ matrix.major_version }}
|
||||
oci: true
|
||||
|
||||
@ -118,14 +119,14 @@ jobs:
|
||||
|
||||
- name: Sign container image
|
||||
run: |
|
||||
cosign sign --key cosign.key -a git_sha=${{ github.sha }} -a git_tag=${{ github.ref }} ${{ steps.registry_case.outputs.lowercase }}/${{ env.IMAGE_NAME }}@${TAGS}
|
||||
cosign sign --key cosign.key ${{ steps.registry_case.outputs.lowercase }}/${{ steps.build_image.outputs.image }}@${TAGS}
|
||||
env:
|
||||
TAGS: ${{ steps.push.outputs.digest }}
|
||||
COSIGN_EXPERIMENTAL: false
|
||||
|
||||
- name: Verify signed image
|
||||
run: |
|
||||
cosign verify --key cosign.pub ${{ steps.registry_case.outputs.lowercase }}/${{ env.IMAGE_NAME }}@${TAGS}
|
||||
cosign verify --key cosign.pub ${{ steps.registry_case.outputs.lowercase }}/${{ steps.build_image.outputs.image }}@${TAGS}
|
||||
env:
|
||||
TAGS: ${{ steps.push.outputs.digest }}
|
||||
COSIGN_EXPERIMENTAL: false
|
||||
|
@ -1,5 +1,3 @@
|
||||
ARG FEDORA_MAJOR_VERSION="${FEDORA_MAJOR_VERSION:-37}"
|
||||
|
||||
FROM ghcr.io/ublue-os/kinoite-nvidia:latest
|
||||
|
||||
COPY etc /etc
|
||||
@ -32,7 +30,10 @@ RUN rpm-ostree install \
|
||||
kdeconnectd \
|
||||
btop \
|
||||
fish \
|
||||
kate
|
||||
kate \
|
||||
openrgb-udev-rules \
|
||||
$(rpm -qa --qf "%{NAME} ")
|
||||
# The above prints every package installed, this acts similarly to rpm-ostree update when making an OCI image and resolves issues with installing Steam
|
||||
|
||||
# Install dock updater, this is done manually as it has proprietary parts and cannot be built in Copr.
|
||||
RUN git clone https://github.com/KyleGospo/jupiter-dock-updater-bin.git && \
|
||||
|
60
Containerfile-desktop
Normal file
60
Containerfile-desktop
Normal file
@ -0,0 +1,60 @@
|
||||
FROM ghcr.io/ublue-os/kinoite-nvidia:latest
|
||||
|
||||
COPY etc-desktop /etc
|
||||
|
||||
# Re-enable RPMFusion repos & add Copr repos
|
||||
RUN sed -i 's@enabled=0@enabled=1@g' /etc/yum.repos.d/rpmfusion-nonfree{,-updates}.repo && \
|
||||
sed -i 's@enabled=0@enabled=1@g' /etc/yum.repos.d/rpmfusion-free{,-updates}.repo && \
|
||||
wget https://copr.fedorainfracloud.org/coprs/kylegospo/bazzite/repo/fedora-$(rpm -E %fedora)/kylegospo-bazzite-fedora-$(rpm -E %fedora).repo -O /etc/yum.repos.d/_copr_kylegospo-bazzite.repo && \
|
||||
wget https://copr.fedorainfracloud.org/coprs/kylegospo/system76-scheduler/repo/fedora-$(rpm -E %fedora)/kylegospo-system76-scheduler-fedora-$(rpm -E %fedora).repo -O /etc/yum.repos.d/_copr_kylegospo-system76-scheduler.repo
|
||||
|
||||
# Install new packages
|
||||
RUN rpm-ostree install \
|
||||
distrobox \
|
||||
steam-devices \
|
||||
steamdeck-kde-themes \
|
||||
duperemove \
|
||||
kdeconnectd \
|
||||
system76-scheduler \
|
||||
btop \
|
||||
fish \
|
||||
kate \
|
||||
openrgb-udev-rules
|
||||
|
||||
# Remove unneeded packages
|
||||
RUN rpm-ostree override remove toolbox
|
||||
|
||||
# Install mesa freeworld components and ffmpeg for hardware accelerated video decode
|
||||
RUN rpm-ostree override remove \
|
||||
mesa-va-drivers \
|
||||
libavutil-free \
|
||||
libswscale-free \
|
||||
libswresample-free \
|
||||
libavformat-free \
|
||||
libavcodec-free \
|
||||
libavfilter-free \
|
||||
libpostproc-free \
|
||||
--install=mesa-va-drivers-freeworld.x86_64 \
|
||||
--install=mesa-va-drivers-freeworld.i686 \
|
||||
--install=mesa-vdpau-drivers-freeworld \
|
||||
--install=libva-intel-driver \
|
||||
--install=nvidia-vaapi-driver \
|
||||
--install=ffmpeg-libs \
|
||||
--install=ffmpeg \
|
||||
--install=libavcodec-freeworld
|
||||
|
||||
# Cleanup & Finalize
|
||||
RUN sed -i 's@enabled=1@enabled=0@g' /etc/yum.repos.d/rpmfusion-nonfree{,-updates}.repo && \
|
||||
sed -i 's@enabled=1@enabled=0@g' /etc/yum.repos.d/rpmfusion-free{,-updates}.repo && \
|
||||
sed -i 's@enabled=1@enabled=0@g' /etc/yum.repos.d/_copr_kylegospo-bazzite.repo && \
|
||||
sed -i 's@enabled=1@enabled=0@g' /etc/yum.repos.d/_copr_kylegospo-system76-scheduler.repo && \
|
||||
sed -i 's/#DefaultTimeoutStopSec.*/DefaultTimeoutStopSec=15s/' /etc/systemd/user.conf && \
|
||||
sed -i 's/#DefaultTimeoutStopSec.*/DefaultTimeoutStopSec=15s/' /etc/systemd/system.conf && \
|
||||
sed -i 's/#AutomaticUpdatePolicy.*/AutomaticUpdatePolicy=stage/' /etc/rpm-ostreed.conf && \
|
||||
systemctl enable rpm-ostreed-automatic.timer && \
|
||||
rpm-ostree cleanup -m && \
|
||||
rm -rf \
|
||||
/tmp/* \
|
||||
/var/* && \
|
||||
mkdir -p /var/lib/duperemove && \
|
||||
ostree container commit
|
5
etc-desktop/default/duperemove
Normal file
5
etc-desktop/default/duperemove
Normal file
@ -0,0 +1,5 @@
|
||||
# Dir to store hash files. Each instance has own, named by $(systemd-escape <instance>).hashfile
|
||||
HashDir=/var/lib/duperemove
|
||||
# Additional options for duperemove binary
|
||||
OPTIONS="--skip-zeroes --hash=xxhash"
|
||||
|
4
etc-desktop/sysctl.conf
Normal file
4
etc-desktop/sysctl.conf
Normal file
@ -0,0 +1,4 @@
|
||||
vm.swappiness=35
|
||||
vm.max_map_count=1048576
|
||||
net.core.default_qdisc=fq
|
||||
net.ipv4.tcp_congestion_control=bbr
|
18
etc-desktop/systemd/system/duperemove-weekly@.timer
Normal file
18
etc-desktop/systemd/system/duperemove-weekly@.timer
Normal file
@ -0,0 +1,18 @@
|
||||
[Unit]
|
||||
# Usage: systemctl enable --now duperemove-weekly@$(systemd-escape <path>).timer
|
||||
# Utilize %J specifier for duration set.
|
||||
# One can hardlink/copy with 'weekly' part changed
|
||||
# to set other duration.
|
||||
Description=Deduplicate %I at calendar event (%J)
|
||||
After=local-fs.target
|
||||
Requires=local-fs.target
|
||||
Conflicts=shutdown.target rescue.target rescue.service emergency.service
|
||||
|
||||
[Timer]
|
||||
Unit=duperemove@%i.service
|
||||
RandomizedDelaySec=30
|
||||
Persistent=true
|
||||
OnCalendar=%J
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
22
etc-desktop/systemd/system/duperemove@.service
Normal file
22
etc-desktop/systemd/system/duperemove@.service
Normal file
@ -0,0 +1,22 @@
|
||||
[Unit]
|
||||
Description=Recursive deduplication at %I
|
||||
Documentation=man:duperemove(8)
|
||||
Documentation=https://github.com/markfasheh/duperemove.git
|
||||
Conflicts=shutdown.target rescue.target rescue.service emergency.service
|
||||
After=local-fs.target
|
||||
Before=shutdown.target
|
||||
|
||||
[Service]
|
||||
Type=simple
|
||||
Environment="HashDir=/var/lib/%p"
|
||||
EnvironmentFile=-/etc/default/%p
|
||||
MemoryHigh=1G
|
||||
IOWeight=25
|
||||
CPUWeight=25
|
||||
Nice=18
|
||||
IOSchedulingClass=idle
|
||||
CPUSchedulingPolicy=idle
|
||||
ExecStartPre=/bin/mkdir -p ${HashDir}
|
||||
ExecStartPre=-/bin/df -h %I
|
||||
ExecStart=/usr/sbin/duperemove --hashfile=${HashDir}/%i.hashfile -r -d -h $OPTIONS %I
|
||||
ExecStopPost=-/bin/df -h %I
|
@ -0,0 +1,7 @@
|
||||
[Unit]
|
||||
Description=distrobox-upgrade Automatic Update
|
||||
|
||||
[Service]
|
||||
Type=simple
|
||||
ExecStart=/usr/bin/distrobox-upgrade --all
|
||||
StandardOutput=null
|
@ -0,0 +1,9 @@
|
||||
[Unit]
|
||||
Description=distrobox-upgrade Automatic Update Trigger
|
||||
|
||||
[Timer]
|
||||
OnBootSec=1h
|
||||
OnUnitInactiveSec=1d
|
||||
|
||||
[Install]
|
||||
WantedBy=timers.target
|
12
etc-desktop/systemd/user/flatpak-upgrade-automatic.service
Normal file
12
etc-desktop/systemd/user/flatpak-upgrade-automatic.service
Normal file
@ -0,0 +1,12 @@
|
||||
[Unit]
|
||||
Description=flatpak Automatic Update
|
||||
Documentation=man:flatpak(1)
|
||||
Wants=network-online.target
|
||||
After=network-online.target
|
||||
|
||||
[Service]
|
||||
Type=oneshot
|
||||
ExecStart=/usr/bin/flatpak update -y
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
10
etc-desktop/systemd/user/flatpak-upgrade-automatic.timer
Normal file
10
etc-desktop/systemd/user/flatpak-upgrade-automatic.timer
Normal file
@ -0,0 +1,10 @@
|
||||
[Unit]
|
||||
Description=flatpak Automatic Update Trigger
|
||||
Documentation=man:flatpak(1)
|
||||
|
||||
[Timer]
|
||||
OnBootSec=1h
|
||||
OnUnitInactiveSec=1d
|
||||
|
||||
[Install]
|
||||
WantedBy=timers.target
|
Loading…
x
Reference in New Issue
Block a user