Skip to content
This repository has been archived by the owner on Feb 27, 2023. It is now read-only.

Implements Contour Namespace API #25

Merged
merged 1 commit into from
Sep 24, 2020

Conversation

danehans
Copy link
Contributor

Implements the Namespace API added in #20. Updates ensureNamespace() and ensureNamespaceRemoved() to use a Contour object instead of a namespace string as a parameter. Updates ensureNamespaceRemoved() to only remove the namespace if RemoveOnDeletion is unset and the namespace does not match a name in namespaceBlacklist.

Requires PR #24

/assign @jpeach @stevesloka
/cc @Miciah

Signed-off-by: Daneyon Hansen [email protected]

controller/contour/namespace.go Outdated Show resolved Hide resolved
@danehans danehans force-pushed the ns_api_impl branch 2 times, most recently from 06a3f12 to aef797c Compare September 17, 2020 00:34
@danehans
Copy link
Contributor Author

@stevesloka commit aef797c addresses your feedback and also implements a portion of the API that was previously missing (not removing the namespace if another contour exists), PTAL.

/cc @Miciah

Copy link
Member

@skriss skriss left a comment

Choose a reason for hiding this comment

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

handful of comments but this mostly looks good!

controller/contour/controller.go Outdated Show resolved Hide resolved
controller/contour/controller.go Outdated Show resolved Hide resolved
controller/contour/namespace.go Outdated Show resolved Hide resolved

// contoursExist lists Contour objects in all namespaces if all is true or only the
// namespace of contour otherwise, returning true if any exist other than contour.
func (r *Reconciler) contoursExist(ctx context.Context, contour *operatorv1alpha1.Contour, all bool) (bool, error) {
Copy link
Member

Choose a reason for hiding this comment

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

all is not currently specified as true anywhere, but I assume you have a plan to use it?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

controller/contour/controller.go Outdated Show resolved Hide resolved
@danehans
Copy link
Contributor Author

@skriss I really appreciate the review. Commit c3ac3d3 addresses your feedback, PTAL.

@skriss
Copy link
Member

skriss commented Sep 23, 2020

Needs a rebase now that #19 has merged.

Signed-off-by: Daneyon Hansen <[email protected]>
@danehans
Copy link
Contributor Author

@skriss commit 58ac6b6 resolves the conflict, PTAL.

Copy link
Member

@skriss skriss left a comment

Choose a reason for hiding this comment

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

LGTM :shipit:

@danehans
Copy link
Contributor Author

@stevesloka PTAL when you have a moment.

@stevesloka stevesloka merged commit 99d8d5b into projectcontour:main Sep 24, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants