Skip to content

Commit

Permalink
Fix logic for deleting AMIs that where tagged by us.
Browse files Browse the repository at this point in the history
  • Loading branch information
ppostma committed Nov 4, 2024
1 parent 212d593 commit 40ca671
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/capistrano/asg/tasks/rolling.rake
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ namespace :rolling do
end

# Only clean up when AMI was tagged by us.
next if exists && (!ami.tag?('capistrano-asg-rolling:version') || !ami.tag?('capistrano-asg-rolling:gem-version'))
next if exists && !ami.tag?('capistrano-asg-rolling:version') && !ami.tag?('capistrano-asg-rolling:gem-version')

logger.verbose "Deleting Launch Template **#{version.name}** version **#{version.version}**..."
version.delete
Expand Down

0 comments on commit 40ca671

Please sign in to comment.