Skip to content

Instantly share code, notes, and snippets.

@simplymathematics
Last active April 21, 2023 17:31
Show Gist options
  • Save simplymathematics/05ca7139edb272ea7e9e88e0c029eea5 to your computer and use it in GitHub Desktop.
Save simplymathematics/05ca7139edb272ea7e9e88e0c029eea5 to your computer and use it in GitHub Desktop.
polymake_dev_container

Tested on Ubuntu 22.04:

Run bash setup.sh

Tested on Windows 10

Ctrl + Shift + P and type "dev container". Navigate to the "build" option. Press Enter. Go grab a coffee. Then, your jupyter notebook server will be ready.

// For format details, see https://aka.ms/devcontainer.json. For config options, see the
// README at: https://github.com/devcontainers/templates/tree/main/src/ubuntu
{
"name": "Ubuntu",
// Or use a Dockerfile or Docker Compose file. More info: https://containers.dev/guide/dockerfile
"image": "mcr.microsoft.com/devcontainers/base:jammy",
// Features to add to the dev container. More info: https://containers.dev/features.
// "features": {},
// Use 'forwardPorts' to make a list of ports inside the container available locally.
"forwardPorts": [8888]
// Use 'postCreateCommand' to run commands after the container is created.
// "postCreateCommand": "sudo bash setup.sh"
// Configure tool-specific properties.
// "customizations": {},
// Uncomment to connect as root instead. More info: https://aka.ms/dev-containers-non-root.
// "remoteUser": "root"
}
#!/bin/bash
apt-get update
apt-get install libgmp-dev libmpc-dev libboost-all-dev libperl-dev libxml2 polymake python3-pip -y
python3 -m pip install notebook
jupyter notebook
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment