Skip to content

Add-on feature

Sovereign Execution is a paid add-on available for the Business and Enterprise plans. For all available add-ons, see Add-ons.

Configure proxies ​

If your network routes outgoing connections through a proxy server, configure the proxy on your sovereign executors. Workflows then reach external services, such as databases and REST APIs, through the proxy.

Choose a proxy provider ​

The proxy provider decides where the executor gets its proxy settings from. Knime supports three providers:

  • Direct: The executor bypasses all proxies.
  • Manual: The executor uses the proxy hosts and ports that you set in the preferences.
  • Native: The executor reads the proxy settings from the operating system.

For details on each provider, see Network connections in the Knime Analytics Platform user guide.

Set the proxy preferences ​

Set the provider and the proxy servers in a preference (.epf) file. The following example configures a manual HTTPS proxy without authentication:

text
/instance/org.eclipse.core.net/proxiesEnabled=true
/instance/org.eclipse.core.net/systemProxiesEnabled=false
/instance/org.eclipse.core.net/nonProxiedHosts=localhost|127.0.0.1
/instance/org.eclipse.core.net/proxyData/HTTPS/host=proxy.example.com
/instance/org.eclipse.core.net/proxyData/HTTPS/port=8080
/instance/org.eclipse.core.net/proxyData/HTTPS/hasAuth=false

The following preferences are available:

PreferenceDescription
/instance/org.eclipse.core.net/proxiesEnabledtrue turns proxies on. false turns them off, which is the same as the Direct provider.
/instance/org.eclipse.core.net/systemProxiesEnabledtrue uses the Native provider. false uses the Manual provider.
/instance/org.eclipse.core.net/nonProxiedHostsHosts that never use the manual proxy, separated by |. Set at least localhost|127.0.0.1.
/instance/org.eclipse.core.net/proxyData/<PROTOCOL>/hostHost name of the proxy server. Replace <PROTOCOL> with HTTP, HTTPS, or SOCKS.
/instance/org.eclipse.core.net/proxyData/<PROTOCOL>/portPort of the proxy server.
/instance/org.eclipse.core.net/proxyData/<PROTOCOL>/hasAuthtrue if the proxy requires authentication. You can't store proxy credentials in the .epf file. See Set up proxy authentication.

The last four preferences apply only to the Manual provider.

To apply the .epf file to your executors, put it in a profile folder, for example /opt/knime/profiles/proxy, and reference the profile in knime.ini. For the steps, see Apply the profile to executors. Use proxy as the profile name instead of kerberos.

Set up proxy authentication ​

A sovereign executor runs headless, so you can't enter proxy credentials on the Network Connections preferences page. Provide them with environment variables or the secure storage.

If workflows reach HTTPS URLs through a proxy that uses basic authentication, also allow basic authentication for tunneling. Add the following line to the knime.ini file in the executor installation folder, below the -vmargs line:

text
-Djdk.http.auth.tunneling.disabledSchemes=""

Without this line, requests fail with 407 Proxy Authentication Required.

From Knime version 5.3, the executor reads proxy environment variables only with the Native provider. The Manual and Direct providers ignore them. The variables use this format:

text
<http|https|socks|all>_proxy=<user>:<password>@<host>:<port>

The <user>:<password>@ prefix is optional and sets the proxy credentials. To exclude hosts from these proxies, list them in the no_proxy variable, separated by commas.

On Linux, this is the simplest setup, because it doesn't depend on users or configuration folders. The trade-off is that the credentials are stored in plain text in the environment, not in the encrypted secure storage.

