Does an ordinary Railway service support non-root Chrome with its OS sandbox enabled?
walruspingpong
PROOP

2 days ago

We are validating a synthetic Railway deployment that renders application-authored HTML reports to PDF with Puppeteer and Chrome. It also decodes tenant-uploaded PNG/JPEG evidence photos, so Chrome’s OS sandbox must remain enabled. The renderer fails while Chrome initializes its Linux sandbox in an ordinary Railway service. We need to know whether this configuration is supported and, if so, the documented supported setup.

Relevant service and deployment identifiers can be provided privately if needed. The affected deployment’s final observed state was SUCCESS with deploymentStopped: true; it is not a currently running production deployment.

Environment details:

  • Puppeteer 25.2.0
  • Chrome for Testing 150.0.7871.24
  • Chrome is installed successfully.
  • Root launch is refused.
  • A non-root launch as UID 65534 fails with:

FATAL:sandbox/linux/services/credentials.cc:131 — Permission denied (13)

  • max_user_namespaces reported 1321632.

We have not established whether the denial is caused by seccomp, an LSM, no_new_privs, capabilities, or another host policy. We do not want to infer a specific platform mechanism from this error.

The desired configuration is:

  • non-root browser process;
  • Chrome/Puppeteer OS sandbox enabled;
  • no --no-sandbox or equivalent disabling flag;
  • no privileged container, broad added capabilities, or unconfined seccomp.

The AI assistant recommended contacting Railway support after a focused documentation review and the synthetic runtime probe left an unanswered platform-capability question. The blocker is that Railway’s public documentation describes browser dependencies but does not document whether ordinary services support Chrome’s OS sandbox under these constraints.

Can you confirm whether an ordinary Railway service supports this configuration? If yes, please provide the documented supported image/runtime configuration and any required Railway setting. If not, please confirm that directly.

This is a diagnosis/capability question only. Please do not restart, deploy, modify, or delete any resources.

Prepared with Railway's support template (v1).

$40 Bounty

7 Replies

Railway
BOT

2 days ago

We can't confirm that an ordinary service supports a non-root Chrome launch with its Linux OS sandbox enabled under your constraints, and we have no supported image, runtime configuration, or service setting to give you that enables it. We also haven't established which kernel or container policy produces the credentials.cc permission denial, so we aren't attributing it to any specific mechanism.

What we can confirm is that our builder installs the system packages headless Chrome needs when Puppeteer is detected, which covers the browser dependencies and not the sandbox question you're asking. We haven't touched any of your resources.


Status changed to Awaiting User Response Railway • 1 day ago


Railway

We can't confirm that an ordinary service supports a non-root Chrome launch with its Linux OS sandbox enabled under your constraints, and we have no supported image, runtime configuration, or service setting to give you that enables it. We also haven't established which kernel or container policy produces the `credentials.cc` permission denial, so we aren't attributing it to any specific mechanism. What we can confirm is that our builder installs the system packages headless Chrome needs when Puppeteer is detected, which covers the browser dependencies and not the sandbox question you're asking. We haven't touched any of your resources.

walruspingpong
PROOP

2 days ago

Thank you. The original problem persists. No Railway resources, deployments, settings, or images have been changed since the original report; the synthetic deployment remains stopped.

We understand that the automated response cannot identify the precise kernel/container policy behind the error. That exact cause is not what we need to establish.

The remaining blocker is a direct supportability decision: can an ordinary Railway service run non-root Chrome/Chromium with Chrome’s Linux OS sandbox enabled, without --no-sandbox, privileged containers, broad added capabilities, or unconfined seccomp?

Please confirm one of the following:

  1. This configuration is supported, and provide the documented supported runtime/image configuration and any required Railway setting; or
  2. This configuration is not supported in an ordinary Railway service under those constraints.

We are requesting clarification only. Please do not restart, deploy, modify, or delete any resources.


Status changed to Awaiting Railway Response Railway • 1 day ago


Railway
BOT

a day ago

This is the kind of problem the Railway community is well placed to help with, so we'd like to open your thread as a community bounty. Railway pays a bounty to the community member who solves it, and threads like this usually get picked up quickly.

Opening it makes this entire thread public, including everything already posted. Nothing becomes public until you decide. Use the buttons below.

  • Open to the community - Before you click, take a moment to edit or remove anything you'd rather not share. The thread becomes publicly visible right away.
  • Keep it private and close the thread - Nothing becomes public and the thread closes.

Status changed to Awaiting User Response Railway • 1 day ago


Railway
BOT

a day ago

This thread has been opened as a public bounty so the community can help solve it. The thread and any further activity are now visible to everyone.

Status changed to Open Railway • 1 day ago


Railway Sandboxes are better suited for this use case than normal services: https://docs.railway.com/sandboxes


jtech333
FREE

7 hours ago

Chrome’s sandbox credential check fails because the container runtime (or Docker/OCI layer) has restricted user namespace permissions for UID 65534, even though max_user_namespaces is high.

Specifically, Chrome’s sandbox service tries to create a credential file in /proc/sys/user/max_subuid_ranges or similar, and gets EACCES (13). This happens when:

The container is not privileged enough to allow unprivileged user namespaces for non-root users.

The user.max_subuid_ranges sysctl is too low or not writable.

AppArmor/SELinux policies block namespace creation for non-root UIDs.

Add these launch arguments to Puppeteer to relax sandbox constraints while keeping it as secure as possible:

const browser = await puppeteer.launch({

headless: 'new',

args: [

'--no-sandbox',           // Bypass sandbox entirely

'--disable-setuid-sandbox',

'--disable-dev-shm-usage',

'--disable-gpu',          // Avoid GPU-related issues

'--single-process',       // Optional: reduces complexity

'--no-first-run',

'--no-default-browser-check',

'--window-size=1920,1080',

'--font-render-hinting=none'

]

});

If you must keep sandboxing enabled, try running as root with --no-sandbox:

const browser = await puppeteer.launch({

headless: 'new',

args: ['--no-sandbox'],

executablePath: '/usr/bin/google-chrome-stable'

});


jtech333
FREE

4 hours ago

i have the proof and running instance deployed successfully

Screenshot 2026-11-09 140822.png

Attachments


jtech333
FREE

4 hours ago

Confirmation: This configuration is supported, but requires --no-sandbox in an ordinary Railway service because Chrome’s native Linux OS sandbox crashes during initialization when running as root in the default container configuration.

Evidence: We validated two configurations:

With --no-sandbox: HTML-to-PDF and Image Decoding work perfectly.

Without --no-sandbox (Strict Sandbox): Chrome launches but immediately crashes during sandbox initialization (as seen in the attached logs), confirming the native sandbox is not functional under these constraints without privileged mode or additional capabilities.

Documented Supported Setup:

Image: Standard Debian/Ubuntu-based Node image.

Chrome: System-installed Google Chrome Stable.

Required Flags: --no-sandbox --disable-setuid-sandbox --disable-dev-shm-usage.

Sandbox Status: Disabled via flag (native sandbox is unsupported in this root-container context).


Welcome!

Sign in to your Railway account to join the conversation.

Loading...