Connect to a deployed ZenML

Learning about the ZenML server.

This is an older version of the ZenML documentation. To read and view the latest version please visit this up-to-date URL.

Connect to a deployed ZenML

Although the basic functionalities of ZenML work perfectly on your local machine, you need to connect to a deployed ZenML server to use remote services and infrastructure.

ZenML Server

When you first get started with ZenML, it is based on the following architecture on your machine.

The SQLite database that you can see in this diagram is used to store information about pipelines, pipeline runs, stacks, and other configurations. In the previous pages, we used the zenml up command to spin up a local rest server to serve the dashboard as well. The diagram for this will look as follows:

In order to move into production, you will need to deploy this server somewhere centrally so that the different cloud stack components can read from and write to the server. Additionally, this also allows all your team members to connect to it and share stacks and pipelines.

Connect your client to the server

When ZenML is deployed, the client can be explicitly connected. This is how you do it:

zenml connect --url https://<your-own-deployment> --username default

You will be prompted for your password:

Connecting to: 'https://<your-own-deployment>'...
Password for user zenml (press ENTER for empty password) []:

In Scenario 2, the zenml up command implicitly connects the client to the server.

In order to use the zenml connect command, you need to first deploy a remote ZenML server. If you are the person who is setting up it for your organization and looking for detailed documentation regarding the deployment, head on over to the Platform Guide to set it up on your infrastructure of choice.

Alternatively, if you are just getting started and want to try things out along with this starter guide, take a look at the ZenML Sandbox, which allows you to spin up a remote sandbox ZenML deployment.

And just like that, your client should be connected to the server. You can simply verify this by running zenml status:

Using configuration from: '/home/apenner/.config/zenml'
Local store files are located at: '/home/apenner/.config/zenml/local_stores'
Connected to a ZenML server: '<your-own-deployment>'
The current user is: 'zenml'
The active workspace is: 'default' (global)
The active stack is: 'default' (global)

Similarly, you can disconnect from a server using zenml disconnect

Last updated