Skip to content

Running server.py in Docker container always seems to refuse HTTP access (403 Forbidden), so can't run test suite #2558

Open
@cjlee112

Description

@cjlee112

I am running a Docker container (python:3.13.1-alpine) to provide the exact CPython version required for working with the corresponding Brython tagged version (3.13.1). I tried to follow the instructions in CONTRIBUTING.md for running the test suite. The server.py runs fine (no error messages), but all attempts to connect to it just get HTTP status 403 Forbidden.

The commands for reproducing this, assuming you are in the Brython source directory, having already run make_dist.py and ready to run the test suite::

docker run -it --rm -p 8000:8000 -v "$PWD":/user/src/brython -w /usr/src/brython python:3.13.1-alpine sh
pip install aiohttp
python server.py

Now back in your host shell::

firefox http://localhost:8000/tests

Note same 403 error happens if you connect directly to the docker container IP address::

firefox http://172.17.0.2:8000/tests

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions