Skip to main content

Selenium

A browser automation server for web testing and scraping.

Selenium is the standard framework for automating web browsers. The standalone Chrome deployment provides a remotely-accessible browser instance for running automated tests, web scraping, and browser-based automation tasks. Self-hosting avoids the cost of cloud browser services like BrowserStack or Sauce Labs.

Alternatives considered

Cloud Hosted

ToolOpen SourceFree TierMonthly Cost
BrowserStackNoNoFrom $29/mo
Sauce LabsNoNoFrom $39/mo

Self Hosted

ToolOpen SourceFull FeaturesNotes
PlaywrightYesYesLocal only; no remote grid

Installation

Architecture

  • Deployment: Single selenium deployment in the selenium namespace (standalone Chrome)
  • Image: selenium/standalone-chrome:133.0.6943.126-chromedriver-133.0.6943.126-20250222 (digest-pinned)
  • Storage: dshm emptyDir with medium: Memory for Chrome shared memory; no persistent storage
  • Networking: ClusterIP service with ports for WebDriver (hub) and noVNC viewer; HTTPRoute via public gateway

Security

No securityContext configured. Basic auth via SE_ROUTER_USERNAME/SE_ROUTER_PASSWORD from SOPS secret protects the WebDriver endpoint.

Updates

Managed by Renovate. Image is digest-pinned.

Data Management

No persistent storage. Stateless browser automation service.

User Management

Basic auth via SE_ROUTER_USERNAME/SE_ROUTER_PASSWORD from SOPS-encrypted secret. No OIDC.

Configuration Management

  • Router credentials and session limits from SOPS-encrypted secret
  • SE_VNC_NO_PASSWORD and other settings from env vars

Administration

Usage

Point Selenium WebDriver clients at the hub endpoint to run browser automation jobs. Use the noVNC interface to watch sessions visually for debugging. Connect from CI pipelines (e.g., Gitea Actions) for running browser-based integration tests against internal services.

Cluster-specific deviations from the above live in the per-cluster README — see k8s/apps/talos/selenium/README.md.

Cluster Deployment

Depends on

Selenium — Talos cluster

Cluster-specific notes only. General product info, "why we use it", and alternatives live in docusaurus/docs/apps/selenium.mdx.

Deviations from defaults

Defaults live in docusaurus/docs/apps/selenium.mdx — document anything this cluster does differently here, with a one-line reason.

Kubernetes Metadata
  • Image: selenium/standalone-chrome:133.0.6943.126-chromedriver-133.0.6943.126-20250222@sha256:c53f878fd122d65f8e6f07968362571981873b37e03aedf2fdc9a6dae2bec45c
Rendered manifests (kustomize build)
apiVersion: apps/v1
kind: Deployment
metadata:
annotations:
kustomize.toolkit.fluxcd.io/force: enabled
labels:
app: selenium
name: selenium
namespace: selenium
spec:
replicas: 1
selector:
matchLabels:
app: selenium
homepage: active
ingress: public
template:
metadata:
labels:
app: selenium
homepage: active
ingress: public
spec:
containers:
- env:
- name: SE_NODE_MAX_SESSIONS
value: '5'
- name: SE_NODE_OVERRIDE_MAX_SESSIONS
value: 'true'
- name: SE_ROUTER_USERNAME
valueFrom:
secretKeyRef:
key: username
name: selenium
- name: SE_ROUTER_PASSWORD
valueFrom:
secretKeyRef:
key: password
name: selenium
- name: SE_VNC_NO_PASSWORD
value: 'true'
image: >-
selenium/standalone-chrome:133.0.6943.126-chromedriver-133.0.6943.126-20250222@sha256:c53f878fd122d65f8e6f07968362571981873b37e03aedf2fdc9a6dae2bec45c
name: selenium
ports:
- containerPort: 4444
- containerPort: 7900
resources:
limits:
cpu: 1000m
memory: 2Gi
requests:
cpu: 500m
memory: 1Gi
volumeMounts:
- mountPath: /dev/shm
name: dshm
volumes:
- emptyDir:
medium: Memory
sizeLimit: 2Gi
name: dshm