Browse Source

policy sync

pull/3/head
Vladimir Smagin 1 year ago
parent
commit
6156370ebd
2 changed files with 12 additions and 11 deletions
  1. +10
    -10
      deploy/crds/rabbitmq_v1_rabbitmq_cr.yaml
  2. +2
    -1
      pkg/controller/rabbitmq/rabbitmq_users.go

+ 10
- 10
deploy/crds/rabbitmq_v1_rabbitmq_cr.yaml View File

@@ -26,13 +26,13 @@ spec:
- PLAIN
- AMQPLAIN
volume_size: 1Gi
# policies:
# - name: ha-three
# vhost: "rabbit"
# pattern: ".*"
# definition:
# ha-mode: "exactly"
# ha-params: 3
# ha-sync-mode: "automatic"
# priority: 0
# apply-to: all
policies:
- name: ha-three
vhost: "rabbit"
pattern: ".*"
definition:
ha-mode: "exactly"
ha-params: 3
ha-sync-mode: "automatic"
priority: 0
apply-to: all

+ 2
- 1
pkg/controller/rabbitmq/rabbitmq_users.go View File

@@ -97,8 +97,9 @@ func (r *ReconcileRabbitmq) syncUsersCredentials(ctx context.Context, reqLogger
// do not remove service account, seriosly
continue
}
reqLogger.Info("Removing " + user)
err = r.apiUserRemove(reqLogger, cr, secret, rabbitmqUserStruct{Name:user})
err = r.apiUserRemove(reqLogger, cr, serviceAccount, rabbitmqUserStruct{Name:user})
if err != nil {
return err
}


Loading…
Cancel
Save