Skip to content

Commit

Permalink
fix(api-server): Refresh correctly server when OIDC config changes
Browse files Browse the repository at this point in the history
Signed-off-by: OpenGuidou <[email protected]>
  • Loading branch information
OpenGuidou committed Oct 15, 2024
1 parent 195de1a commit 597d2c5
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions cmd/argocd-server/commands/argocd_server.go
Original file line number Diff line number Diff line change
Expand Up @@ -247,11 +247,11 @@ func NewCommand() *cobra.Command {
stats.RegisterStackDumper()
stats.StartStatsTicker(10 * time.Minute)
stats.RegisterHeapDumper("memprofile")
argocd := server.NewServer(ctx, argoCDOpts, appsetOpts)
argocd.Init(ctx)
lns, err := argocd.Listen()
errors.CheckError(err)
for {
argocd := server.NewServer(ctx, argoCDOpts, appsetOpts)
argocd.Init(ctx)
lns, err := argocd.Listen()
errors.CheckError(err)
var closer func()
ctx, cancel := context.WithCancel(ctx)
if otlpAddress != "" {
Expand All @@ -265,6 +265,7 @@ func NewCommand() *cobra.Command {
if closer != nil {
closer()
}
lns.Close()
}
},
Example: templates.Examples(`
Expand Down

0 comments on commit 597d2c5

Please sign in to comment.