-
Notifications
You must be signed in to change notification settings - Fork 331
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
Add namespaces in knative/pkg #235
Conversation
system/names.go
Outdated
following import: | ||
|
||
import ( | ||
_ "github.com/knative/serving/pkg/system/testing" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
drop serving.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done
system/names.go
Outdated
@@ -0,0 +1,52 @@ | |||
/* | |||
Copyright 2018 The Knative Authors |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
2019 here and elsewhere
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done
system/testing/names.go
Outdated
|
||
func init() { | ||
os.Setenv(system.NamespaceEnvKey, "knative-testing") | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit: delete empty line
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done
/ok-to-test |
ade7b8d
to
d32f26a
Compare
d32f26a
to
b58f3a9
Compare
) | ||
|
||
const ( | ||
NamespaceEnvKey = "SYSTEM_NAMESPACE" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
i am big fan of prefixing env vars with owner name eg KN_SYSTEM_NAMESPACE or something like that. wdyt?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Add prefixing sounds good. If we change to KN_SYSTEM_NAMESPACE
here, do we need to synchronize this to the config yaml file in knative/serving/config
, knative/build/config
and knative/eventing/config
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If anything I'd go with KNATIVE_
, but I could see myself using this package beyond Knative controllers too, so having the key be agnostic could also be useful.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
+1 to @mattmoor . If this pkg use in common place, then I insist the name SYSTEM_NAMESPACE
/lgtm Use |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: mattmoor, zxDiscovery 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 |
/hold cancel |
synchronize with knative/serving#2708