Skip to content
This repository has been archived by the owner on Feb 19, 2024. It is now read-only.

Commit

Permalink
Merge branch 'bluefin-main' into merge-upstream
Browse files Browse the repository at this point in the history
  • Loading branch information
ohaukeboe committed Dec 20, 2023
2 parents 56c8883 + 4c490b7 commit 6c6dd8d
Show file tree
Hide file tree
Showing 23 changed files with 609 additions and 259 deletions.
36 changes: 36 additions & 0 deletions .github/ISSUE_TEMPLATE/bug-report.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
name: Bug Report
description: Report an issue about using Bluefin
body:
- type: markdown
attributes:
value: |
Thank you for taking the time to fill out this bug report! (She bites sometimes)
- type: textarea
id: describe-bug
attributes:
label: Describe the bug
description: A clear and concise description of what the bug is.
placeholder: Tell us what happened!
value: "When I entered 2 + 2, I got the answer 6."
validations:
required: true
- type: textarea
id: expected-bahavior
attributes:
label: What did you expect to happen?
description: A clear and concise description of what you expected to happen.
placeholder: What were you expecting to happen?
value: "I expected 2 + 2 to equal 4, but instead 2 + 2 equaled 6!"
validations:
required: true
- type: textarea
id: version
attributes:
label: Output of `rpm-ostree status`
description: Please run `rpm-ostree status` and paste the output here.
render: shell
- type: textarea
id: extra-context
attributes:
label: Extra information or context
description: Add any other context about the problem here.
104 changes: 104 additions & 0 deletions .github/workflows/build-bluefin-toolbox.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,104 @@
name: Build and Push Bluefin Toolbox Image
on:
schedule:
- cron: '20 22 * * *' # 10:20pm everyday
pull_request:
merge_group:
workflow_dispatch:
env:
IMAGE_NAME: bluefin-cli
IMAGE_TAGS: latest
IMAGE_REGISTRY: ghcr.io/${{ github.repository_owner }}

concurrency:
group: ${{ github.workflow }}-${{ github.ref || github.run_id }}
cancel-in-progress: true

jobs:
push-ghcr:
name: Build and push image
runs-on: ubuntu-22.04
permissions:
contents: read
packages: write
id-token: write
strategy:
fail-fast: false
steps:
# Checkout push-to-registry action GitHub repository
- name: Checkout Push to Registry action
uses: actions/checkout@v4

# Build metadata
- name: Image Metadata
uses: docker/metadata-action@v5
id: meta
with:
images: |
${{ env.IMAGE_NAME }}
labels: |
io.artifacthub.package.readme-url=https://raw.githubusercontent.com/ublue-os/boxkit/main/README.md
# Build image using Buildah action
- name: Build Image
id: build_image
uses: redhat-actions/buildah-build@v2
with:
containerfiles: |
./toolboxes/Containerfile.bluefin-cli
image: ${{ env.IMAGE_NAME }}
tags: ${{ env.IMAGE_TAGS }}
labels: ${{ steps.meta.outputs.labels }}
oci: false

# Workaround bug where capital letters in your GitHub username make it impossible to push to GHCR.
# https://github.com/macbre/push-to-ghcr/issues/12
- name: Lowercase Registry
id: registry_case
uses: ASzc/change-string-case-action@v6
with:
string: ${{ env.IMAGE_REGISTRY }}

# Push the image to GHCR (Image Registry)
- name: Push To GHCR
uses: redhat-actions/push-to-registry@v2
if: github.event_name != 'pull_request'
id: push
env:
REGISTRY_USER: ${{ github.actor }}
REGISTRY_PASSWORD: ${{ github.token }}
with:
image: ${{ steps.build_image.outputs.image }}
tags: ${{ steps.build_image.outputs.tags }}
registry: ${{ steps.registry_case.outputs.lowercase }}
username: ${{ env.REGISTRY_USER }}
password: ${{ env.REGISTRY_PASSWORD }}
extra-args: |
--disable-content-trust
- name: Login to GitHub Container Registry
uses: docker/login-action@v3
if: github.event_name != 'pull_request'
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}