To provide the credentials as environment variables:

  1. In the .epf file, select the Native provider: /instance/org.eclipse.core.net/systemProxiesEnabled=true.

  2. Create a file that only root can read, for example /etc/knime/proxy.env with owner root and permissions 600:

    text
    https_proxy=http://<user>:<password>@proxy.example.com:8080
    http_proxy=http://<user>:<password>@proxy.example.com:8080
    no_proxy=localhost,127.0.0.1

    URL-encode special characters in the user name and password, for example @ as %40.

  3. In the agent's systemd unit file, /etc/systemd/system/knime-agent.service, add the following line to the [Service] section. For the unit file, see Configuring the Agent as a System Service.

    text
    EnvironmentFile=/etc/knime/proxy.env

    systemd reads the file as root before it starts the agent. The executor inherits the variables from the agent.

  4. Run sudo systemctl daemon-reload and restart the agent.

Workflows that run on the executor can read its environment variables. Use a proxy account with only the permissions it needs.

Option 2: Secure storage ​

The executor reads the proxy credentials from the Eclipse secure storage, which is encrypted with a master password. A headless executor has no UI prompt for the master password. Set the storage location and a master password file explicitly. You also can't add credentials to the storage on the executor itself. Instead, create the storage on a desktop machine and copy it to the executor.

For the Manual provider, set /instance/org.eclipse.core.net/proxyData/<PROTOCOL>/hasAuth=true in the executor's .epf file for each protocol that requires authentication. Replace <PROTOCOL> with HTTP, HTTPS, or SOCKS.

To set up proxy authentication with the secure storage:

  1. Turn off the default master password providers. Create the file <install-dir>/configuration/.settings/org.eclipse.equinox.security.prefs, where <install-dir> is the executor installation folder, with the following content:

    text
    eclipse.preferences.version=1
    org.eclipse.equinox.security.preferences.disabledProviders=org.eclipse.equinox.security.windowspasswordprovider64bit,org.eclipse.equinox.security.osxkeystoreintegration,org.eclipse.equinox.security.linuxkeystoreintegrationjna,org.eclipse.equinox.security.ui.defaultpasswordprovider
  2. Create a text file that contains only the master password, for example /opt/knime/secure/password.txt.

  3. Open the knime.ini file in the executor installation folder. Add the following lines right before the -vmargs line:

    text
    -eclipse.keyring
    /opt/knime/secure/storage
    -eclipse.password
    /opt/knime/secure/password.txt

    -eclipse.keyring sets the location of the secure storage, and -eclipse.password sets the location of the password file. Put each flag and each value on its own line.

  4. Create the secure storage on a desktop machine:

    1. Install Knime Analytics Platform and apply the same configuration as in steps 1 to 3. Use the same org.eclipse.equinox.security.prefs file and a copy of the same password file. Point -eclipse.keyring to a file that doesn't exist yet.
    2. Start Knime Analytics Platform and open Preferences > General > Network Connections. Configure the same provider and proxy entries as in the .epf file. Edit the proxy entry, select Requires Authentication, and enter the user name and password. Click Apply and Close, then close Knime Analytics Platform.
    3. Copy the secure storage file to the -eclipse.keyring path on the executor. Make sure that only the executor user can read the storage file and the password file.
  5. Restart the executor.

To change the master password or the proxy credentials, repeat step 4.

Load customization profiles through a proxy ​

If the executor loads its customization profiles from a remote location behind a proxy, it can't use the proxy preferences, because they're part of the profile. Instead, set the proxy as Java networking properties in knime.ini, below the -vmargs line:

  • For a manual proxy, add -Djava.net.useSystemProxies=false and the properties for your proxy, for example -Dhttps.proxyHost and -Dhttps.proxyPort. For all properties, see the Java networking properties.
  • For the proxy settings of the operating system, add -Djava.net.useSystemProxies=true. This works on Windows, macOS, and GNOME systems. On some Linux setups, it doesn't read proxy environment variables. If the executor can't load the profiles, use a manual proxy instead.

The executor uses this proxy only to load the customization profiles. Workflows still use the proxy from the preferences or the environment variables.

Check the proxy settings ​

To check which proxy settings an executor uses and which URLs it can reach, run the Executor diagnostics data app on the environment.