Sign inSign up

simstosh/improved-bun

By simstosh

•Updated 3 months ago

Bun+Python+FFmpeg+yt-dlp. Source github.com/SimStm/improved-bun

Image
0

2.5K

simstosh/improved-bun repository overview

⁠IMPROVED BUN

⁠It's basically oven/bun:latest, with a bunch of tools like yt-dlp, FFmpeg and audio, video and image processing tools :)

Docker Image GitHub Platforms Base

Source code: github.com/SimStm/improved-bun⁠
Language / Idioma: 🇺🇸 English⁠  ·  🇧🇷 Português⁠

⁠🇺🇸 English

Docker image based on oven/bun⁠ with Python, FFmpeg, yt-dlp, WebP tooling, and Microsoft Core Fonts pre-installed—so you don’t have to install them on every machine or CI run.

⁠What is it?

A Debian-based image (inherited from oven/bun:latest) extended with system packages and Python wheels commonly needed by Bun projects that touch media, downloads, or server-side rendering (Cairo/Pango).

⁠Image details
ItemValue
Source repositorySimStm/improved-bun on GitHub⁠
Base imageoven/bun:latest⁠ (tracks the official Bun release channel)
Default shell / CMD/bin/bash
Working directory/app
Runtime userapp (non-root), UID 1000, groups audio, video
TimezoneAmerica/Sao_Paulo
Architectureslinux/amd64, linux/arm64 (multi-arch manifest on Docker Hub)

The Dockerfile installs APT packages (curl, Python 3, FFmpeg, WebP, Cairo/Pango/Rsvg dev headers, fonts tooling, wget, cabextract, etc.), Microsoft Core Fonts via ttf-mscorefonts-installer, and yt-dlp via pip3 (--break-system-packages on the base Python).

⁠Versioning & tags
Tag patternMeaning
simstosh/improved-bun:latestAlways the most recent successful build pushed from main
simstosh/improved-bun:vYYYYMMDD.HHMMSSImmutable build identifier (UTC timestamp from CI), useful to pin deployments

Upstream tracking: The image is built FROM oven/bun:latest. When the official Bun image⁠ publishes a new digest for latest, a scheduled workflow can commit an update and trigger a rebuild so this stack stays aligned with the current Bun base.

Pinning for reproducibility:

  • Prefer a timestamp tag (v20260327.143022) instead of latest in production if you need a fixed combination of Bun base + this layer set.
  • You can also pin the base explicitly in your own Dockerfile (e.g. FROM oven/bun:1.3.9) and fork/adapt this Dockerfile if you need a specific Bun semver.
⁠Dependencies (why they’re here)
DependencyTypical use
Python 3 + pipScripts, tooling, yt-dlp
FFmpegAudio/video processing
yt-dlpMedia download (YouTube and others)
WebP (webpmux, cwebp, dwebp)WebP encode/decode/mux
Microsoft Core FontsArial, Times New Roman, Courier, etc.
Cairo, Pango, librsvg (+ dev headers)Raster/vector rendering, text layout
⁠Pre-installed (summary)
  • python3, python3-pip · ffmpeg · webp · build-essential and Cairo/Pango/JPEG/GIF/Rsvg dev packages · pkg-config · xfonts-utils · wget · cabextract · ca-certificates · gnupg · libmspack0
  • yt-dlp (pip)
  • Microsoft Core Fonts (Debian ttf-mscorefonts-installer package)
⁠How to use
docker pull simstosh/improved-bun:latest

docker run -it simstosh/improved-bun:latest

Dockerfile example

FROM simstosh/improved-bun:latest
WORKDIR /app
COPY . .
RUN bun install
USER app
CMD ["bun", "run", "start"]
⁠Local build & push
docker build -t simstosh/improved-bun:latest .

docker login
docker push simstosh/improved-bun:latest
⁠CI/CD (GitHub Actions)
TriggerBehavior
Push to mainMulti-arch build, push to Docker Hub, sync this README.md to the Hub Overview
pull_requestBuild only (no push)
workflow_dispatchManual run (push + README sync)
Schedule (every 6h)Separate workflow checks whether oven/bun:latest digest changed; if so, commits .github/bun-base-digest and pushes, which triggers the build workflow

The digest is read from registry-1.docker.io (Registry HTTP API v2, same as docker pull), via the Docker-Content-Digest header—not from the Docker Hub web API, which can return a digest that does not match the live manifest.

Secrets: DOCKERHUB_USERNAME, DOCKERHUB_TOKEN (PAT⁠ with Read, Write & Delete for push + README API).

Optional — PAT_REPO (GitHub PAT): Pushes made with the default GITHUB_TOKEN do not trigger other workflows (see GitHub docs⁠). The check workflow therefore either (a) checks out with PAT_REPO so the digest commit’s push triggers Docker Image CI, or (b) without PAT_REPO, runs gh workflow run after the push. If builds still don’t start after digest commits, add a classic PAT with repo scope or a fine-grained PAT with Contents: Read and write for this repository, as secret PAT_REPO.

Docker Hub README: After each successful push, dockerhub-description⁠ uploads this file (long text limit ~25 000 chars; short description ~100 chars).