# Sign container
- uses: sigstore/[email protected]
if: github.event_name != 'pull_request'

- name: Sign container image
if: github.event_name != 'pull_request'
run: |
echo "${{ env.COSIGN_PRIVATE_KEY }}" > cosign.key
wc -c cosign.key
cosign sign -y --key cosign.key ${{ steps.registry_case.outputs.lowercase }}/${{ env.IMAGE_NAME }}@${TAGS}
env:
TAGS: ${{ steps.push.outputs.digest }}
COSIGN_EXPERIMENTAL: false
COSIGN_PRIVATE_KEY: ${{ secrets.SIGNING_SECRET }}

- name: Echo outputs
run: |
echo "${{ toJSON(steps.push.outputs) }}"
8 changes: 8 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,9 @@ jobs:
- name: Checkout Push to Registry action
uses: actions/checkout@v4

- name: Check just syntax
uses: ublue-os/just-action@v1

- name: Matrix Variables
run: |
if [[ "${{ matrix.image_flavor }}" == "main" ]]; then
Expand Down Expand Up @@ -203,9 +206,14 @@ jobs:
check:
name: Check all builds successful
if: ${{ !cancelled() }}
runs-on: ubuntu-latest
needs: [push-ghcr]
steps:
- name: Exit on failure
if: ${{ needs.push-ghcr.result == 'failure' }}
shell: bash
run: exit 1
- name: Exit
shell: bash
run: exit 0
4 changes: 2 additions & 2 deletions .github/workflows/release-please.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,8 @@ jobs:
tag: ${{ steps.release-please.outputs.tag_name }}
upload_url: ${{ steps.release-please.outputs.upload_url }}
steps:
- uses: google-github-actions/release-please-action@v3
- uses: google-github-actions/release-please-action@v4
id: release-please
with:
release-type: node
release-type: simple
package-name: release-please-action
28 changes: 19 additions & 9 deletions Containerfile
Original file line number Diff line number Diff line change
Expand Up @@ -17,14 +17,21 @@ ARG BASE_IMAGE_NAME="${BASE_IMAGE_NAME}"
ARG FEDORA_MAJOR_VERSION="${FEDORA_MAJOR_VERSION}"
ARG PACKAGE_LIST="bluefin"

# GNOME VRR
RUN wget https://copr.fedorainfracloud.org/coprs/kylegospo/gnome-vrr/repo/fedora-"${FEDORA_MAJOR_VERSION}"/kylegospo-gnome-vrr-fedora-"${FEDORA_MAJOR_VERSION}".repo -O /etc/yum.repos.d/_copr_kylegospo-gnome-vrr.repo && \
if [ ${FEDORA_MAJOR_VERSION} -lt 39 ]; then \
rpm-ostree override replace --experimental --from repo=copr:copr.fedorainfracloud.org:kylegospo:gnome-vrr mutter mutter-common gnome-control-center gnome-control-center-filesystem xorg-x11-server-Xwayland \
; else \
rpm-ostree override replace --experimental --from repo=copr:copr.fedorainfracloud.org:kylegospo:gnome-vrr mutter mutter-common gnome-control-center gnome-control-center-filesystem \
; fi && \
rm -f /etc/yum.repos.d/_copr_kylegospo-gnome-vrr.repo
# GNOME VRR & Prompt
RUN if [ ${FEDORA_MAJOR_VERSION} -ge "39" ]; then \
wget https://copr.fedorainfracloud.org/coprs/kylegospo/gnome-vrr/repo/fedora-"${FEDORA_MAJOR_VERSION}"/kylegospo-gnome-vrr-fedora-"${FEDORA_MAJOR_VERSION}".repo -O /etc/yum.repos.d/_copr_kylegospo-gnome-vrr.repo && \
rpm-ostree override replace --experimental --from repo=copr:copr.fedorainfracloud.org:kylegospo:gnome-vrr mutter mutter-common gnome-control-center gnome-control-center-filesystem && \
rm -f /etc/yum.repos.d/_copr_kylegospo-gnome-vrr.repo && \
wget https://copr.fedorainfracloud.org/coprs/kylegospo/prompt/repo/fedora-$(rpm -E %fedora)/kylegospo-prompt-fedora-$(rpm -E %fedora).repo?arch=x86_64 -O /etc/yum.repos.d/_copr_kylegospo-prompt.repo && \
rpm-ostree override replace \
--experimental \
--from repo=copr:copr.fedorainfracloud.org:kylegospo:prompt \
vte291 \
vte-profile && \
rpm-ostree install \
prompt && \
rm -f /etc/yum.repos.d/_copr_kylegospo-prompt.repo \
; fi

COPY usr /usr
COPY just /tmp/just
Expand Down Expand Up @@ -86,6 +93,7 @@ RUN wget https://copr.fedorainfracloud.org/coprs/ublue-os/bling/repo/fedora-$(rp
rm -f /usr/share/applications/fish.desktop && \
rm -f /usr/share/applications/htop.desktop && \
rm -f /usr/share/applications/nvtop.desktop && \
rm -fr /usr/share/applications/gnome-system-monitor.desktop && \
sed -i 's/#DefaultTimeoutStopSec.*/DefaultTimeoutStopSec=15s/' /etc/systemd/user.conf && \
sed -i 's/#DefaultTimeoutStopSec.*/DefaultTimeoutStopSec=15s/' /etc/systemd/system.conf && \
sed -i '/^PRETTY_NAME/s/Kinoite/Kfin/' /usr/lib/os-release && \
Expand Down Expand Up @@ -117,7 +125,8 @@ COPY workarounds.sh \
RUN sysctl -p

RUN wget https://copr.fedorainfracloud.org/coprs/ganto/lxc4/repo/fedora-"${FEDORA_MAJOR_VERSION}"/ganto-lxc4-fedora-"${FEDORA_MAJOR_VERSION}".repo -O /etc/yum.repos.d/ganto-lxc4-fedora-"${FEDORA_MAJOR_VERSION}".repo && \
wget https://copr.fedorainfracloud.org/coprs/ublue-os/staging/repo/fedora-"${FEDORA_MAJOR_VERSION}"/ublue-os-staging-fedora-"${FEDORA_MAJOR_VERSION}".repo -O /etc/yum.repos.d/ublue-os-staging-fedora-"${FEDORA_MAJOR_VERSION}".repo
wget https://copr.fedorainfracloud.org/coprs/ublue-os/staging/repo/fedora-"${FEDORA_MAJOR_VERSION}"/ublue-os-staging-fedora-"${FEDORA_MAJOR_VERSION}".repo -O /etc/yum.repos.d/ublue-os-staging-fedora-"${FEDORA_MAJOR_VERSION}".repo && \
wget https://copr.fedorainfracloud.org/coprs/karmab/kcli/repo/fedora-"${FEDORA_MAJOR_VERSION}"/karmab-kcli-fedora-"${FEDORA_MAJOR_VERSION}".repo -O /etc/yum.repos.d/karmab-kcli-fedora-"${FEDORA_MAJOR_VERSION}".repo

# Handle packages via packages.json
RUN /tmp/build.sh && \
Expand Down Expand Up @@ -156,6 +165,7 @@ RUN /tmp/workarounds.sh
# Clean up repos, everything is on the image so we don't need them
RUN rm -f /etc/yum.repos.d/ublue-os-staging-fedora-"${FEDORA_MAJOR_VERSION}".repo && \
rm -f /etc/yum.repos.d/ganto-lxc4-fedora-"${FEDORA_MAJOR_VERSION}".repo && \
rm -f /etc/yum.repos.d/karmab-kcli-fedora-"${FEDORA_MAJOR_VERSION}".repo && \
rm -f /etc/yum.repos.d/vscode.repo && \
rm -f /etc/yum.repos.d/docker-ce.repo && \
rm -f /etc/yum.repos.d/_copr:copr.fedorainfracloud.org:phracek:PyCharm.repo && \
Expand Down
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,8 @@ A familiar(ish) Ubuntu desktop for Fedora Silverblue. It strives to cover these
# Documentation

