Hi All,
I have a setup of two vault instances and One of them is using transit auto unseal to unseal the main Vault. Both are on local domain.
Main Vault - vault1.soluspki-int.in
Unsealing Vault - vault2.soluspki-in.in
I have generated the certificates using the Vault PKI method. The certificates were working fine. The vault2
is running good, but the vault1,is facing some token new error, while auto unsealing.
This error is appearing, after the self-signed certificates were implemented. I don’t think it’s an issue with certs. But, I can’t access both the vault from my host machine after getting the vaults on domain. Previously, auto unsealing works and I can access vaults on VMs IP.
May 06 11:56:08 vault1.soluspki-int.in vault[3476]: Error parsing Seal configuration: Put "https://vault2.soluspki-int.in:8200/v1/transit/encrypt/autounseal": dial tcp 192.168.56.4:8200: connect: connection refused
May 06 11:56:08 vault1.soluspki-int.in vault[3476]: 2022-05-06T11:56:00.599Z [INFO] proxy environment: http_proxy="" https_proxy="" no_proxy=""
May 06 11:56:08 vault1.soluspki-int.in vault[3476]: 2022-05-06T11:56:04.759Z [INFO] seal.transit: unable to renew token, disabling renewal: err="Put \"https://vault2.soluspki-int.in:8200/v1/auth/token/renew-self\": dial tcp 192.168.56.4:8200: connect: connection refused"
Main Vault - vault1.soluspki-int.in
Config:
# Full configuration options can be found at https://www.vaultproject.io/docs/configuration
ui = true
storage "raft" {
path = "/opt/vault/data"
node_id = "node_1"
}
# HTTPS listener
listener "tcp" {
address = "vault1.soluspki-int.in:8200"
tls_disable = 0
tls_cert_file = "/home/vagrant/certs/fullchain.crt"
tls_key_file = "/home/vagrant/certs/vault1.key"
}
api_addr = "https://vault1.soluspki-int.in:8200"
cluster_addr = "https://vault1.soluspki-int.in:8201"
disable_mlock = true
ui=true
seal "transit" {
address = "https://vault2.soluspki-int.in:8200"
disable_renewal = "false"
key_name = "autounseal"
mount_path = "transit/"
token = "<token-here>"
tls_skip_verify = 0
}
Unsealing Vault - vault2.soluspki-in.in
Config:
# Full configuration options can be found at https://www.vaultproject.io/docs/configuration
ui = true
storage "file" {
path = "/opt/vault/data"
node_id = "node_1"
}
# HTTPS listener
listener "tcp" {
address = "vault2.soluspki-int.in:8200"
tls_disable = 0
tls_cert_file = "/home/vagrant/certs/fullchain.crt"
tls_key_file = "/home/vagrant/certs/vault2.key"
}
api_addr = "https://vault2.soluspki-int.in:8200"
cluster_addr = "https://vault2.soluspki-int.in:8201"
disable_mlock = true
ui=true
My intention is to, test the certs and cant’ even access vault from Windows Host machine. I have added the following IPs to my Windows /etc/hosts
file too.
Please help me out. I can’t figure it out.