LogoLogo
ProductResourcesGitHubStart free
  • Documentation
  • Learn
  • ZenML Pro
  • Stacks
  • API Reference
  • SDK Reference
  • Getting Started
    • Welcome to ZenML
    • Installation
    • Hello World
    • Core Concepts
    • System Architecture
  • Deploying ZenML
    • Deploy
      • Deploy with Docker
      • Deploy with Helm
      • Deploy using HuggingFace Spaces
      • Deploy with custom images
      • Secret management
      • Custom secret stores
    • Connect
      • with your User (interactive)
      • with an API Token
      • with a Service Account
    • Manage
      • Best practices for upgrading
      • Using ZenML server in production
      • Troubleshoot your ZenML server
      • Migration guide
        • Migration guide 0.13.2 → 0.20.0
        • Migration guide 0.23.0 → 0.30.0
        • Migration guide 0.39.1 → 0.41.0
        • Migration guide 0.58.2 → 0.60.0
  • Concepts
    • Steps & Pipelines
      • Configuration
      • Scheduling
      • Logging
      • Advanced Features
      • YAML Configuration
    • Artifacts
      • Materializers
      • Visualizations
    • Stack & Components
    • Service Connectors
    • Containerization
    • Code Repositories
    • Secrets
    • Tags
    • Metadata
    • Models
    • Templates
    • Dashboard
  • Reference
    • Community & content
    • Environment Variables
    • llms.txt
    • FAQ
    • Global settings
    • Legacy docs
Powered by GitBook
On this page

Was this helpful?

Edit on GitHub
  1. Deploying ZenML

Manage

Learn how to upgrade your server to a new version of ZenML for the different deployment options.

Previouswith a Service AccountNextBest practices for upgrading

Last updated 12 days ago

Was this helpful?

The way to upgrade your ZenML server depends a lot on how you deployed it. However, there are some best practices that apply in all cases. Before you upgrade, check out the guide.

In general, upgrade your ZenML server as soon as you can once a new version is released. New versions come with a lot of improvements and fixes from which you can benefit.

To upgrade to a new version with docker, you have to delete the existing container and then run the new version of the zenml-server image.

Check that your data is persisted (either on persistent storage or on an external MySQL instance) before doing this.

Optionally also perform a backup before the upgrade.

  • Delete the existing ZenML container, for example like this:

    # find your container ID
    docker ps
    # stop the container
    docker stop <CONTAINER_ID>
    
    # remove the container
    docker rm <CONTAINER_ID>
  • Deploy the version of the zenml-server image that you want to use. Find all versions .

    docker run -it -d -p 8080:8080 --name <CONTAINER_NAME> zenmldocker/zenml-server:<VERSION>

To upgrade your ZenML server Helm release to a new version, follow the steps below.

Simple in-place upgrade

If you don't need to change any configuration values, you can perform a simple in-place upgrade that reuses your existing configuration:

helm -n <namespace> upgrade zenml-server oci://public.ecr.aws/zenml/zenml --version <VERSION> --reuse-values

Upgrade with configuration changes

If you need to modify your ZenML server configuration during the upgrade, follow these steps instead:

  • Extract your current configuration values to a file:

    helm -n <namespace> get values zenml-server > custom-values.yaml
  • Make the necessary changes to your custom-values.yaml file (make sure they are compatible with the new version)

  • Upgrade the release using your modified values file:

    helm -n <namespace> upgrade zenml-server oci://public.ecr.aws/zenml/zenml --version <VERSION> -f custom-values.yaml

It is not recommended to change the container image tag in the Helm chart to custom values, since every Helm chart version is tested to work only with the default image tag. However, if you know what you're doing you can change the zenml.image.tag value in your custom-values.yaml file to the desired ZenML version (e.g. 0.32.0).

Important Considerations After Upgrading

  • Downgrading is not supported: Downgrading the server to an older version is not supported and can lead to unexpected behavior.

  • Client-server version alignment: The version of the Python client that connects to the server should be kept at the same version as the server.

  • Recreate run templates: After upgrading your ZenML server, you need to recreate any that you were using. Templates are tied to specific server versions and will not work correctly after an upgrade.

best practices for upgrading ZenML
here
run templates
ZenML Scarf