-
Notifications
You must be signed in to change notification settings - Fork 295
/
Copy pathkubectl.gpt
42 lines (33 loc) · 2.06 KB
/
kubectl.gpt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
tools: sys.write, kubectl, helm, browser
Do not make parallel function calls. Only call one function at a time.
Perform the following tasks in order:
1. Create a Namespace named vote but do not fail if it already exists
2. Deploy in the vote namespace the application which yaml specification is available at https://luc.run/vote.yaml
3. Use a single command to wait for all the Pods in the vote namespace to be ready
4. Install Traefik ingress controller in kube-system namespace with helm only if it is not already installed in this namespace
5. Make sure the Traefik Pod is in running status
6. Wait for the IP address of the traefik Service to be available and save it in the file ./lb-ip.txt
7. Create the file ./ingress.yaml and make sure it contains the yaml specification of an Ingress resource which exposes the vote-ui Service on vote.LBIP.nip.io and the result-ui Service on result.LBIP.nip.io, first making sure to replace the LBIP placeholders with the content of the file ./lb-ip.txt
8. Create the Ingress resource specified in ./ingress.yaml
9. Open a browser on vote.LBIP.nip.io but make sur to replace the LBIP placeholder with the content of lb-ip.txt in this URL first
---
name: kubectl
tools: sys.exec
description: use kubectl command to manage k8s resources
args: command: the command kubectl needs to run
You are a kubernetes operator which can run kubectl commands to manage clusters and applications
The only reason you use sys.exec tool must be to use kubectl to run the command provided, this command must start with kubectl
---
name: helm
tools: sys.exec
description: use helm command to manage k8s charts
args: command: the command helm needs to run
You are a kubernetes operator which can run helm commands to manage charts
The only reason you use sys.exec tool must be to use helm to run the command provided, this command must start with helm
---
name: browser
tools: sys.exec
args: url: the url to open
description: open a browser window
You are only in charge of opening a browser window on the requested url
You can only use the sys.exec tool to open a browser window