Skip to content
Snippets Groups Projects
Commit ac9b3458 authored by Bo-Chun Chen's avatar Bo-Chun Chen
Browse files

Merge branch 'feat-remove-keypair' into 'main'

Feat remove keypair and private key

Closes #20

See merge request rc/packer-openstack-hpc-image!7
parents bedd65c6 e963b3de
No related branches found
No related tags found
No related merge requests found
......@@ -22,7 +22,3 @@ auto_accept_members = false
image_tags = []
# The username to connect to SSH with. Used by Packer build section
ssh_username = "centos"
# Key that will be used for SSH with the machine. Must match key pair name loaded up into the remote.
ssh_keypair_name = ""
# Path to the private key file to use to authenticate with SSH.
ssh_private_key_file = ""
......@@ -17,9 +17,6 @@ source "openstack" "image" {
security_groups = var.security_groups
ssh_username = var.ssh_username
ssh_keypair_name = var.ssh_keypair_name
ssh_private_key_file = var.ssh_private_key_file
}
build {
......@@ -34,16 +31,9 @@ build {
}
provisioner "ansible" {
use_proxy = false
ssh_authorized_key_file = "/home/ubuntu/.ssh/id_rsa.pub"
ansible_env_vars = ["ANSIBLE_HOST_KEY_CHECKING=False"]
playbook_file = "../CRI_XCBC/ood-packer.yaml"
roles_path = "./ansible/roles"
inventory_file = "../CRI_XCBC/hosts"
extra_arguments = [
"--extra-vars", "root_ssh_key='${var.root_ssh_key}'",
"--private-key=${var.ssh_private_key_file}",
"--user=centos",
#"-vvvv"
]
}
}
......@@ -76,13 +76,3 @@ variable "ssh_username" {
default = "centos"
description = "The default username to use for SSH"
}
variable "ssh_keypair_name" {
type = string
description = "SSH keypair to use from OS project"
}
variable "ssh_private_key_file" {
type = string
description = "Private key file"
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment