Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Allow configuring run_docker ports using env vars
This allows changing various `run_docker` settings using env vars. The primary one that I wanted was the ability to easily set the system port used so that I could run two pyodide containers. Before when running a second instance of `./run_docker`: ``` $ ./run_docker docker: Error response from daemon: driver failed programming external connectivity on endpoint quirky_banach (45f5dd12606ac5d732a311ef3f3c378e359bbbd406a1c65915a300ec413eaf25): Bind for 0.0.0.0:8000 failed: port is already allocated. ``` With this PR: ``` $ PYODIDE_SYSTEM_PORT=8001 ./run_docker root@29308e720856:/src# ``` I also broke the `docker run` command on to multiple lines (which I find more readable; hopefully others agree) and added an `exec` to the command, so the shell process on the host doesn't have to hang around waiting for the container to exit.
- Loading branch information