Recreating connections in a new environment

Turribeach Dataiku DSS Core Designer, Neuron, Dataiku DSS Adv Designer, Registered, Neuron 2023 Posts: 1,730 Neuron

Hi, I don't see a way to export/import Dataiku connections to a new Designer environment. I see that the Dataiku API exposes DSS connections, which can be created, modified and deleted through the API. Does anyone have any sample code on how to read a connection from one environment and recreate it on another environment? Thanks!

Best Answer

  • Andrey
    Andrey Dataiker Alumni Posts: 119 ✭✭✭✭✭✭✭
    edited July 17 Answer ✓

    Hi @Turribeach

    You can use Dataiku API python client to copy connection across instances.

    This is how you read a list of existing connections:

    import dataiku, dataikuapi
    client = dataiku.api_client()
    conections = client.list_connections()

    then you can write it to a file, read it from another instance and call

    for conn in connections:

    alternatively you can create a second API client by providing host and API key of your second DSS instance, in this case no need to save connections into file, you can read the list and create copies from the same script

    second_client = dataikuapi.DSSClient(...)

    Note that the passwords won't be copied, you'd have to type them in manually


Setup Info
      Help me…