Set preferences for Docker devices

Note: Enable the Docker plugin to use it.

To set preferences for Docker devices:

  1. Go to Preferences > Devices > Devices.
  2. In Device, select a Docker device.

    {Docker device preferences}

The following table summarizes the preferences you can set.

OptionValue
Run as outside userOn Linux and macOS, sets the user ID and group ID of the user running Qt Creator in the Docker container. This option is not available on Windows.
Do not modify entry pointStops Qt Creator from modifying the entry point of the image. Make sure that the entry point starts a shell.
Enable flags needed for LLDBAdds the following flags to the container to allow LLDB to run:
--cap-add=SYS_PTRACE --security-opt seccomp=unconfined
Clangd executableThe path to a remote Clangd executable for a remote code model.
Paths to mountHost directories to mount into the container, such as the project directory.
Search locationsWhere to automatically detect kit items.

Modify entry points

The entry point of a Docker container is specified in the container settings and started as the main process when starting the container. The entry point can be a shell, an SSH server, or another process, for example. By default, Qt Creator modifies the entry point before it starts a container to make sure that the main process is an sh shell.

To stop Qt Creator from modifying the entry point, select Do not modify entry point. However, if the entry point you specify is not a shell, Qt Creator cannot start the container.

Specify paths to mount

Copy your project files into the Docker container or specify paths to them in Paths to mount. Shared mounts are restricted to locations in the host system that can end up in the same absolute location in the Docker container. On Windows, network mounts cannot be used as shared mounts.

The paths in Paths to mount are mapped one-to-one to the Docker container. Select Insert to browse directories to add. Select Delete Line to delete the selected path or Clear to delete all paths.

Auto-detect kit items

Select Auto-detect Kit Items to find kit items and create kits for the Docker device. You can search for kit items in the device's PATH or in the specified directories.

In Search locations, select:

  • Search in PATH to find kit items in PATH.
  • Search in Selected Directories to find kit items in the selected directories.
  • Search in PATH and Additional Directories to find kit items in the PATH and in the selected directories.

When searching in directories, enter a semicolon-separated list of directory paths in the Docker image to scan for kit entries.

To list the automatically detected kit items, select List Auto-Detected Kit Items. To remove them, select Remove Auto-Detected Kit Items.

See also Enable and disable plugins, How To: Develop for Docker, and How To: Manage Kits.

© 2024 The Qt Company Ltd. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation. Qt and respective logos are trademarks of The Qt Company Ltd in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.