Web Dev Solutions

Catalin Mititiuc

Web Log

Elixir, JavaScript, SVG, Containers, Git, Linux

Questions, comments, feedback? Contact the author.

Start Erlang's Dialyzer With GUI From A Docker Container

I use Docker mostly when working on software projects and I figured out how to get Erlang’s Dialyzer GUI working in a Docker container.

  1. Start a container with X11 forwarding:

    $ docker run -it --rm --net=host -e "DISPLAY" -e "NO_AT_BRIDGE=1" \
    -v "$XAUTHORITY:/root/.Xauthority:rw" elixir bash
  2. Build “the recommended minimal PLT for Erlang/OTP”:

    # dialyzer --build_plt --apps erts kernel stdlib mnesia
    Creating PLT /root/.cache/erlang/.dialyzer_plt ...
    ...
    done (warnings were emitted)
  3. Start the Dialyzer GUI:

    1. From the command line:

       # dialyzer --gui
    2. From inside an IEx session:

      1. Start the Dialyzer application:

        iex(1)> Application.load(:dialyzer)
        :ok
      2. Start the Dialyzer GUI:

        iex(2)> :dialyzer.gui()

You should now see the Dialyzer GUI.

dialyzer application window