Skip to content

Commit

Permalink
Remove first provider container last (#317)
Browse files Browse the repository at this point in the history
remove first prov container last

Signed-off-by: Emily McMullan <emcmulla@redhat.com>
  • Loading branch information
eemcmullan committed Aug 14, 2024
1 parent 94882ff commit 293325e
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion cmd/analyze.go
Original file line number Diff line number Diff line change
Expand Up @@ -2005,7 +2005,8 @@ func (a *analyzeCommand) RmVolumes(ctx context.Context) error {
}

func (a *analyzeCommand) RmProviderContainers(ctx context.Context) error {
for i := range a.providerContainerNames {
// if multiple provider containers, we need to remove the first created provider container last
for i := len(a.providerContainerNames) - 1; i >= 0; i-- {
con := a.providerContainerNames[i]
// because we are using the --rm option when we start the provider container,
// it will immediately be removed after it stops
Expand Down

0 comments on commit 293325e

Please sign in to comment.