How to apply licenses to Artifactory on K8s? [Video]

Matthew Wang
2020-11-18 10:53

How to apply the license to Artifactory running on K8s (HELM installation)


Video Transcription

Hey there. My name is Matthew and in this short video, I’m going to go over how to apply a license to an Artifactory K8 installation. So, the first way is using our Kuberrnetes secret. You can run this command here to create the secret from a license file and then you can pass the secret to helm, to the helm install command, as you can see here.

We’re going to take a quick look at the cluster license file for HA installations. Each license must be separated by two new lines in this license file, as you can see here. I’ve already ran the command and to take a look at the licenses. As you can see in the JFrog Home, var-ATC Artifactory directory, there’s a cluster license file here with the licenses that we were looking at earlier.

The second way is by modifying the values.yaml directly, under Artifactory license, license key. Let’s take a quick look. As you can see here, I have licenses just like we saw on the Artifactory.cluster, the license. And take note that the indentation does matter here. I’ll make sure that each license is under LicenseKey, the column that is. I’ve also ran helm install command using this values.yaml. One second to take a look. As you can see, there’s a cluster license file here as well. And the contents are what we saw in the values.yaml.

So, the third way is to add licenses through a UI. And if you’re adding multiple licenses, you’ll need to separate each license with the space. So, let’s give this a shot. As you can see, I separated the licenses with the space and now if I hit save, it took the two new licenses.

And the last way is by adding licenses through the REST API. So, this REST API takes a JSON body with the licenses and as a POST. Going to take a quick look at the JSON body. Take note that each new line must be, there must be a backslash end for each new line instead of the actual new line. And we could run the curl command, you’ll see that in the response, you’ll see an okay for each license. If you go back to the UI and refresh, you can see that the two licenses were applied. Thanks for your time and I hope this video was helpful.