output "internal_ips" {
    description = "IPs internes de toutes les instances"
    value = {
        frontend = google_compute_instance.frontend-vm.network_interface[0].network_ip
        backend  = google_compute_instance.backend-vm.network_interface[0].network_ip
        database = google_compute_instance.database-vm.network_interface[0].network_ip
    }
}

output "frontend_public_ip" {
    description = "IP publique du frontend"
    value       = google_compute_instance.frontend-vm.network_interface[0].access_config[0].nat_ip
}

output "instance_names" {
    description = "Noms des instances"
    value = {
        frontend = google_compute_instance.frontend-vm.name
        backend  = google_compute_instance.backend-vm.name
        database = google_compute_instance.database-vm.name
    }
}