Skip to content

External Assets (images, svg files etc) do not load correctly when running the website in a docker container #3947

@LuminousHustler

Description

@LuminousHustler

What Happened?

When running the website in a docker container, external images and other assets fail to load. This makes it somewhat difficult to do web development, because the web pages do not accurately render in a browser.

This is what you see when the container is running:

Image

Steps to Reproduce

Follow the instructions on this github on the contributions page, specifically the docker setup:

  1. Install docker
  2. Install docker-compose
  3. Follow the instructions on the docker website to setup the user and user group permissions
  4. Clone this repo
  5. run $ cd ./dev && docker-compose up -d
  6. Navigate to localhost:8000 in a browser

Expected Behavior

All external assets, including images render correctly.

OS Version

8.x (Circe)

OS Architecture

amd64 (on most hardwares)

Session Type

Classic Session (X11)

Software Version

Compiled from git

Log Output

rebecca@becky-desktop:~/git/website_draft$ cd ./dev && docker-compose up
Starting elementary-os-website ... done
Attaching to elementary-os-website
elementary-os-website    | Loading composer repositories with package information
elementary-os-website    | Updating dependencies
elementary-os-website    | Lock file operations: 0 installs, 1 update, 0 removals
elementary-os-website    |   - Upgrading composer/ca-bundle (1.5.9 => 1.5.10)
elementary-os-website    | Writing lock file
elementary-os-website    | Installing dependencies from lock file (including require-dev)
elementary-os-website    | Nothing to install, update or remove
elementary-os-website    | Generating autoload files
elementary-os-website    | 6 packages you are using are looking for funding.
elementary-os-website    | Use the `composer fund` command to find out more!
elementary-os-website    | No security vulnerability advisories found
elementary-os-website    | ./dev/entrypoint.sh: line 6: npm: command not found
elementary-os-website    | ./dev/entrypoint.sh: line 7: npm: command not found
elementary-os-website    | Starting nginx: nginx.
elementary-os-website    | [28-Dec-2025 14:26:21] NOTICE: fpm is running, pid 51
elementary-os-website    | [28-Dec-2025 14:26:21] NOTICE: ready to handle connections
elementary-os-website    | NOTICE: PHP message: The address 172.18.0.1 is not in the database.
elementary-os-website    | 127.0.0.1 -  28/Dec/2025:14:26:39 +0000 "GET /index.php" 200
elementary-os-website    | 127.0.0.1 -  28/Dec/2025:14:26:39 +0000 "GET /403.php" 200
elementary-os-website    | 127.0.0.1 -  28/Dec/2025:14:26:39 +0000 "GET /403.php" 200
elementary-os-website    | 127.0.0.1 -  28/Dec/2025:14:26:39 +0000 "GET /403.php" 200
elementary-os-website    | 127.0.0.1 -  28/Dec/2025:14:26:39 +0000 "GET /403.php" 200
elementary-os-website    | 127.0.0.1 -  28/Dec/2025:14:26:39 +0000 "GET /403.php" 200
elementary-os-website    | 127.0.0.1 -  28/Dec/2025:14:26:39 +0000 "GET /404.php" 200
elementary-os-website    | 127.0.0.1 -  28/Dec/2025:14:26:39 +0000 "GET /404.php" 200
elementary-os-website    | 127.0.0.1 -  28/Dec/2025:14:26:39 +0000 "GET /404.php" 200
elementary-os-website    | 127.0.0.1 -  28/Dec/2025:14:26:39 +0000 "GET /404.php" 200
elementary-os-website    | 127.0.0.1 -  28/Dec/2025:14:26:39 +0000 "GET /404.php" 200
elementary-os-website    | 127.0.0.1 -  28/Dec/2025:14:26:39 +0000 "GET /404.php" 200
elementary-os-website    | 127.0.0.1 -  28/Dec/2025:14:26:39 +0000 "GET /404.php" 200
elementary-os-website    | 127.0.0.1 -  28/Dec/2025:14:26:39 +0000 "GET /404.php" 200
elementary-os-website    | 127.0.0.1 -  28/Dec/2025:14:26:39 +0000 "GET /404.php" 200
elementary-os-website    | 127.0.0.1 -  28/Dec/2025:14:26:39 +0000 "GET /404.php" 200
elementary-os-website    | 127.0.0.1 -  28/Dec/2025:14:26:39 +0000 "GET /404.php" 200
elementary-os-website    | 127.0.0.1 -  28/Dec/2025:14:26:39 +0000 "GET /404.php" 200
elementary-os-website    | 127.0.0.1 -  28/Dec/2025:14:26:39 +0000 "GET /404.php" 200
elementary-os-website    | 127.0.0.1 -  28/Dec/2025:14:26:39 +0000 "GET /404.php" 200
elementary-os-website    | 127.0.0.1 -  28/Dec/2025:14:26:39 +0000 "GET /404.php" 200
elementary-os-website    | 127.0.0.1 -  28/Dec/2025:14:26:39 +0000 "GET /404.php" 200
elementary-os-website    | 127.0.0.1 -  28/Dec/2025:14:26:39 +0000 "GET /404.php" 200
elementary-os-website    | 127.0.0.1 -  28/Dec/2025:14:26:39 +0000 "GET /404.php" 200
elementary-os-website    | 127.0.0.1 -  28/Dec/2025:14:26:39 +0000 "GET /404.php" 200
elementary-os-website    | 127.0.0.1 -  28/Dec/2025:14:26:39 +0000 "GET /404.php" 200

Hardware Info

N/A

Metadata

Metadata

Labels

No labels
No labels

Type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions