| 
									
										
										
										
											2024-12-01 16:07:23 +00:00
										 |  |  | ---
 | 
					
						
							| 
									
										
										
										
											2024-05-16 08:19:27 +08:00
										 |  |  | apiVersion: v1
 | 
					
						
							|  |  |  | kind: PersistentVolumeClaim
 | 
					
						
							|  |  |  | metadata:
 | 
					
						
							|  |  |  |   name: windows-pvc
 | 
					
						
							|  |  |  | spec:
 | 
					
						
							|  |  |  |   accessModes:
 | 
					
						
							| 
									
										
										
										
											2024-12-01 16:07:23 +00:00
										 |  |  |   - ReadWriteOnce
 | 
					
						
							| 
									
										
										
										
											2024-05-16 08:19:27 +08:00
										 |  |  |   resources:
 | 
					
						
							|  |  |  |     requests:
 | 
					
						
							|  |  |  |       storage: 64Gi
 | 
					
						
							|  |  |  | ---
 | 
					
						
							| 
									
										
										
										
											2025-03-07 00:44:47 +01:00
										 |  |  | apiVersion: apps/v1
 | 
					
						
							|  |  |  | kind: Deployment
 | 
					
						
							| 
									
										
										
										
											2024-05-16 08:19:27 +08:00
										 |  |  | metadata:
 | 
					
						
							|  |  |  |   name: windows
 | 
					
						
							|  |  |  |   labels:
 | 
					
						
							|  |  |  |     name: windows
 | 
					
						
							|  |  |  | spec:
 | 
					
						
							| 
									
										
										
										
											2025-03-07 00:44:47 +01:00
										 |  |  |   replicas: 1
 | 
					
						
							|  |  |  |   selector:
 | 
					
						
							|  |  |  |     matchLabels:
 | 
					
						
							|  |  |  |       app: windows
 | 
					
						
							|  |  |  |   template:
 | 
					
						
							|  |  |  |     metadata:
 | 
					
						
							|  |  |  |       labels:
 | 
					
						
							|  |  |  |         app: windows
 | 
					
						
							|  |  |  |     spec:
 | 
					
						
							|  |  |  |       containers:
 | 
					
						
							|  |  |  |       - name: windows
 | 
					
						
							|  |  |  |         image: dockurr/windows
 | 
					
						
							|  |  |  |         env:
 | 
					
						
							|  |  |  |         - name: VERSION
 | 
					
						
							|  |  |  |           value: "11"
 | 
					
						
							|  |  |  |         - name: DISK_SIZE
 | 
					
						
							|  |  |  |           value: "64G"
 | 
					
						
							|  |  |  |         ports:
 | 
					
						
							|  |  |  |           - containerPort: 8006
 | 
					
						
							|  |  |  |             name: http
 | 
					
						
							|  |  |  |             protocol: TCP
 | 
					
						
							|  |  |  |           - containerPort: 3389
 | 
					
						
							|  |  |  |             name: rdp
 | 
					
						
							|  |  |  |             protocol: TCP
 | 
					
						
							|  |  |  |           - containerPort: 3389
 | 
					
						
							|  |  |  |             name: udp
 | 
					
						
							|  |  |  |             protocol: UDP
 | 
					
						
							|  |  |  |           - containerPort: 5900
 | 
					
						
							|  |  |  |             name: vnc
 | 
					
						
							|  |  |  |             protocol: TCP
 | 
					
						
							|  |  |  |         securityContext:
 | 
					
						
							|  |  |  |           capabilities:
 | 
					
						
							|  |  |  |             add:
 | 
					
						
							|  |  |  |             - NET_ADMIN
 | 
					
						
							|  |  |  |           privileged: true
 | 
					
						
							|  |  |  |         volumeMounts:
 | 
					
						
							|  |  |  |         - mountPath: /storage
 | 
					
						
							|  |  |  |           name: storage
 | 
					
						
							|  |  |  |         - mountPath: /dev/kvm
 | 
					
						
							|  |  |  |           name: dev-kvm
 | 
					
						
							|  |  |  |         - mountPath: /dev/net/tun
 | 
					
						
							|  |  |  |           name: dev-tun
 | 
					
						
							|  |  |  |       terminationGracePeriodSeconds: 120
 | 
					
						
							|  |  |  |       volumes:
 | 
					
						
							|  |  |  |       - name: storage
 | 
					
						
							|  |  |  |         persistentVolumeClaim:
 | 
					
						
							|  |  |  |           claimName: windows-pvc
 | 
					
						
							|  |  |  |       - hostPath:
 | 
					
						
							|  |  |  |           path: /dev/kvm
 | 
					
						
							|  |  |  |         name: dev-kvm
 | 
					
						
							|  |  |  |       - hostPath:
 | 
					
						
							|  |  |  |           path: /dev/net/tun
 | 
					
						
							|  |  |  |           type: CharDevice
 | 
					
						
							|  |  |  |         name: dev-tun
 | 
					
						
							| 
									
										
										
										
											2024-05-16 08:19:27 +08:00
										 |  |  | ---
 | 
					
						
							|  |  |  | apiVersion: v1
 | 
					
						
							|  |  |  | kind: Service
 | 
					
						
							|  |  |  | metadata:
 | 
					
						
							|  |  |  |   name: windows
 | 
					
						
							|  |  |  | spec:
 | 
					
						
							| 
									
										
										
										
											2025-03-07 00:44:47 +01:00
										 |  |  |   internalTrafficPolicy: Cluster
 | 
					
						
							| 
									
										
										
										
											2024-12-01 16:07:23 +00:00
										 |  |  |   ports:
 | 
					
						
							| 
									
										
										
										
											2025-03-07 00:44:47 +01:00
										 |  |  |     - name: http
 | 
					
						
							|  |  |  |       port: 8006
 | 
					
						
							|  |  |  |       protocol: TCP
 | 
					
						
							| 
									
										
										
										
											2025-03-18 05:19:44 +01:00
										 |  |  |       targetPort: 8006
 | 
					
						
							| 
									
										
										
										
											2025-03-07 00:44:47 +01:00
										 |  |  |     - name: rdp
 | 
					
						
							|  |  |  |       port: 3389
 | 
					
						
							|  |  |  |       protocol: TCP
 | 
					
						
							|  |  |  |       targetPort: 3389
 | 
					
						
							|  |  |  |     - name: udp
 | 
					
						
							|  |  |  |       port: 3389
 | 
					
						
							|  |  |  |       protocol: UDP
 | 
					
						
							|  |  |  |       targetPort: 3389
 | 
					
						
							|  |  |  |     - name: vnc
 | 
					
						
							|  |  |  |       port: 5900
 | 
					
						
							|  |  |  |       protocol: TCP
 | 
					
						
							|  |  |  |       targetPort: 5900
 | 
					
						
							| 
									
										
										
										
											2024-05-16 08:19:27 +08:00
										 |  |  |   selector:
 | 
					
						
							| 
									
										
										
										
											2025-03-07 00:44:47 +01:00
										 |  |  |     app: windows
 | 
					
						
							|  |  |  |   type: ClusterIP
 |