Create certificate
Create a YAML file certificate-test-dekagpu.
Copy nano certificate-test-dekagpu.yaml
Copy and paste the following YAML contents.
Copy apiVersion: cert-manager.io/v1
kind: Certificate
metadata:
name: test-dekagpu-tls
namespace: default
spec:
dnsNames:
- test-dekagpu.cloudeka.id
issuerRef:
kind: ClusterIssuer
name: letsencrypt-prod
secretName: test-dekagpu-tls
After pasting the syntax, save the file by pressing Ctrl + O, then press the Enter key and exit the editor by pressing Ctrl + X. The next step is to apply configuration
Copy kubectl apply -f certificate-test-dekagpu.yaml
Create ingress
Create a YAML file ingress-test-dekagpu.
Copy nano ingress-test-dekagpu.yaml
Copy and paste the following YAML contents.
Copy apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
name: ingress-test-dekagpu
namespace: default
annotations:
kubernetes.io/ingress.class: nginx
spec:
ingressClassName: nginx
rules:
- host: test-dekagpu.cloudeka.id
http:
paths:
- path: /
pathType: ImplementationSpecific
backend:
service:
name: svc-test-dekagpu
port:
number: 80
tls:
- hosts:
- test-dekagpu.cloudeka.id
secretName: test-dekagpu-tls
After pasting the syntax, save the file by pressing Ctrl + O, then press the Enter key and exit the editor by pressing Ctrl + X. The next step is to apply configuration.
Copy kubectl apply -f ingress-test-dekagpu.yaml
Last updated 2 months ago