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

Operator Install from URL #489

Merged
merged 10 commits into from
Jul 7, 2019
Merged

Operator Install from URL #489

merged 10 commits into from
Jul 7, 2019

Conversation

kensipe
Copy link
Member

@kensipe kensipe commented Jul 2, 2019

What type of PR is this?
/component kudoctl
/kind enhancement

What this PR does / why we need it:
Adds the ability to install operator from a URL.

This enables install from:

  1. local folder
  2. local tgz
  3. url tgz
  4. repo

Which issue(s) this PR fixes:
Fixes #

Special notes for your reviewer:

Does this PR introduce a user-facing change?:

* Operators can be installed from URL to a valid operator package.

@kensipe
Copy link
Member Author

kensipe commented Jul 2, 2019

huh?

Sending build context to Docker daemon    788kB

Step 1/9 : FROM kudobuilder/golang:1.12
1.12: Pulling from kudobuilder/golang

error pulling image configuration: received unexpected HTTP status: 502 Bad Gateway
Error when building test docker image, cannot run tests.
Exited with code 1

@kensipe
Copy link
Member Author

kensipe commented Jul 3, 2019

looking for #479 to land before working on this more... it will collide

@jbarrick-mesosphere
Copy link
Member

jbarrick-mesosphere commented Jul 3, 2019

I was wondering if we could break this out into a separate interface where we treat each install target as a KUDO package repository.

For example, we can implement the interface for the local directory that treats it as a repository.

This would be useful for me in the test harness as I want to be able to easily install all operator versions from a repository, whether that repository is GCS or on disk or etc.

@kensipe kensipe added component/cli kubectl kudo a.k.a. kudoctl WIP labels Jul 3, 2019
@fabianbaier
Copy link
Member

I was wondering if we could break this out into a separate interface where we treat each install target as a KUDO package repository.

For example, we can implement the interface for the local directory that treats it as a repository.

This would be useful for me in the test harness as I want to be able to easily install all operator versions from a repository, whether that repository is GCS or on disk or etc.

This PR lgtm. While discussing it here we probably should use it as the foundation of multiple PRs that explore what has been discussed. In particular around ability to search for Operators ( see #332 ) or caching.

Copy link
Member

@fabianbaier fabianbaier left a comment

Choose a reason for hiding this comment

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

lgtm see also my latest comment

@kensipe kensipe added needs review and removed WIP labels Jul 4, 2019
// - a operator name in the remote repository
// in that order. Should there exist a local folder e.g. `cassandra` it will take precedence
// over the remote repository package with the same name.
func getPackageCRDs(name string, options *Options, repository repo.Repository) (*repo.PackageCRDs, error) {
func getPackageCRDs(name string, options *Options, repository repo.Repository) (*bundle.PackageCRDs, error) {
Copy link
Member

Choose a reason for hiding this comment

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

Could we make this public?

Copy link
Member Author

Choose a reason for hiding this comment

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

I've been reducing all things to be private until needed to be public.. is there are reason to make it public?

Copy link
Member

@jbarrick-mesosphere jbarrick-mesosphere left a comment

Choose a reason for hiding this comment

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

This is great, thanks!

Copy link
Contributor

@alenkacz alenkacz left a comment

Choose a reason for hiding this comment

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

Definitely missing some tests here, otherwise looks good :)

@kensipe
Copy link
Member Author

kensipe commented Jul 4, 2019

mostly taken the day off... but I will add some tests and hope to merge today or tomorrow. thanks team!
I would also like to see repo refactored a little... but lets get that on another PR to keep the size reasonable.

@kensipe
Copy link
Member Author

kensipe commented Jul 4, 2019

@fabianbaier I love the search options in #332 . If you are ok with it... I would like to grab that in another PR.

@kensipe kensipe merged commit 0785f61 into master Jul 7, 2019
@alenkacz alenkacz deleted the ken/operator-from-url branch October 30, 2019 09:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
component/cli kubectl kudo a.k.a. kudoctl needs review
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants