artifactory-cpp-ce
by Helm
JFrog Artifactory CE for C++
About this chart
JFrog Artifactory CE for C++ Helm Chart
[!NOTE] See the JFrog Helm Charts README for important notices including the container image migration.
JFrog Artifactory CE for C++ is a free Artifactory edition to host C/C++ packages in Conan repositories.
Heads up: Our Helm Chart docs are moving to our main documentation site. For Artifactory installers, see Installing Artifactory.
Prerequisites Details
- Kubernetes 1.19+
Chart Details
This chart will do the following:
- Deploy JFrog Artifactory CE for C++
- Deploy an optional Nginx server
- Deploy an optional PostgreSQL Database
- Optionally expose Artifactory with Ingress Ingress documentation
Installing the Chart
Add JFrog Helm repository
Before installing JFrog helm charts, you need to add the JFrog helm repository to your helm client.
helm repo add jfrog https://charts.jfrog.io
helm repo update
Install Chart
To install the chart with the release name artifactory-cpp-ce:
helm upgrade --install artifactory-cpp-ce jfrog/artifactory-cpp-ce \
--namespace artifactory-cpp-ce --create-namespace \
--set artifactory.postgresql.auth.password=<postgres_password> \
--set artifactory.nginx.generateSelfSignedCert=true
The artifactory.nginx.generateSelfSignedCert=true above is a dev/test opt-in
so the example succeeds out-of-the-box. For production, replace it with
artifactory.nginx.tlsSecretName=<your-secret> — see Nginx TLS Certificate.
Nginx TLS Certificate
Starting with artifactory sub-chart version 107.161.x, the chart no longer auto-generates the nginx TLS certificate by default. You must decide how nginx serves HTTPS. All nginx values in this wrapper chart are namespaced under artifactory.nginx.*.
Fresh install — with artifactory.nginx.https.enabled=true (the default), the install fails unless one of the following is set:
| Option | Values flag | When to use |
|---|---|---|
| Supply your own certificate (recommended) | --set artifactory.nginx.tlsSecretName=<name> | Production; you create a kubernetes.io/tls Secret out-of-band |
| Chart-generated self-signed certificate | --set artifactory.nginx.generateSelfSignedCert=true | Dev / test only — the private key is chart-generated and not issued by a trusted CA |
| Disable HTTPS entirely | --set artifactory.nginx.https.enabled=false | HTTP-only installs; TLS termination happens elsewhere or is not required |
To generate your own tls.crt / tls.key for the recommended option, see the JFrog documentation:
Establish TLS in Artifactory and the JFrog Platform › Generate Certificates.
Supplying your own certificate:
kubectl create namespace artifactory-cpp-ce
kubectl create secret tls artifactory-nginx-tls \
--cert=./tls.crt --key=./tls.key -n artifactory-cpp-ce
helm upgrade --install artifactory-cpp-ce jfrog/artifactory-cpp-ce \
--namespace artifactory-cpp-ce --create-namespace \
--set artifactory.postgresql.auth.password=<postgres_password> \
--set artifactory.nginx.tlsSecretName=artifactory-nginx-tls
Upgrade from earlier chart versions — if the prior release auto-generated the Secret <release>-artifactory-nginx-certificate, the chart discovers it via helm lookup, reuses its tls.crt/tls.key byte-for-byte, and annotates it with helm.sh/resource-policy: keep. HTTPS continues to work with no operator action, and the certificate data is not modified.
The reused certificate is still self-signed by the previous chart and is not suitable for production. Replace it with your own certificate on your next upgrade:
kubectl create secret tls artifactory-nginx-tls \
--cert=./tls.crt --key=./tls.key -n artifactory-cpp-ce
helm upgrade artifactory-cpp-ce jfrog/artifactory-cpp-ce \
--namespace artifactory-cpp-ce \
--reuse-values --set artifactory.nginx.tlsSecretName=artifactory-nginx-tls
Once nginx is running on your certificate, the previously auto-generated Secret is retained (helm.sh/resource-policy: keep) and can be removed manually:
kubectl delete secret <release>-artifactory-nginx-certificate -n artifactory-cpp-ce
If a custom certificate is supplied on the first upgrade to sub-chart version 107.161.x, the legacy auto-generated Secret is deleted by Helm during that upgrade. If you plan to migrate to a custom certificate, no additional cleanup is required.
Accessing Artifactory CE for C++
NOTE: If using artifactory or nginx service type LoadBalancer, it might take a few minutes for Artifactory CE for C++'s public IP to become available.
Updating Artifactory CE for C++
Once you have a new chart version, you can upgrade your deployment with
helm upgrade artifactory-cpp-ce jfrog/artifactory-cpp-ce --namespace artifactory-cpp-ce --create-namespace
Special Upgrade Notes
Artifactory upgrade from 6.x to 7.x (App Version)
Arifactory 6.x to 7.x upgrade requires a one time migration process. This is done automatically on pod startup if needed. It's possible to configure the migration timeout with the following configuration in extreme cases. The provided default should be more than enough for completion of the migration.
artifactory:
artifactory:
# Migration support from 6.x to 7.x
migration:
enabled: true
timeoutSeconds: 3600
- Note: If you are upgrading from 1.x to 3.x and above chart versions, please delete the existing statefulset of postgresql before upgrading the chart due to breaking changes in postgresql subchart.
kubectl delete statefulsets <OLD_RELEASE_NAME>-postgresql
- For more details about artifactory chart upgrades refer here
Deleting Artifactory CE for C++
helm delete artifactory-cpp-ce --namespace artifactory-cpp-ce
This will delete your Artifactory CE for C++ deployment. NOTE: You might have left behind persistent volumes. You should explicitly delete them with
kubectl delete pvc ...
kubectl delete pv ...
Database
The Artifactory CE for C++ chart comes with PostgreSQL deployed by default. For details on the PostgreSQL configuration or customising the database, Look at the options described in the Artifactory helm chart.
Ingress and TLS
To get Helm to create an ingress object with a hostname, add these two lines to your Helm command:
helm upgrade --install artifactory-cpp-ce \
--set artifactory.nginx.enabled=false \
--set artifactory.ingress.enabled=true \
--set artifactory.ingress.hosts[0]="artifactory.company.com" \
--set artifactory.artifactory.service.type=NodePort \
jfrog/artifactory-cpp-ce --namespace artifactory-cpp-ce --create-namespace
To manually configure TLS, first create/retrieve a key & certificate pair for the address(es) you wish to protect. Then create a TLS secret in the namespace:
kubectl create secret tls artifactory-tls --cert=path/to/tls.cert --key=path/to/tls.key
Include the secret's name, along with the desired hostnames, in the Artifactory Ingress TLS section of your custom values.yaml file:
artifactory:
artifactory:
ingress:
## If true, Artifactory Ingress will be created
##
enabled: true
## Artifactory Ingress hostnames
## Must be provided if Ingress is enabled
##
hosts:
- artifactory-cpp-ce.domain.com
annotations:
kubernetes.io/tls-acme: "true"
## Artifactory Ingress TLS configuration
## Secrets must be manually created in the namespace
##
tls:
- secretName: artifactory-tls
hosts:
- artifactory-cpp-ce.domain.com
Useful links
https://www.jfrog.com https://www.jfrog.com/confluence/
Deploy artifactory-cpp-ce with OpenTenant
Each tenant gets its own release of this chart, with its own namespace, secrets and domain. The builder below already has artifactory-cpp-ce on a Hetzner server. Change the host, add apps from the marketplace, then copy the generated files. Providers and prices are samples, and nothing here is sent anywhere.
- Pick a serverConnect Hetzner, OVHcloud or AWS. The builder starts on Hetzner, the cheapest sample rate.
- Place the chartartifactory-cpp-ce is pinned at v107.161.26 in opentenant.yaml. Drag more apps from the marketplace onto a rack.
- ApplySave opentenant.yaml and main.tf from the console, then run the commands below.
# opentenant.yaml, main.tf and dns.tf come from the builder below opentenant validate opentenant.yaml terraform init && terraform apply