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

Documentation for named ports. #1092

Merged
merged 1 commit into from
Oct 13, 2017
Merged

Conversation

fasaxc
Copy link
Member

@fasaxc fasaxc commented Sep 7, 2017

Description

Add documentation for the new named ports feature projectcalico/felix#1534

Todos

  • Tests N/A
  • Documentation
  • Release note

Release Note

Calico now implements support for named ports in policy rules and maps named ports through from Kubernetes Pod and NetworkPolicy resources.  This allows you to attach a name to a particular port on a particular endpoint and then match on the name rathe than the port number.  Different endpoints can use different port numbers for the same named port.


| Field | Description | Accepted Values | Schema | Default |
|-------------|----------------------------------|-------------------|--------|------------|
| name | The name to attach to this port, alowing it to be referred to in [policy rules](./policy#entityrule). Names must be unique within an endpoint. | | string | |
Copy link
Contributor

Choose a reason for hiding this comment

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

alowing -> allowing

@@ -0,0 +1,13 @@
An EndpointPort associates a name with a particular TCP/UDP port of the endpoint, allowing it to
be referenced as a named port in [policy rules]({{site.baseurl}}/{{page.version}}/reference/calicoctl/resources/policy#entityrule).
Copy link
Member

Choose a reason for hiding this comment

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

Does this link render correctly with a space (apparently) between the ] and the ( ? It's a useful TIL if so!

Copy link
Member Author

Choose a reason for hiding this comment

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

No, there's no space, it's just how github renders it if the window is too small.


| Field | Description | Accepted Values | Schema | Default |
|-------------|----------------------------------|-------------------|--------|------------|
| name | The name to attach to this port, allowing it to be referred to in [policy rules](./policy#entityrule). Names must be unique within an endpoint. | | string | |
Copy link
Member

Choose a reason for hiding this comment

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

If this shorter link works, can we use that above as well?

> ** NOTE **
>
> On their own, EndpointPort entries don't result in any change to the connectivity of the port.
> They only have an effect if they are referred to in policy.
Copy link
Member

Choose a reason for hiding this comment

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

Please adapt this according to current master, where the standard Note formatting has slightly changed. (E.g. look for alert-info in master/getting-started/bare-metal/bare-metal.md.)

> Since each named port may refer to many endpoints (and Calico has to expand a named port into
> a set of endpoint/port combinations), using a named port is considerably more expensive in terms
> of CPU than using a simple numeric port. We recommend that they are used sparingly, only where
> the extra indirection is required.
Copy link
Member

Choose a reason for hiding this comment

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

Another Note to adapt to latest standard.

@fasaxc fasaxc changed the title [WiP] Documentation for named ports. Documentation for named ports. Oct 13, 2017
@nelljerram nelljerram merged commit 13c8876 into projectcalico:master Oct 13, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants