-
Notifications
You must be signed in to change notification settings - Fork 11
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
tinc.conf generated with wrong hostname if inventory_hostname is fqdn #2
Comments
Umm, "hosts dir"? I see that inventory format for the first time, how does that work? It's usually hosts file in an INI format. Have you tried specifying the hostnames directly in each host inventory variables? That should work, I think. What's the error specifically that the task creates? |
Sorry, I mean "hosts dir" inside tinc config folder that contains RSA keys and other options. As I know tinc read config files in "/etc/tinchosts/" based on names that was defined in ConnectTo. And in this case tinc failed to start. |
I've set tinc_hostname as host variable but it doesn't help
Unfortunately I don't understand why it does not fail with inventory_hostname_short because "Initialize RSA key pairs" task generates rsa_key.pub file. |
Try setting the |
In this case I get invalid tinc configuration because of different hosts name usage FQDN vs hostname.
|
I've looked at task that distributes keys and it uses Not sure what's happening. Could you hop on our IRC channel ( |
I found that tincd doesn't allow use dots in Name, so it wouldn't create public key with follow name /etc/tinc/ProxmoxCluster/hosts/openvz3.example.com.
But iteration thought tinc_inventory_hosts: '{{ groups.debops_tinc }}' that is used for tinc.conf, generate FQDN names. I think to fix it we can play around but I can't understand how to make it beauty.
|
I use an filter_plugin to convert the fqdn to string, but roles can't provide filter_plugin until ansible 3. |
Hello,
I'm using FQDN in my ansible inventory file and found follow issue.
Because tinc_hostname defined as inventory_hostname_short that uses for generate hosts files, and tinc_connect_to uses items from group inventory I'm getting wrong ConnectTo values in
tinc.conf.
Example:
tinc.conf
Hosts dir
But if I change tinc_hostname to inventory_hostname somehow task Create persistent copy of host public key is failed.
The text was updated successfully, but these errors were encountered: