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

Possible typing mistake in class V1HTTPGetAction #444

Closed
rivernews opened this issue May 6, 2020 · 2 comments
Closed

Possible typing mistake in class V1HTTPGetAction #444

rivernews opened this issue May 6, 2020 · 2 comments

Comments

@rivernews
Copy link

rivernews commented May 6, 2020

The typing of port seems to be incorrect:

export declare class V1HTTPGetAction {

  ...

  /**
     * Name or number of the port to access on the container. Number must be in the range 1 to 65535. 
  Name must be an IANA_SVC_NAME.
   */
  'port': object;

  ...

As you can see, the port type is object. However, the comments in the class is indicating it should be a Name or number.

When I look at the Kubernetes documentation, it seems that port are provided by either a string or a number:

livenessProbe:
  httpGet:
    path: /healthz
    port: liveness-port   <--- either a string indicating port name, or a number for the port

I'm wondering should port be type of number | string instead? Or let me know if I'm missing anything else. If somebody else can confirm this understanding is correct, I can create a PR for this.

** I'm using the latest version 0.11.2.

@brendandburns
Copy link
Contributor

This is a duplicate of #370, I've been trying to figure out what happened, there's something in the representation of an IntOrString in the swagger spec that doesn't work right with the code generator.

@brendandburns
Copy link
Contributor

Closing as duplicate

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants