Skip to content

Instantly share code, notes, and snippets.

@clarkezone
Last active September 11, 2023 15:31
Show Gist options
  • Save clarkezone/b22a5851f2e4229f5fd29f1115ddee32 to your computer and use it in GitHub Desktop.
Save clarkezone/b22a5851f2e4229f5fd29f1115ddee32 to your computer and use it in GitHub Desktop.
Tailscale operator test
apiVersion: v1
kind: Namespace
metadata:
name: tailscaletest
---
apiVersion: apps/v1
kind: Deployment
metadata:
name: nginx-tailscale
namespace: tailscaletest
labels:
app: nginx-tailscale
spec:
selector:
matchLabels:
app: nginx-tailscale
replicas: 2 # tells deployment to run 2 pods matching the template
template:
metadata:
labels:
app: nginx-tailscale
spec:
containers:
- name: nginx-tailscale
image: nginx:1.20-alpine
ports:
- containerPort: 80
---
apiVersion: v1
kind: Service
metadata:
name: nginx-tailscale
namespace: tailscaletest
spec:
type: LoadBalancer
loadBalancerClass: tailscale
ports:
- port: 80
selector:
app: nginx-tailscale
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment