[GH-ISSUE #1003] Bug: CHROME_BINARY config ignored by Docker container #630

Closed
opened 2026-03-01 14:45:09 +03:00 by kerem · 2 comments
Owner

Originally created by @agnosticlines on GitHub (Jul 24, 2022).
Original GitHub issue: https://github.com/ArchiveBox/ArchiveBox/issues/1003

Describe the bug

If you set the chrome binary in the ArchiveBox.conf file, the changes are ignored when running with Docker

Steps to reproduce

  1. Add the following to ArchiveBox.conf:
[SERVER_CONFIG]
SECRET_KEY = SECRET_KEY_HERE

[DEPENDENCY_CONFIG]
CHROME_BINARY = chromium2
  1. Run ArchiveBox with docker-compose
  2. Add a new URL for archive using the SingleFIle module
  3. View the admin logs for that archive
  4. See the output
Run to see full output: cd /data/archive/1658662117.468753; /node/node_modules/single-file/cli/single-file --browser-executable-path=chromium

The code does take the config into account (from ArchiveBox/extractors/singlefile.py:47)

    # SingleFile CLI Docs: https://github.com/gildas-lormeau/SingleFile/tree/master/cli
    browser_args = '--browser-args={}'.format(json.dumps(browser_args[1:]))
    cmd = [
        DEPENDENCIES['SINGLEFILE_BINARY']['path'],
        '--browser-executable-path={}'.format(CHROME_BINARY),
        browser_args,
        link.url,
        output,
    ]

But I guess the Dockerfile overwrites that, so you have to set it in the dockerfile or docker compose environment variables, this isn't super clear and may confuse new users

Originally created by @agnosticlines on GitHub (Jul 24, 2022). Original GitHub issue: https://github.com/ArchiveBox/ArchiveBox/issues/1003 <!-- Please fill out the following information, feel free to delete sections if they're not applicable or if long issue templates annoy you. (the only required section is the version information) --> #### Describe the bug If you set the chrome binary in the `ArchiveBox.conf` file, the changes are ignored when running with Docker <!-- A description of what the bug is, what you expected to happen, and any relevant context about issue. --> #### Steps to reproduce <!-- For example: 1. Ran ArchiveBox with the following config '...' 2. Saw this output during archiving '....' 3. UI didn't show the thing I was expecting '....' --> 1. Add the following to `ArchiveBox.conf`: ``` [SERVER_CONFIG] SECRET_KEY = SECRET_KEY_HERE [DEPENDENCY_CONFIG] CHROME_BINARY = chromium2 ``` 2. Run ArchiveBox with docker-compose 3. Add a new URL for archive using the SingleFIle module 4. View the admin logs for that archive 5. See the output ``` Run to see full output: cd /data/archive/1658662117.468753; /node/node_modules/single-file/cli/single-file --browser-executable-path=chromium ``` The code does take the config into account (from ArchiveBox/extractors/singlefile.py:47) ```py # SingleFile CLI Docs: https://github.com/gildas-lormeau/SingleFile/tree/master/cli browser_args = '--browser-args={}'.format(json.dumps(browser_args[1:])) cmd = [ DEPENDENCIES['SINGLEFILE_BINARY']['path'], '--browser-executable-path={}'.format(CHROME_BINARY), browser_args, link.url, output, ] ``` But I guess the Dockerfile overwrites that, so you have to set it in the dockerfile or docker compose environment variables, this isn't super clear and may confuse new users
kerem closed this issue 2026-03-01 14:45:09 +03:00
Author
Owner

@pirate commented on GitHub (Jul 26, 2022):

How exactly are you running a non-standard chromium binary in the Docker image? Are you using a custom Dockerfile or loading a custom executable via a volume?

<!-- gh-comment-id:1195856970 --> @pirate commented on GitHub (Jul 26, 2022): How exactly are you running a non-standard chromium binary in the Docker image? Are you using a custom Dockerfile or loading a custom executable via a volume?
Author
Owner

@agnosticlines commented on GitHub (Jul 26, 2022):

I'm not, I was trying to find a workaround for the /usr/bin/chromium link that you added to the dockerfile, when I was doing it though I noticed this option wasn't respected, it may not be important and looking back on it this option probably only makes sense on a normal install not a dockerized one.
My bad!

<!-- gh-comment-id:1195865584 --> @agnosticlines commented on GitHub (Jul 26, 2022): I'm not, I was trying to find a workaround for the `/usr/bin/chromium` link that you added to the dockerfile, when I was doing it though I noticed this option wasn't respected, it may not be important and looking back on it this option probably only makes sense on a normal install not a dockerized one. My bad!
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/ArchiveBox#630
No description provided.