[dns] Add support for static DNS configuration.#14239
[dns] Add support for static DNS configuration.#14239oleksandrivantsiv wants to merge 0 commit intosonic-net:masterfrom
Conversation
|
Does this feature cover DNS configuration inside container? For example, "docker exec telemetry cat /etc/resolv.conf" |
Yes. During the container start the docker daemon copies "/etc/resolv.conf" from the host OS rootfs to the docker container rootfs. |
|
|
There was a problem hiding this comment.
If your intention is to check if the table is empty, no need to dump.
4 is magic number, you may consider sonic-db-cli with CONFIG_DB.
@judyjoseph to check multi-asic and T2.
Wondering if KUBELET_EXTRA_ARGS is impacted by this new feature? @lixiaoyuner could you help review? Refers to: files/build_templates/sonic_debian_extension.j2:477 in 4fd0180. [](commit_id = 4fd01802a87f2edfe5ac75651ac5e3c7dacf146e, deletion_comment = False) |
There was a problem hiding this comment.
Those are mutually exclusive approaches. If the user wants to edit /etc/resolv.conf manually it should not configure DNS via config DB and vice-versa. The default behavior is preserved if no DNS entries are specified in the config DB.
4fd0180 to
6f54251
Compare
Why I did it
Add support for static DNS configuration. According to sonic-net/SONiC#1262 HLD.
How I did it
Add a new
resolv-config.servicethat is responsible for transferring configuration from Config DB into/etc/resolv.conffile that is consumed by various subsystems in Linux to resolve domain names into IP addresses.How to verify it
Which release branch to backport (provide reason below if selected)
Description for the changelog
Ensure to add label/tag for the feature raised. example - PR#2174 under sonic-utilities repo. where, Generic Config and Update feature has been labelled as GCU.
Link to config_db schema for YANG module changes
A picture of a cute animal (not mandatory but encouraged)