mirror of
				https://gitee.com/devstar/devstar-devcontainer-operator
				synced 2025-11-02 03:40:34 +00:00 
			
		
		
		
	fix RBAC using '+kubebuilder:rbac:' prefix
	
		
			
	
		
	
	
		
	
		
			All checks were successful
		
		
	
	
		
			
				
	
				DevStar DevContainer Operator CI Pipeline - main branch / build-and-push-devstar-devcontainer-operator (push) Successful in 1m5s
				
			
		
		
	
	
				
					
				
			
		
			All checks were successful
		
		
	
	DevStar DevContainer Operator CI Pipeline - main branch / build-and-push-devstar-devcontainer-operator (push) Successful in 1m5s
				
			This commit is contained in:
		@@ -4,6 +4,26 @@ kind: ClusterRole
 | 
			
		||||
metadata:
 | 
			
		||||
  name: manager-role
 | 
			
		||||
rules:
 | 
			
		||||
- apiGroups:
 | 
			
		||||
  - ""
 | 
			
		||||
  resources:
 | 
			
		||||
  - services
 | 
			
		||||
  verbs:
 | 
			
		||||
  - create
 | 
			
		||||
  - delete
 | 
			
		||||
  - get
 | 
			
		||||
  - list
 | 
			
		||||
  - watch
 | 
			
		||||
- apiGroups:
 | 
			
		||||
  - apps
 | 
			
		||||
  resources:
 | 
			
		||||
  - statefulsets
 | 
			
		||||
  verbs:
 | 
			
		||||
  - create
 | 
			
		||||
  - delete
 | 
			
		||||
  - get
 | 
			
		||||
  - list
 | 
			
		||||
  - watch
 | 
			
		||||
- apiGroups:
 | 
			
		||||
  - devcontainer.devstar.cn
 | 
			
		||||
  resources:
 | 
			
		||||
@@ -30,9 +50,3 @@ rules:
 | 
			
		||||
  - get
 | 
			
		||||
  - patch
 | 
			
		||||
  - update
 | 
			
		||||
- apiGroups: [""]
 | 
			
		||||
  resources: ["services"]
 | 
			
		||||
  verbs: ["create", "delete", "get", "list", "watch"]
 | 
			
		||||
- apiGroups: ["apps"]
 | 
			
		||||
  resources: ["statefulsets"]
 | 
			
		||||
  verbs: ["create", "delete", "get", "list", "watch"]
 | 
			
		||||
 
 | 
			
		||||
@@ -43,6 +43,8 @@ type DevcontainerAppReconciler struct {
 | 
			
		||||
// +kubebuilder:rbac:groups=devcontainer.devstar.cn,resources=devcontainerapps,verbs=get;list;watch;create;update;patch;delete
 | 
			
		||||
// +kubebuilder:rbac:groups=devcontainer.devstar.cn,resources=devcontainerapps/status,verbs=get;update;patch
 | 
			
		||||
// +kubebuilder:rbac:groups=devcontainer.devstar.cn,resources=devcontainerapps/finalizers,verbs=update
 | 
			
		||||
// +kubebuilder:rbac:groups=apps,resources=statefulsets,verbs=create;delete;get;list;watch
 | 
			
		||||
// +kubebuilder:rbac:groups="",resources=services,verbs=create;delete;get;list;watch
 | 
			
		||||
 | 
			
		||||
// Reconcile is part of the main kubernetes reconciliation loop which aims to
 | 
			
		||||
// move the current state of the cluster closer to the desired state.
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user