Page MenuHomePhabricator

Move tools-db and tools-redis into DNS
Closed, ResolvedPublic

Description

These are currently maintained via puppet in /etc/hosts, and don't make it into the containers. Let's move them into DNS so they can!

Event Timeline

Change 296941 had a related patch set uploaded (by Yuvipanda):
labsdns: Allow returning arbitrary A records, not CNAMEs

https://gerrit.wikimedia.org/r/296941

Change 296941 merged by Yuvipanda:
labsdns: Allow returning arbitrary A records, not CNAMEs

https://gerrit.wikimedia.org/r/296941

Ok, right now it's implemented with a hacky lua script that requires a puppet change to change, but ideally should be implemented as:

  1. We add $projectname.wmflabs.org to the search list in /etc/resolv.conf, and then can add these as $thing.$projectname.wmflabs.org in horizon
  2. No step 2.

We already have two items in 'search' in /etc/resolv.conf, and there's a hard limit of 5, and kubernetes might add a couple more, so we have to examine that carefully...

Change 296947 had a related patch set uploaded (by Yuvipanda):
labsdns: Add tools-redis to DNS alias as well

https://gerrit.wikimedia.org/r/296947

Change 296947 merged by Yuvipanda:
labsdns: Add tools-redis to DNS alias as well

https://gerrit.wikimedia.org/r/296947

scfc triaged this task as Normal priority.Nov 27 2016, 12:30 AM
scfc removed a project: Patch-For-Review.
scfc moved this task from Triage to Backlog on the Toolforge board.

Change 328453 had a related patch set uploaded (by Tim Landscheidt):
Tools: Remove redundant tools-db entry from /etc/hosts

https://gerrit.wikimedia.org/r/328453

Change 328453 merged by Andrew Bogott:
Tools: Remove redundant tools-db entry from /etc/hosts

https://gerrit.wikimedia.org/r/328453

bd808 edited projects, added Kubernetes; removed Toolforge.Jul 28 2017, 11:02 PM
bd808 added a comment.Aug 3 2018, 3:57 PM

It looks like this was actually done and we just never did the final cleanup in the hosts file.

$ dig @labs-recursor1.wikimedia.org. tools-redis.tools.eqiad.wmflabs

; <<>> DiG 9.9.5-3ubuntu0.17-Ubuntu <<>> @labs-recursor1.wikimedia.org. tools-redis.tools.eqiad.wmflabs
; (1 server found)
;; global options: +cmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 8160
;; flags: qr rd ra; QUERY: 1, ANSWER: 1, AUTHORITY: 0, ADDITIONAL: 0

;; QUESTION SECTION:
;tools-redis.tools.eqiad.wmflabs. IN    A

;; ANSWER SECTION:
tools-redis.tools.eqiad.wmflabs. 300 IN A       10.68.22.56

;; Query time: 1 msec
;; SERVER: 208.80.154.20#53(208.80.154.20)
;; WHEN: Fri Aug 03 15:50:30 UTC 2018
;; MSG SIZE  rcvd: 65
$ dig @labs-recursor0.wikimedia.org. tools-redis.tools.eqiad.wmflabs

; <<>> DiG 9.9.5-3ubuntu0.17-Ubuntu <<>> @labs-recursor0.wikimedia.org. tools-redis.tools.eqiad.wmflabs
; (1 server found)
;; global options: +cmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 63192
;; flags: qr rd ra; QUERY: 1, ANSWER: 1, AUTHORITY: 0, ADDITIONAL: 0

;; QUESTION SECTION:
;tools-redis.tools.eqiad.wmflabs. IN    A

;; ANSWER SECTION:
tools-redis.tools.eqiad.wmflabs. 192 IN A       10.68.22.56

;; Query time: 4 msec
;; SERVER: 208.80.155.118#53(208.80.155.118)
;; WHEN: Fri Aug 03 15:50:40 UTC 2018
;; MSG SIZE  rcvd: 65
Bstorm added a comment.Aug 3 2018, 4:10 PM

I noticed the same thing. I was actually curious if that hosts file is needed at all at this point.

Change 450247 had a related patch set uploaded (by Bstorm; owner: Bstorm):
[operations/puppet@production] gridengine: remove puppetized hosts file

https://gerrit.wikimedia.org/r/450247

Change 450247 merged by Bstorm:
[operations/puppet@production] gridengine: remove puppetized hosts file

https://gerrit.wikimedia.org/r/450247

Change 450624 had a related patch set uploaded (by Bstorm; owner: Bstorm):
[operations/puppet@production] gridengine: remove variables that were for deleted template

https://gerrit.wikimedia.org/r/450624

Change 450624 merged by Bstorm:
[operations/puppet@production] gridengine: remove variables that were for deleted template

https://gerrit.wikimedia.org/r/450624

So for the final step of this (making svc domain for the redis server), it looks like that should be something like: https://gerrit.wikimedia.org/r/c/operations/puppet/+/397256

bd808 closed this task as Resolved.Aug 27 2018, 8:05 PM
bd808 assigned this task to Bstorm.

Let's call this done. I was thinking about adding some service name like tools.redis.svc.eqiad.wmflabs for redis, but since this is really just for things inside the Toolforge project I am now thinking that the tools-redis.tools.eqiad.wmflabs name is fine. We already have tools.db.svc.eqiad.wmflabs up and working for the database component of this task.