Upgrade

Upgrade the HAProxy Data Plane API on HAProxy Enterprise

This section describes how to upgrade the HAProxy Data Plane API to the latest version.

Upgrade the HAProxy Data Plane API Jump to heading

To upgrade HAProxy Data Plane API:

  1. Install the Data Plane API package. This will upgrade the existing installation. Note that the following examples install version 3.0. You can specify a different package name if you want to install a different version (hapee-extras-dataplaneapi27 for version 2.7, for example).

    nix
    sudo apt-get install hapee-extras-dataplaneapi30
    nix
    sudo apt-get install hapee-extras-dataplaneapi30
    nix
    sudo yum install hapee-extras-dataplaneapi30 --allowerasing
    nix
    sudo yum install hapee-extras-dataplaneapi30 --allowerasing
    nix
    sudo zypper install hapee-extras-dataplaneapi30
    nix
    sudo zypper install hapee-extras-dataplaneapi30
    nix
    sudo pkg install hapee-extras-dataplaneapi30
    nix
    sudo pkg install hapee-extras-dataplaneapi30
    Install in an air-gapped environment

    Note: If your installation of HAProxy Enterprise and HAProxy Data Plane API is in an air-gapped environment, follow these instructions for upgrade:

    • Download the latest version of the Data Plane API package from the HAProxy Enterprise repository. Replace <HAPROXY ENTERPRISE KEY> with your HAProxy Enterprise license key in the URL below to access the repository.

      nix
      https://www.haproxy.com/download/hapee/key/<HAPROXY ENTERPRISE KEY>/extras/
      nix
      https://www.haproxy.com/download/hapee/key/<HAPROXY ENTERPRISE KEY>/extras/

      Navigate to the directory for your operating system. The Data Plane API package (.deb for Debian/Ubuntu or .rpm for RHEL) will be located at /<arch>/pool inside that directory.

    • Install the Data Plane API package. This will upgrade the existing installation.

      nix
      sudo dpkg -i --force-depends <PACKAGE NAME>.deb
      nix
      sudo dpkg -i --force-depends <PACKAGE NAME>.deb
      nix
      sudo rpm -Uvh --nodeps <PACKAGE NAME>.rpm
      nix
      sudo rpm -Uvh --nodeps <PACKAGE NAME>.rpm
  2. Reload the systemd file and restart the service:

    nix
    sudo systemctl daemon-reload
    sudo systemctl restart hapee-extras-dataplaneapi
    nix
    sudo systemctl daemon-reload
    sudo systemctl restart hapee-extras-dataplaneapi
  3. As of version 2.8, your Data Plane API configuration file should be in the .yml format. You can convert your Data Plane API configuration file in .hcl format to .yml format by installing and running the hapee-extras-hclconverter utility.

Convert HCL configuration file to YAML Jump to heading

As of version 2.8, your Data Plane API configuration file should be in the YAML format. To convert your HCL Data Plane API configuration file to YAML:

  1. Install the hapee-extras-hclconverter utility.

    nix
    sudo apt install hapee-extras-hclconverter
    nix
    sudo apt install hapee-extras-hclconverter
    nix
    sudo yum install hapee-extras-hclconverter
    nix
    sudo yum install hapee-extras-hclconverter
    nix
    sudo zypper install hapee-extras-hclconverter
    nix
    sudo zypper install hapee-extras-hclconverter
    nix
    sudo pkg install hapee-extras-hclconverter
    nix
    sudo pkg install hapee-extras-hclconverter
    Install in an air-gapped environment

    If your installation of HAProxy Enterprise and HAProxy Data Plane API is in an air-gapped environment, follow these instructions for installing the hapee-extras-hclconverter utility:

    • Download the latest version of the hapee-extras-hclconverter utility package from the HAProxy Enterprise repository. Replace <HAPROXY ENTERPRISE KEY> with your HAProxy Enterprise license key in the URL below to access the repository.

      nix
      https://www.haproxy.com/download/hapee/key/<HAPROXY ENTERPRISE KEY>/extras/
      nix
      https://www.haproxy.com/download/hapee/key/<HAPROXY ENTERPRISE KEY>/extras/

      Navigate to the directory for your operating system. The hapee-extras-hclconverter utility package (.deb for Debian/Ubuntu or .rpm for RHEL) will be located at /<arch>/pool inside that directory.

    • Install the hapee-extras-hclconverter utility.

      nix
      sudo dpkg -i --force-depends <PACKAGE NAME>.deb
      nix
      sudo dpkg -i --force-depends <PACKAGE NAME>.deb
      nix
      sudo rpm -ivh --nodeps <PACKAGE NAME>.rpm
      nix
      sudo rpm -ivh --nodeps <PACKAGE NAME>.rpm
  2. Run the hapee-extras-hclconverter. It takes the following arguments in this order:

    • the path of your existing Data Plane API configuration file in .hcl format
    • the path for the new configuration file in .yml format

    Most likely, the new configuration file will reside in the same directory as the old configuration file.

    nix
    sudo /opt/hapee-extras/bin/hcl-converter /etc/hapee-extras/dataplaneapi.hcl /etc/hapee-extras/dataplaneapi.yml
    nix
    sudo /opt/hapee-extras/bin/hcl-converter /etc/hapee-extras/dataplaneapi.hcl /etc/hapee-extras/dataplaneapi.yml
    output
    text
    Input file: /etc/hapee-extras/dataplaneapi.hcl
    Output file: /etc/hapee-extras/dataplaneapi.yml
    output
    text
    Input file: /etc/hapee-extras/dataplaneapi.hcl
    Output file: /etc/hapee-extras/dataplaneapi.yml
    nix
    sudo /opt/hapee-extras/bin/hcl-converter /etc/hapee-extras/dataplaneapi.hcl.rpmsave /etc/hapee-extras/dataplaneapi.yml
    nix
    sudo /opt/hapee-extras/bin/hcl-converter /etc/hapee-extras/dataplaneapi.hcl.rpmsave /etc/hapee-extras/dataplaneapi.yml
    output
    text
    Input file: /etc/hapee-extras/dataplaneapi.hcl.rpmsave
    Output file: /etc/hapee-extras/dataplaneapi.yml
    output
    text
    Input file: /etc/hapee-extras/dataplaneapi.hcl.rpmsave
    Output file: /etc/hapee-extras/dataplaneapi.yml

Do you have any suggestions on how we can improve the content of this page?