-
Notifications
You must be signed in to change notification settings - Fork 402
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
Updates to apiserver swagger ui #1387
Conversation
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.
Have one immediate change. Will run through the instructions later today to confirm they work
apiserver/DEVELOPMENT.md
Outdated
* [local service -- http://localhost:8888/swagger-ui/](http://localhost:8888/swagger-ui/) | ||
* [kind cluster -- http://localhost:31888/swagger-ui/](http://localhost:31888/swagger-ui/) | ||
|
||
Please note that for the local service to properly serve the swagger content the location of the swagger files would need to be changed in [code](https://github.com/ray-project/kuberay/blob/f1067378bc99987f3eba1e5b12b4cc797465336d/apiserver/cmd/main.go#L138-L142) as follows (lines 138-142 of [main.go](cmd/main.go)): |
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.
@z103cb For running local apiserver, should we have something like this in main.go so we can do KUBERAY_APISERVER_SWAGGER=local make run
if os.Getenv("KUBERAY_APISERVER_SWAGGER") == "local" {
p = path.Join("../proto/swagger/", p)
} else {
p = path.Join("/workspace/proto/swagger/", p)
}
Then we would not need to manually change the file for local service.
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 was thinking about this issue, and I wasn't sure if I should include a fix in this PR. But since you've asked, you have convinced me that we should probably do it. I will push a commit along the lines you have suggested
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.
Take a look at the latest commit (b88d4bd)
@z103cb would you mind rebasing with the master branch? Thanks! |
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.
LGTM. I verified the following:
- Ran
make run
and opened http://localhost:8888/swagger-ui/ in browser. - Run
make docker-image operator-image cluster load-image load-operator-image deploy deploy-operator
and opened http://localhost:31888/swagger-ui/ in browser.- some hiccup. The
deploy
anddeplpoy-operator
would not work unless I--set image.repository=localhost/kuberay/apiserver
and--set image.repository=localhost/kuberay/operator
explicitly for the helm commands in the makefile. I will track in this issue.
- some hiccup. The
- Called a few APIs using swagger-ui and had no error
- Create ComputeTemplate http://localhost:31888/swagger-ui/?urls.primaryName=ComputeTemplate%20Service#/ImageTemplateService/ImageTemplateService_CreateImageTemplate
- Create a RayCluster
- Create a RayJob
- Create ComputeTemplate http://localhost:31888/swagger-ui/?urls.primaryName=ComputeTemplate%20Service#/ImageTemplateService/ImageTemplateService_CreateImageTemplate
Consider the case of sidecar containers
…#1395) [CI] Remove RayService tests from comopatibility-test.py
…b container (ray-project#1375) Enable job log streaming by setting `PYTHONUNBUFFERED` in job container
Update Volcano integration doc
Update Autoscaler YAML for the Autoscaler tutorial
…er container (ray-project#1401) Use image of Ray head container as the default Ray Autoscaler container
[services] Add text ml rayservice yaml
…#1403) [serve] Change text ml yaml to use french in user config
…project#1398) fix: Issue ray-project#1391 - Custom labels not being pulled in
…1369) implemented liveness/readyness probe for the API server
Bumps [golang.org/x/sys](https://github.com/golang/sys) from 0.0.0-20211210111614-af8b64212486 to 0.1.0. - [Commits](https://github.com/golang/sys/commits/v0.1.0) --- updated-dependencies: - dependency-name: golang.org/x/sys dependency-type: indirect ... Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Update GCS fault tolerance YAML
Bumps [github.com/emicklei/go-restful](https://github.com/emicklei/go-restful) from 2.9.5+incompatible to 2.16.0+incompatible. - [Release notes](https://github.com/emicklei/go-restful/releases) - [Changelog](https://github.com/emicklei/go-restful/blob/v3/CHANGES.md) - [Commits](emicklei/go-restful@v2.9.5...v2.16.0) --- updated-dependencies: - dependency-name: github.com/emicklei/go-restful dependency-type: indirect ... Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Bumps [golang.org/x/net](https://github.com/golang/net) from 0.0.0-20210813160813-60bc85c4be6d to 0.7.0. - [Commits](https://github.com/golang/net/commits/v0.7.0) --- updated-dependencies: - dependency-name: golang.org/x/net dependency-type: indirect ... Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Bumps [golang.org/x/sys](https://github.com/golang/sys) from 0.0.0-20210510120138-977fb7262007 to 0.1.0. - [Commits](https://github.com/golang/sys/commits/v0.1.0) --- updated-dependencies: - dependency-name: golang.org/x/sys dependency-type: indirect ... Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
…ay-project#1407) Bumps [go.mongodb.org/mongo-driver](https://github.com/mongodb/mongo-go-driver) from 1.3.4 to 1.5.1. - [Release notes](https://github.com/mongodb/mongo-go-driver/releases) - [Commits](mongodb/mongo-go-driver@v1.3.4...v1.5.1) --- updated-dependencies: - dependency-name: go.mongodb.org/mongo-driver dependency-type: indirect ... Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Bumps [golang.org/x/text](https://github.com/golang/text) from 0.3.5 to 0.3.8. - [Release notes](https://github.com/golang/text/releases) - [Commits](golang/text@v0.3.5...v0.3.8) --- updated-dependencies: - dependency-name: golang.org/x/text dependency-type: indirect ... Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Bumps [golang.org/x/net](https://github.com/golang/net) from 0.0.0-20210405180319-a5a99cb37ef4 to 0.7.0. - [Commits](https://github.com/golang/net/commits/v0.7.0) --- updated-dependencies: - dependency-name: golang.org/x/net dependency-type: indirect ... Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Signed-off-by: Laurentiu Bradin <[email protected]>
Consider the case of sidecar containers
…#1395) [CI] Remove RayService tests from comopatibility-test.py
[services] Add text ml rayservice yaml
The git history got way too crazy. Closing this PR in favour of: #1410 |
Why are these changes needed?
The swagger ui presented by the api-server was the stock pet store version, this PR rectifies this situation and displays the swagger for KubeRay API Server.
Related issue number
Closes #1343
Checks