1. [Bluefin](https://universal-blue.org/images/bluefin/)
1. [Bluefin](http://universal-blue.discourse.group/t/introduction-to-bluefin/41)
2. [Discussions and Announcements](https://universal-blue.discourse.group/c/bluefin/6) - strongly recommended!
3. [Developer Experience Edition](https://universal-blue.org/images/bluefin/developer-experience)
4. [Administrator's Guide](https://universal-blue.discourse.group/docs?topic=40)
3. [Developer Experience Edition](http://universal-blue.discourse.group/t/bluefin-dx-the-bluefin-developer-experience/39)
4. [Administrator's Guide](http://universal-blue.discourse.group/t/bluefin-administrators-guide/40)
5. [Framework Images](https://universal-blue.org/images/framework/)
7 changes: 2 additions & 5 deletions dx/usr/bin/bluefinbox-enter
Original file line number Diff line number Diff line change
Expand Up @@ -19,11 +19,8 @@ if [ "$container_exists" -eq 0 ]; then
# No need to assemble, enjoy your stay
exec distrobox enter "${container_name}"
else
# We don't have the container so we assemble it first. With distrobox version 1.5.0.2
# or below we need to assemble all the entries that occur in the `distrobox.ini` manifest.
# In future versions of distrobox we will be able to specify `--name $container_name` to
# only assemble the box we want to enter.
distrobox assemble create --replace --file /etc/distrobox/distrobox.ini
# We don't have the container so we assemble it first.
distrobox assemble create --name "${container_name}" --replace --file /etc/distrobox/distrobox.ini

# All done, good to go
exec distrobox enter "${container_name}"
Expand Down
11 changes: 11 additions & 0 deletions dx/usr/etc/dconf/db/local.d/01-ublue-dx
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
[org/gnome/shell]
favorite-apps = ['org.mozilla.firefox.desktop', 'org.mozilla.Thunderbird.desktop', 'org.gnome.Nautilus.desktop', 'org.gnome.Rhythmbox3.desktop', 'org.libreoffice.LibreOffice.writer.desktop', 'org.gnome.Software.desktop', 'code.desktop', 'org.gnome.Prompt.desktop', 'ubuntu.desktop', 'yelp.desktop']

[org/gnome/settings-daemon/plugins/media-keys/custom-keybindings/custom3]
binding='<Control><Alt>f'
command='xdg-terminal-exec -- bluefinbox-enter fedora'
name='Fedora Prompt'

[org/gnome/settings-daemon/plugins/media-keys]
custom-keybindings=['/org/gnome/settings-daemon/plugins/media-keys/custom-keybindings/custom0/', '/org/gnome/settings-daemon/plugins/media-keys/custom-keybindings/custom1/', '/org/gnome/settings-daemon/plugins/media-keys/custom-keybindings/custom2/', '/org/gnome/settings-daemon/plugins/media-keys/custom-keybindings/custom3/']
home=['<Super>e']
2 changes: 1 addition & 1 deletion dx/usr/share/ublue-os/distrobox/pytorch-nvidia.ini
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[mlbox]
image=nvcr.io/nvidia/pytorch:23.09-py3
image=nvcr.io/nvidia/pytorch:23.10-py3
additional_packages="nano git htop"
init_hooks="pip3 install huggingface_hub tokenizers transformers accelerate datasets wandb peft bitsandbytes fastcore fastprogress watermark torchmetrics deepspeed"
#pre-init-hooks="/init_script.sh"
Expand Down
Loading

0 comments on commit 6c6dd8d

Please sign in to comment.