Link with Docker

Setting up mabl Link with Docker removes the need of installing Java and setting up the Java-based Link Agent distribution on the host machine. You can simply run the Link Agent inside a Docker container. You can get the Link Agent Docker image from the Dockerhub.

Running the Link Agent inside a Docker container is as simple as running the following command.

$ docker run mablhq/link-agent --api-key <your-api-key> --name <agent-name>

Alternatively you can run the container as a background daemon process in the following way:

$ docker run -d --name mabl-link-agent mablhq/link-agent \
--api-key <your-api-key> --name <agent-name>

Once you run the Docker container, go to Using mabl Link - Step 4 to proceed with the rest of the Link service setup.

Testing against 'localhost'

If your test needs to access services running on the docker host (the machine/VM where docker is running), such as localhost URLs, you will need to add an additional flag when starting docker: --net="host". For example:

$ docker run --net="host" mablhq/link-agent --api-key <your-api-key> --name <agent-name>

Note about --net="host" compatibility

Unfortunately, the --net="host" flag only works in the Linux version of Docker. It will not work on MacOS or Windows. See #1, #2, and #3 for more information.

Updated 10 months ago



Link with Docker


Suggested Edits are limited on API Reference Pages

You can only suggest edits to Markdown body content, but not to the API spec.