Skip to content

Docker build with opam install ocaml-migrate-parsetree fails #44

Closed
@ryyppy

Description

Hi!

I created a basic OCaml Docker image with an installed OCaml compiler 4.06.0 and opam 1.2.2.

I based off a Dockerfile which installs ocaml-migrate-parsetree like this:

FROM ryyppy/ocaml:4.06.0

RUN opam install ocaml-migrate-parsetree || true

docker build -t my-ocaml -f Dockerfile . does yield following error messages during the build:

Step 1/2 : FROM ryyppy/ocaml:4.06.0
 ---> 9fd61c178361
Step 2/2 : RUN opam install ocaml-migrate-parsetree || true
 ---> Running in 9126211b07a3
The following actions will be performed:
  - install ocaml-migrate-parsetree 1.0.11

=-=- Gathering sources =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
[ocaml-migrate-parsetree: from default] Command started
[ocaml-migrate-parsetree: from default] Command started
[default] https://opam.ocaml.org/archives/ocaml-migrate-parsetree.1.0.11+opam.tar.gz downloaded

=-=- Processing actions -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
[ocaml-migrate-parsetree: jbuilder build] Command started
[ERROR] The compilation of ocaml-migrate-parsetree failed at "jbuilder build -p
        ocaml-migrate-parsetree -j 4".

#=== ERROR while installing ocaml-migrate-parsetree.1.0.11 ====================#
# opam-version         1.2.2
# os                   linux
# command              jbuilder build -p ocaml-migrate-parsetree -j 4
# path                 /home/opam/.opam/system/build/ocaml-migrate-parsetree.1.0.11
# compiler             system (4.06.0)
# exit-code            127
# env-file             /home/opam/.opam/system/build/ocaml-migrate-parsetree.1.0.11/ocaml-migrate-parsetree-5-ad8886.env
# stdout-file          /home/opam/.opam/system/build/ocaml-migrate-parsetree.1.0.11/ocaml-migrate-parsetree-5-ad8886.out
# stderr-file          /home/opam/.opam/system/build/ocaml-migrate-parsetree.1.0.11/ocaml-migrate-parsetree-5-ad8886.err



=-=- Error report -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
The following actions failed
  - install ocaml-migrate-parsetree 1.0.11
No changes have been performed
Removing intermediate container 9126211b07a3
 ---> 509f962534b6
Successfully built 509f962534b6
Successfully tagged my-ocaml:latest

I entered the container and looked into the resulting .out and .err files, but they are empty.

Another interesting thing: When I run the original docker image and do the opam install command in interactive mode, it works just fine.

Any ideas how to fix this?

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