Skip to content

Commit

Permalink
clear instance source server in pool-agent config
Browse files Browse the repository at this point in the history
  • Loading branch information
site0801 committed Dec 13, 2024
1 parent f696094 commit 536a165
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions pool-agent/cmd/agent.go
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,8 @@ func newAgent(ctx context.Context) (*Agent, error) {
if err != nil {
return nil, err
}
source.Server = ""

c, err := lxd.ConnectLXDUnixWithContext(ctx, "", &lxd.ConnectionArgs{})
if err != nil {
return nil, fmt.Errorf("connect lxd: %w", err)
Expand Down Expand Up @@ -110,6 +112,7 @@ func (a *Agent) reloadConfig() error {
return fmt.Errorf("parse image alias: %w", err)
}
a.InstanceSource = *source
a.InstanceSource.Server = ""
a.ImageAlias = conf.ImageAlias
}
a.ResourceTypesMap = conf.ResourceTypesMap
Expand Down

0 comments on commit 536a165

Please sign in to comment.