opensafely-core / opensafely-core/backend-server

Disable DNS on reboot in TPP

Open
#240 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Shell
Stars
1
Forks
5
Avg merge
1h 36m
Merged PRs (30d)
2

Description

A reboot will reset the upstream DNS to the default on reboot.

I have not been able to figure out how to make this setting persist reboot. Disabling DNS is off the beaten path, and there's some weird systemd/resolved/cloud-init network configuration stuff going on that I couldn't figure out.

On TPP, running resolvectl dns eth0 "" removes the default upstream DNS resolution, leaving the host with only the static IPs in /etc/hosts, which is what we want.

However, in the DO test backend, and in the local lxd VM, this does not replace the default DNS, just adds to it.

It may be something to do with systemd version, or possibly differences in the user-data or vendor-data passed to cloud-init that the various VMs were provisioned with.

Either way, I can't figure out how to get it to survive reboot. I suspect the answer lies in modifying the cloud-init user-data, perhaps. But I've run out of time, and need to park this.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by comparing the resolvectl dns eth0 "" behavior across TPP, the DO test backend, and the local LXD VM, then inspect the systemd/resolved configuration and cloud-init user-data and vendor-data mentioned in the issue. Done means the DNS setting survives reboot on TPP without restoring upstream resolvers, with the behavior understood across the other environments.

Written by the indexing model from the issue text.

Assessment

Tech stack
shell
Domain
cloud, infrastructure, operating-systems
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.