1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
desc "GITLAB | Migrate SSH Keys" task migrate_keys: :environment do puts "This will add fingerprint to ssh keys in db" ask_to_continue Key.find_each(batch_size: 20) do |key| if key.valid? && key.save print '.' else print 'F' end end end