Enable Kubectl Shell for AKS
Configure the kubectl shell for for DuploCloud-managed AKS deployments
Step 1. Create a DuploCloud Service
From the Tenant list box, select the correct Tenant.
Navigate to Kubernetes -> Services.
Click Add. The Add Service page displays.
Fill in the fields below. Leave any fields not listed at their default values.
Name
k8s-shell
Cloud
Azure
Platform
AKS Linux
Docker Image
duplocloud/shell:terraform-kubectl-latest
Enter the following in the Environmental Variables field:
- Name: FLASK_APP_SECRET
Value: b33d13ab-5b46-443d-a19d-asdfsd443
- Name: DUPLO_AUTH_URL
Value: https://<CUSTOMER_NAME>.duplocloud.net
Click Next, and then Create.
Step 2: Create a Load Balancer
From the DuploCloud Portal, navigate to Kubernetes -> Services.
From the NAME column, select the
k8s-shell
Service you created in the previous step.Select the Load Balancers tab, and click Configure Load Balancer.
Fill in the fields below. Leave any fields not listed at their default values.
Type
K8S Cluster IP
Container port
80
Health Check
/duplo_auth
Backend Protocol
TCP
Click Add.
Step 3: Add an Ingress
In the DuploCloud Portal, navigate to Kubernetes -> Ingress.
Click Add. The Add Ingress pane displays.
Fill in the fields below. Leave any fields not listed at their default values.
Ingress name
K8s-shell
Ingress controller
azure-application-gateway
Visibility
Public
DNS Prefix
k8s-shell
Certificate
Select from the list box. If not present, you will need to configure a Certificate.
In the Ingress Rules area Click Add Rule.
Complete the following fields in the Add Ingress Rule pane. Leave any fields not listed at their default values.
Service Name
k8s-shell:80
Container port
80
Click Add Rule.
Enter the following in the Annotations field:
appgw.ingress.kubernetes.io/health-probe-path: /duplo_auth
Click Submit.
In the Name field, enter
kubect-shell
. Add a Path that defaults all traffic to the kubectl Service we created in the previous step:
Step 4: Add the DNS Name to System Settings
Navigate to Administrator -> Systems Settings.
Select the System Config tab, and click Add. The Add Config pane displays.
Fill in the fields below.
Config Type
AppConfig
Key
Other
Key
DuploShellFqdn
Value
Paste the fully qualified DNS name* of your kubectl shell ingress/Load Balancer.
Example: https://k8s-shell.example.duplocloud.net
Click Submit. Access to the
kubectl
shell is enabled.
Last updated
Was this helpful?