-
Notifications
You must be signed in to change notification settings - Fork 172
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
Support context path from index file when pushing #14
Conversation
@shizhMSFT this is great! Thanks Do you mind if we nest this under apiVersion: v1
serverInfo:
contextPath: /some/path
entries: {}
generated: "2018-08-08T08:00:00Z" |
if err != nil { | ||
return nil, err | ||
} | ||
if resp.StatusCode != 200 { |
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.
This can be before reading body
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.
Let's follow the original design. The function call to getChartmuseumError(b, resp.StatusCode)
requires reading the response body.
@@ -0,0 +1,48 @@ | |||
package helm |
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.
this is the dep package so you should not change it?
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.
This is pkg
not vendor
. Therefore, it is not a dep package.
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.
ah...ok :)
@jdolitsky Nested |
LGTM. @jdolitsky can you help to review? Thanks! |
Works great! merging |
New version of plugin has been released with this feature (v0.7.0) |
When pushing charts to the remote server, the plugin automatically sets the context path from the cached repo index file. If pushing to a URL not a repo or the cache does not exist, the plugin tries to get the index file directly from the server.
Here is an example server generated index file with context path located at
http://example.com/some/path/index.yaml
with repo urlhttp://example.com/some/path
.With this index file, the plugin will send requests to
http://example.com/some/path/api/charts
for pushing charts instead ofhttp://example.com/api/some/path/charts
.