Skip to content

Commit 79f07a3

Browse files
CopilotZozman
andcommitted
Fix Chromium installation for multi-architecture support - replace snap dependencies with proper browser packages
Co-authored-by: Zozman <1192364+Zozman@users.noreply.github.com>
1 parent ef628ee commit 79f07a3

699 files changed

Lines changed: 394333 additions & 8 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

Dockerfile

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -3,20 +3,22 @@ FROM golang:1.24.5 AS base
33
WORKDIR /app
44
COPY ./go.mod ./
55
COPY ./go.sum ./
6-
# Use direct proxy to avoid TLS issues
7-
ENV GOPROXY=direct
8-
RUN go mod download
6+
COPY ./vendor ./vendor
7+
# Use vendor directory instead of downloading
8+
ENV GOPROXY=off
9+
ENV GOFLAGS=-mod=vendor
910
COPY ./main.go ./
1011

1112
# Setup builder
1213
FROM base AS builder
1314
RUN go build -o /stream ./main.go
1415

15-
# Run using FFmpeg image with Chromium support
16-
FROM linuxserver/ffmpeg:7.1.1 AS runner
16+
# Run using FFmpeg image with Chromium support (use Ubuntu 20.04 base)
17+
FROM ubuntu:20.04 AS runner
1718

18-
# Install runtime dependencies and Chromium
19-
RUN apt-get update && apt-get install -y \
19+
# Install runtime dependencies, FFmpeg, and Chromium from Ubuntu 20.04 repos
20+
RUN DEBIAN_FRONTEND=noninteractive apt-get update && apt-get install -y \
21+
ffmpeg \
2022
xvfb \
2123
x11-utils \
2224
pulseaudio \

main.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -98,7 +98,7 @@ func getEnvOrDefault(key, defaultValue string) string {
9898
func streamWebsite(ctx context.Context, config *Config) error {
9999
// Create Chrome context with options for screen capture
100100
opts := append(chromedp.DefaultExecAllocatorOptions[:],
101-
chromedp.ExecPath("chromium-browser"), // Use chromium-browser binary
101+
chromedp.ExecPath("chromium-browser"), // Use chromium-browser from Ubuntu 22.04
102102
chromedp.Flag("headless", false), // We need non-headless for video capture
103103
chromedp.Flag("disable-gpu", false),
104104
chromedp.Flag("no-sandbox", true),

vendor/github.com/chromedp/cdproto/.gitignore

Lines changed: 2 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

vendor/github.com/chromedp/cdproto/LICENSE

Lines changed: 21 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

vendor/github.com/chromedp/cdproto/README.md

Lines changed: 29 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)