Skip to content
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

Remove occurrences of "master" from the project #1636

Merged
merged 6 commits into from
Jul 8, 2020

Conversation

Raffo
Copy link
Contributor

@Raffo Raffo commented Jun 19, 2020

This is part of #1630 .

After a search in the project, it looks like the only oppressive word that we use is "master", which isn't too bad given that the word is very central to parts of Kubernetes ("the master node") and on GitHub (being master the default branch to date). I still think we can't do better:

  • Master in a lot of parts of the codebase doesn't really tell a great story. We are often talking about the URL of the API server. I renamed in most places to that naming.
  • All GitHub links pointing to master can be replaced with HEAD.

I haven't touched a few occurrences:

cloudbuild.yaml
18:  _PULL_BASE_REF: 'master'

provider/azure/azure_privatedns_test.go
262:			createPrivateMockRecordSet("@", "SOA", "Email: azuredns-hostmaster.microsoft.com"),
298:			createPrivateMockRecordSet("@", "SOA", "Email: azuredns-hostmaster.microsoft.com"),

provider/azure/azure_test.go
266:			createMockRecordSet("@", "SOA", "Email: azuredns-hostmaster.microsoft.com"),
303:			createMockRecordSet("@", "SOA", "Email: azuredns-hostmaster.microsoft.com"),

provider/pdns/pdns_test.go
183:		// Zone kind, one of “Native”, “Master”, “Slave”

provider/rcode0/rcode0_test.go
385:			Masters: []string{
392:			Type:   "MASTER",
397:			Masters: []string{

go.sum
44:github.com/Masterminds/semver v1.4.2 h1:WBLTQ37jOCzSLtXNdoo8bNM8876KhNqOKvrlGITgsTc=
45:github.com/Masterminds/semver v1.4.2/go.mod h1:MB6lktGJrhw8PrUyiEoblNEGEQ+RzHPF078ddwwvV3Y=

docs/tutorials/designate.md
33:$ openstack zone create --email dnsmaster@example.com example.com.

docs/tutorials/rcodezero.md
18:2. Select "MASTER" as domain type, and add your domain name there. Use this domain name instead of "example.com" throughout the rest of this tutorial.

docs/tutorials/rfc2136.md
44:      type master;
52:      type master;
118:- host should be the IP of your master DNS server.

The reasons are:

  • we are not going to change the default branch until we get a green light from the Kubernetes project (see https://groups.google.com/forum/#!topic/kubernetes-dev/jvRPIscaDek ).
  • I am not going to replace a terminology that is specific to a given provider. In that case, the owners of providers will need to do this change. We can't afford breaking anything there.

The only real breaking change in this PR is the change of a flag from master to apiserver, which I'd love to discuss. I'm normally against breaking changes, but it feels appropriate to do so and as long as it is in the release notes, seems fine to me. We could think of supporting both the flags in an intermediate release, but I am not too concerned being this flag used at startup.

Signed-off-by: Raffaele Di Fazio <raffo@github.com>
Signed-off-by: Raffaele Di Fazio <raffo@github.com>
@k8s-ci-robot k8s-ci-robot added the cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. label Jun 19, 2020
@k8s-ci-robot k8s-ci-robot added size/L Denotes a PR that changes 100-499 lines, ignoring generated files. approved Indicates a PR has been approved by an approver from all required OWNERS files. labels Jun 19, 2020
Signed-off-by: Raffaele Di Fazio <raffo@github.com>
@@ -285,7 +285,7 @@ func (cfg *Config) ParseFlags(args []string) error {
app.DefaultEnvars()

// Flags related to Kubernetes
app.Flag("master", "The Kubernetes API server to connect to (default: auto-detect)").Default(defaultConfig.Master).StringVar(&cfg.Master)
app.Flag("apiserver", "The Kubernetes API server to connect to (default: auto-detect)").Default(defaultConfig.APIServerURL).StringVar(&cfg.APIServerURL)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's call it --server similar to kubectl.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Legit, will do the change.

@@ -294,7 +294,7 @@ func TestParseFlags(t *testing.T) {
title: "override everything via environment variables",
args: []string{},
envVars: map[string]string{
"EXTERNAL_DNS_MASTER": "http://127.0.0.1:8080",
"EXTERNAL_DNS_APISERVER": "http://127.0.0.1:8080",
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This needs a gofmt.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I really don't think so, I did it, even in a dedicated commit: 9e19427

@linki
Copy link
Member

linki commented Jul 1, 2020

I agree regarding the API server flag. It's not used by many installations since it runs cluster-internal usually. Let's make sure to put it in the release notes.

@Raffo Raffo added the tide/merge-method-squash Denotes a PR that should be squashed by tide when it merges. label Jul 2, 2020
Raffo added 3 commits July 2, 2020 18:45
Signed-off-by: Raffaele Di Fazio <raffo@github.com>
Signed-off-by: Raffaele Di Fazio <raffo@github.com>
Signed-off-by: Raffaele Di Fazio <raffo@github.com>
@Raffo
Copy link
Contributor Author

Raffo commented Jul 2, 2020

I addressed the comments, PTAL @linki


3. https://github.com/kubernetes-sigs/external-dns/pull/326 - attempt to add multiple target support.

*what it does*: for each pair `DNS Name` + `Record Type` it aggregates **all** targets from the cluster and passes them to Provider. It adds basic support
for DO, Azura, Cloudflare, AWS, GCP, however those are not tested (?). (DNSSimple and Infoblox providers were not updated)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🤣 Azura is a fork from Azure

Copy link
Member

@njuettner njuettner left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/lgtm
/approve

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Jul 8, 2020
@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: njuettner, Raffo

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@k8s-ci-robot k8s-ci-robot merged commit 7505f29 into master Jul 8, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. lgtm "Looks good to me", indicates that a PR is ready to be merged. size/L Denotes a PR that changes 100-499 lines, ignoring generated files. tide/merge-method-squash Denotes a PR that should be squashed by tide when it merges.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants