To assign a fixed port:
- Get Smart Check help chart. Download the latest Smart Check version using the command below.
If you need to download a specific version, follow this link.#Download Helm chart curl -LO https://github.com/deep-security/smartcheck-helm/archive/master.tar.gz #Extract file tar -xvzf master.tar.gz
- Edit the proxy.yaml service object using a text editor.
vi ./smartcheck-helm-master/templates/proxy.yaml
- Look for "kind: Service", and then add "nodePort: <30000 - 32767>" under .spec.ports.
NodePort only allows port 30000 to 32767 as value.apiVersion: v1 kind: Service metadata: ... spec: type: {{ default "LoadBalancer" .Values.service.type }} ports: - port: {{ default 443 .Values.service.httpsPort }} targetPort: 8443 nodePort: 30443 #Added nodePort value protocol: TCP name: https - port: {{ default 80 .Values.service.httpPort }} targetPort: 8080 nodePort: 30080 #Added nodePort value protocol: TCP name: http ...
- Install Smart Check with "--set service.type=NodePort" flag.
helm install --values overrides.yaml --set service.type=NodePort deepsecurity-smartcheck ./smartcheck-helm-master/
- Verify the service NodePort using the command below.
kubectl get services
You should now be able to access the Smart Check web console using the following:
https://<kubernetes node FQDN/IP>:<https NodePort>/