Comments (7)
Update on this issue,
It seems that you can have multiple DNS servers in a single string format with space in between, which it seem to worked for me. However, for the proper formatting of the values, it should be in object format.
Proxmox Release = 8.1
Proxmox Version = 8.1.3
Terraform Version = 1.6.6
Terraform Module = bpg/proxmox v0.40.0
from terraform-provider-proxmox.
Hi @mkopnsrc! 👋🏼
I think this is already supported, albeit not documented.
PVE does not provide an option to specify a list of DNS servers as separate items neither in UI, nor in APIs:
![Screenshot 2023-12-17 at 9 27 38 PM](https://private-user-images.githubusercontent.com/627562/291132685-c70702e0-ff57-43cd-afe4-f65716904ef9.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MTA1NTM1NzgsIm5iZiI6MTcxMDU1MzI3OCwicGF0aCI6Ii82Mjc1NjIvMjkxMTMyNjg1LWM3MDcwMmUwLWZmNTctNDNjZC1hZmU0LWY2NTcxNjkwNGVmOS5wbmc_WC1BbXotQWxnb3JpdGhtPUFXUzQtSE1BQy1TSEEyNTYmWC1BbXotQ3JlZGVudGlhbD1BS0lBVkNPRFlMU0E1M1BRSzRaQSUyRjIwMjQwMzE2JTJGdXMtZWFzdC0xJTJGczMlMkZhd3M0X3JlcXVlc3QmWC1BbXotRGF0ZT0yMDI0MDMxNlQwMTQxMThaJlgtQW16LUV4cGlyZXM9MzAwJlgtQW16LVNpZ25hdHVyZT1jMjFmYzEyY2YwNTNhNWQwYjEyZjAyYTJjNTM2YzliNzQwYjY3NzQ1OWUwMmU0ZmU2YTQyNjNhNmE3YmE4MGU3JlgtQW16LVNpZ25lZEhlYWRlcnM9aG9zdCZhY3Rvcl9pZD0wJmtleV9pZD0wJnJlcG9faWQ9MCJ9.aVEOlz2ePOy1WYQc2_nMSoj8ryG9MQiie2ATlGP5az4)
![Screenshot 2023-12-17 at 9 04 02 PM](https://private-user-images.githubusercontent.com/627562/291127799-3235b304-7e92-4bce-9889-8c0a6b192760.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MTA1NTM1NzgsIm5iZiI6MTcxMDU1MzI3OCwicGF0aCI6Ii82Mjc1NjIvMjkxMTI3Nzk5LTMyMzViMzA0LTdlOTItNGJjZS05ODg5LThjMGE2YjE5Mjc2MC5wbmc_WC1BbXotQWxnb3JpdGhtPUFXUzQtSE1BQy1TSEEyNTYmWC1BbXotQ3JlZGVudGlhbD1BS0lBVkNPRFlMU0E1M1BRSzRaQSUyRjIwMjQwMzE2JTJGdXMtZWFzdC0xJTJGczMlMkZhd3M0X3JlcXVlc3QmWC1BbXotRGF0ZT0yMDI0MDMxNlQwMTQxMThaJlgtQW16LUV4cGlyZXM9MzAwJlgtQW16LVNpZ25hdHVyZT0xOTMwN2RkMDQyNzM0MWMyN2ZiM2E0MTJjMzgzODhkNWU1MTZiMjgyODgwYzU5NDhkMzY1NWQ0YjdlMjQ5MzA3JlgtQW16LVNpZ25lZEhlYWRlcnM9aG9zdCZhY3Rvcl9pZD0wJmtleV9pZD0wJnJlcG9faWQ9MCJ9.4qXQtCXx1LsMXj7BI_w0iano-EKWrSJQoXuMqCJF5g8)
But we can use a space-separated lists of IPs instead (tested with ubuntu cloud image):
dns {
domain = "example.com"
server = "192.168.3.1 192.168.1.1"
}
![Screenshot 2023-12-17 at 9 25 33 PM](https://private-user-images.githubusercontent.com/627562/291132411-26a8cb43-175a-4c76-ac88-6bebe7951559.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MTA1NTM1NzgsIm5iZiI6MTcxMDU1MzI3OCwicGF0aCI6Ii82Mjc1NjIvMjkxMTMyNDExLTI2YThjYjQzLTE3NWEtNGM3Ni1hYzg4LTZiZWJlNzk1MTU1OS5wbmc_WC1BbXotQWxnb3JpdGhtPUFXUzQtSE1BQy1TSEEyNTYmWC1BbXotQ3JlZGVudGlhbD1BS0lBVkNPRFlMU0E1M1BRSzRaQSUyRjIwMjQwMzE2JTJGdXMtZWFzdC0xJTJGczMlMkZhd3M0X3JlcXVlc3QmWC1BbXotRGF0ZT0yMDI0MDMxNlQwMTQxMThaJlgtQW16LUV4cGlyZXM9MzAwJlgtQW16LVNpZ25hdHVyZT0yYzJiY2ZmOTcyZDc0M2VmOWU5YTU3MjczODk3ZWIwMDUxMmU5YTE1MzAyZWZkYTY2M2ZiZmUwY2E5OTI3MjBiJlgtQW16LVNpZ25lZEhlYWRlcnM9aG9zdCZhY3Rvcl9pZD0wJmtleV9pZD0wJnJlcG9faWQ9MCJ9.3s7rQSU7351WnKTWquM0kdw7lCa6rEGLcsKt93iBx5A)
Then, on the VM itself:
ubuntu@test:~$ resolvectl status
Global
Protocols: -LLMNR -mDNS -DNSOverTLS DNSSEC=no/unsupported
resolv.conf mode: stub
Link 2 (eth0)
Current Scopes: DNS
Protocols: +DefaultRoute +LLMNR -mDNS -DNSOverTLS DNSSEC=no/unsupported
Current DNS Server: 192.168.3.1
DNS Servers: 192.168.3.1 182.168.1.1
DNS Domain: example.com
from terraform-provider-proxmox.
I appreciate your quick response, yes you're correct. Would be still possible to support the object based at the module level and when executing on PVE side, it would convert it to string format ?
The object level formatting on code would help admins to spot multiple entries easier and enables for comment for each DNS entries. Ex:
from terraform-provider-proxmox.
That would break backward compatibility with existing deployments. We could probably add a new attribute servers
there, keeping the old server
for compatibility.
from terraform-provider-proxmox.
@all-contributors please add @mkopnsrc for financial
from terraform-provider-proxmox.
I've put up a pull request to add @mkopnsrc! 🎉
from terraform-provider-proxmox.
Thank you @bpg for your support.
from terraform-provider-proxmox.
Related Issues (20)
- local vs local-lvm HOT 3
- [BUG] v0.46.4 -> v0.46.5 breaks : The mac_addresses attribute is missing elements. HOT 3
- Expiration date of proxmox_virtual_environment_user not working HOT 3
- Can't create disk on VM whith SATA interface HOT 1
- setting linux bridge comment field to "" causes TF Error
- snippets upload does not work on Windows HOT 7
- proxmox_virtual_environment_vm initialization stanza needs a boolean to disable cloud-init package updates HOT 1
- proxmox_virtual_environment_vm is not idempotent with cloud init drive datastore_id + interface HOT 2
- It's not possible put a null gateway in a network bridge HOT 3
- Support disconnected interfaces HOT 8
- Add hostname to scaled VM's HOT 8
- SSH Only Mode HOT 4
- LDAP API key is not recognized with current regex
- Initialization settings cannot be cleared when cloning.
- Error creating CTs with large/slow disks "timeout while waiting for task" HOT 5
- proxmox_virtual_environment_certificate always gets updated when a certificate chain is used HOT 1
- SSH Session & Client Closing causes EOF error
- Cloud-init with hashed passwd not work HOT 9
- proxmox_virtual_environment_file set destination file name HOT 3
- Missing protection option for VM HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from terraform-provider-proxmox.