playbook/roles/k3s-addon/templates/kubernetes-discovery-config.yaml: update
This commit is contained in:
parent
849e80fdfb
commit
e9cbc821e2
@ -1,22 +1,3 @@
|
||||
---
|
||||
kubectl edit cm -n ingress apisix
|
||||
discovery:
|
||||
kubernetes:
|
||||
- id: apisix
|
||||
service:
|
||||
schema: https
|
||||
host: "10.170.0.6"
|
||||
port: "6443"
|
||||
client:
|
||||
token: |-
|
||||
#xxxxxxxxxxxxxxx
|
||||
default_weight: 50
|
||||
namespace_selector:
|
||||
match:
|
||||
- bookinfo
|
||||
- nginx
|
||||
shared_size: 1m
|
||||
---
|
||||
apiVersion: apisix.apache.org/v2
|
||||
kind: ApisixUpstream
|
||||
metadata:
|
||||
@ -30,7 +11,7 @@ spec:
|
||||
apiVersion: apisix.apache.org/v2
|
||||
kind: ApisixRoute
|
||||
metadata:
|
||||
name: bookinfo-route
|
||||
name: bookinfo
|
||||
namespace: bookinfo
|
||||
spec:
|
||||
http:
|
||||
@ -59,3 +40,26 @@ spec:
|
||||
secret:
|
||||
name: bookinfo-tls
|
||||
namespace: bookinfo
|
||||
---
|
||||
curl -k --header "Authorization: Bearer tokenxxxxx" https://10.170.0.8:6443/api
|
||||
---
|
||||
kubectl get secret kubernetes-discovery-token -o jsonpath={.data.token} | base64 -d
|
||||
---
|
||||
kubectl edit cm -n ingress apisix
|
||||
discovery:
|
||||
kubernetes:
|
||||
- id: apisix
|
||||
service:
|
||||
schema: https
|
||||
host: "10.170.0.6"
|
||||
port: "6443"
|
||||
client:
|
||||
token: |-
|
||||
#xxxxxxxxxxxxxxx
|
||||
default_weight: 50
|
||||
namespace_selector:
|
||||
match:
|
||||
- bookinfo
|
||||
- nginx
|
||||
shared_size: 1m
|
||||
---
|
||||
|
||||
Loading…
Reference in New Issue
Block a user