Skip to content

Setup


This will be relatively painless, we promise!

Integrations

You will need to clone integrations-core and/or integrations-extras depending on which integrations you intend to work on.

Python

To work on any integration you must install Python 3.8+.

After installation, restart your terminal and ensure that your newly installed Python comes first in your PATH.

We recommend using Homebrew.

First update the formulae and Homebrew itself:

brew update

then either install Python:

brew install python

or upgrade it:

brew upgrade python

After it completes, check the output to see if it asked you to run any extra commands and if so, execute them.

Verify successful PATH modification:

which -a python

Windows users have it the easiest.

Simply download the latest x86-64 executable installer and run it. When prompted, be sure to select the option to add to your PATH. Also, it is recommended that you choose the per-user installation method.

Verify successful PATH modification:

where python

Ah, you enjoy difficult things. Are you using Gentoo?

We recommend using either Miniconda or pyenv. Whatever you do, never modify the system Python.

Verify successful PATH modification:

which -a python

ddev

Installation

You have 2 options to install the CLI provided by the package datadog-checks-dev.

Warning

For either option, if you are on macOS/Linux do not use sudo! Doing so will result in a broken installation.

Development

If you cloned integrations-core and want to always use the version based on the current branch, run:

python -m pip install -e "path/to/datadog_checks_dev[cli]"

Note

Be aware that this method does not keep track of dependencies so you will need to re-run the command if/when the required dependencies are changed.

Stable

The latest released version may be installed from PyPI:

python -m pip install --upgrade "datadog-checks-dev[cli]"

Configuration

Upon the first invocation, ddev will create its config file if it does not yet exist.

You will need to set the location of each cloned repository:

ddev config set <REPO> /path/to/integrations-<REPO>

The <REPO> may be either core or extras.

By default, the repo core will be the target of all commands. If you want to switch to integrations-extras, run:

ddev config set repo extras

Docker

Docker is used in nearly every integration's test suite therefore we simply require it to avoid confusion.

  1. Install Docker Desktop for Mac.
  2. Right-click the Docker taskbar item and update Preferences > File Sharing with any locations you need to open.
  1. Install Docker Desktop for Windows.
  2. Right-click the Docker taskbar item and update Settings > Shared Drives with any locations you need to open e.g. C:\.
  1. Install Docker Engine for your distribution:

    [Docker CE for Ubuntu][docker-install-ubuntu]
    
  2. Add your user to the docker group:

    sudo usermod -aG docker $USER
    
  3. Sign out and then back in again so your changes take effect.

After installation, restart your terminal one last time.


Last update: May 15, 2020