⁠🇧🇷 Português

Imagem Docker baseada em oven/bun⁠ com Python, FFmpeg, yt-dlp, ferramentas WebP e fontes Microsoft Core pré-instaladas—para não precisar instalar tudo isso em cada máquina ou pipeline.

⁠O que é?

Imagem baseada em Debian (herdada de oven/bun:latest) estendida com pacotes de sistema e wheels Python usados com frequência em projetos Bun que lidam com mídia, downloads ou renderização no servidor (Cairo/Pango).

⁠Detalhes da imagem
ItemValor
Repositório fonteSimStm/improved-bun no GitHub⁠
Imagem baseoven/bun:latest⁠ (acompanha o canal oficial de releases do Bun)
Shell / CMD padrão/bin/bash
Diretório de trabalho/app
Usuário em runtimeapp (não root), UID 1000, grupos audio, video
Fuso horárioAmerica/Sao_Paulo
Arquiteturaslinux/amd64, linux/arm64 (manifest multi-arch no Docker Hub)

O Dockerfile instala pacotes APT (curl, Python 3, FFmpeg, WebP, headers dev Cairo/Pango/Rsvg, utilitários de fontes, wget, cabextract, etc.), fontes Microsoft Core via ttf-mscorefonts-installer e yt-dlp via pip3 (--break-system-packages no Python da base).

⁠Versionamento e tags
Padrão de tagSignificado
simstosh/improved-bun:latestSempre o build mais recente publicado a partir de main
simstosh/improved-bun:vYYYYMMDD.HHMMSSIdentificador imutável do build (timestamp UTC do CI), útil para fixar deploys

Rastreamento do upstream: a imagem usa FROM oven/bun:latest. Quando a imagem oficial do Bun⁠ publica um novo digest para latest, um workflow agendado pode atualizar o commit e disparar rebuild para manter a stack alinhada à base atual do Bun.

Reprodutibilidade:

  • Em produção, prefira uma tag com timestamp em vez de latest se precisar de uma combinação fixa de Bun + camadas desta imagem.
  • Você também pode fixar a base no seu próprio Dockerfile (ex.: FROM oven/bun:1.3.9) e adaptar este Dockerfile se precisar de um semver específico do Bun.
⁠Dependências (para que servem)
DependênciaUso típico
Python 3 + pipScripts, ferramentas, yt-dlp
FFmpegProcessamento de áudio/vídeo
yt-dlpDownload de mídia (YouTube e outros)
WebP (webpmux, cwebp, dwebp)Codificar/decodificar/mux WebP
Fontes Microsoft CoreArial, Times New Roman, Courier, etc.
Cairo, Pango, librsvg (+ headers dev)Renderização raster/vetorial, texto
⁠Conteúdo pré-instalado (resumo)
  • python3, python3-pip · ffmpeg · webp · build-essential e pacotes dev Cairo/Pango/JPEG/GIF/Rsvg · pkg-config · xfonts-utils · wget · cabextract · ca-certificates · gnupg · libmspack0
  • yt-dlp (pip)
  • Fontes Microsoft Core (pacote Debian ttf-mscorefonts-installer)
⁠Como usar
docker pull simstosh/improved-bun:latest

docker run -it simstosh/improved-bun:latest

Exemplo de Dockerfile

FROM simstosh/improved-bun:latest
WORKDIR /app
COPY . .
RUN bun install
USER app
CMD ["bun", "run", "start"]
⁠Build local e push
docker build -t simstosh/improved-bun:latest .

docker login
docker push simstosh/improved-bun:latest
⁠CI/CD (GitHub Actions)
GatilhoComportamento
Push em mainBuild multi-arch, push para Docker Hub, sincroniza este README.md na aba Overview
pull_requestApenas build (sem push)
workflow_dispatchExecução manual (push + sync do README)
Agendamento (a cada 6h)Outro workflow verifica se o digest de oven/bun:latest mudou; em caso positivo, faz commit em .github/bun-base-digest e push, disparando o workflow de build

O digest é obtido em registry-1.docker.io (API Registry v2, a mesma do docker pull), pelo header Docker-Content-Digest—não pela API REST do Docker Hub, que pode expor digest defasado em relação ao manifest real.

Secrets: DOCKERHUB_USERNAME, DOCKERHUB_TOKEN (PAT⁠ com Read, Write & Delete para push + API do README).

Opcional — PAT_REPO (PAT do GitHub): commits feitos só com GITHUB_TOKEN não disparam outros workflows (veja documentação do GitHub⁠). O workflow de check usa PAT_REPO no checkout para que o push do digest dispare o Docker Image CI, ou, sem PAT_REPO, roda gh workflow run depois do push. Se a imagem ainda não for gerada após commits de digest, crie um PAT clássico com escopo repo ou um fine-grained com Contents: Read and write neste repositório, como secret PAT_REPO.

README no Docker Hub: após cada push bem-sucedido, dockerhub-description⁠ envia este arquivo (texto longo ~25 000 caracteres; descrição curta ~100 caracteres).

Tag summary

Content type

Image

Digest

sha256:5c93fb560…

Size

507.3 MB

Last updated

3 months ago

docker pull simstosh/improved-bun