Skip to content

chris-armstrong/ocaml-devcontainer

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

79 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Devcontainer with OCaml

Pre-installed OCaml with OCaml package manager (opam) for devcontainer. You can find the images in ghcr.io/chris-armstrong/ocaml-devcontainer.

Quickstart

Make a devcontainer setting file at .devcontainer/devcontainer.json in your project.

{
    "image": "ghcr.io/chris-armstrong/ocaml-devcontainer",
    "features": {
        "ghcr.io/devcontainers/features/common-utils:2": {
            "version": "latest"
        }
    },
    "customizations": {
        "vscode": {
            "extensions": [
                "ocamllabs.ocaml-platform"
            ]
        }
    },
    "remoteUser": "ocaml",
    "updateRemoteUserUID": true
}

Then, reopen in container.

Tags

Tags are named by <version>-<distribution>[-root].

  • Images are tagged with its OCaml version. For example, latest tags mean that the image is created with the latest version of OCaml.
  • There are various base OS distributions. available distributions are as follows:
    • debian: latest Debian (default)
    • ubuntu: latest Ubuntu LTS
  • -root images come without non-root user ocaml.

Cross-compile Images

All images are cross-compiled with docker-buildx.

Requirements

Some system libraries for emulation are needed.

$ sudo apt-get update
$ sudo apt-get install -y binfmt-support qemu qemu-user-static

Compile

You can build images for linux/amd64 and linux/arm64 architectures with the following command.

$ docker buildx bake --push

About

Devcontainer with OCaml

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages

  • HCL 50.9%
  • Dockerfile 40.4%
  • Shell 8.7%