Skip to content

Conversation

@yifan-gu
Copy link
Contributor

  • Replace 'KeyPairName' with 'SSHKey'.
  • Fix golint.
  • Use better UUID() implementation from upstream.

@openshift-ci-robot openshift-ci-robot added size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. approved Indicates a PR has been approved by an approver from all required OWNERS files. labels Aug 27, 2018
Copy link
Contributor

Choose a reason for hiding this comment

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

We can drop SSHKey, #127

Copy link
Contributor

Choose a reason for hiding this comment

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

the sshkey has moved to admin section.

@yifan-gu
Copy link
Contributor Author

@wking Yeah, I was feeling like I missed something, that's it!

Copy link
Member

Choose a reason for hiding this comment

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

Previous discussion starting here. I'd still prefer to stick to pborman/uuid and just use the random (version 4) UUID via []byte(uuid.New()).

Copy link
Member

Choose a reason for hiding this comment

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

nit: you're missing a trailing period here.

And maybe add a note about these being the main settings we expect users to edit?

Copy link
Member

Choose a reason for hiding this comment

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

nit: My aspell dictionary and wiktionary have "instantiated" but not "instanciated".

pkg/types/doc.go Outdated
Copy link
Member

Choose a reason for hiding this comment

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

nit: Are other types going to go in here too? If it's just InstallConfig, maybe we should move that type definition into pkg/asset/installconfig.

Copy link
Contributor Author

@yifan-gu yifan-gu Aug 27, 2018

Choose a reason for hiding this comment

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

I'm inclined to keep it here for now, as the pkg/asset is more for generating assets internally for the installer, but the InstallConfig is kinda exportable, and might be referenced by other projects like cluster-operator, etc. So I want to make it stay in a top level package for easier accessibility.

Copy link
Member

@wking wking Aug 27, 2018

Choose a reason for hiding this comment

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

...but the InstallConfig is kinda exportable...

So this package is intended just for that struct? Or do we expect other structs to end up here as well? If it's just this one struct, how about pkg/installconfig for the struct (leaving the asset logic deeper in pkg/asset/installconfig)?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Currently I am only seeing one, but I like to have pkg/types, still more intuitive to me, even if I don't know what installconfig is, I will probably look into this package and find out.

Copy link
Member

Choose a reason for hiding this comment

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

Currently I am only seeing one, but I like to have pkg/types...

So maybe the scope is:

// Package types defines structures for user-supplied installer configuration.

without it being InstallerConfig specific?

@openshift-ci-robot openshift-ci-robot added size/L Denotes a PR that changes 100-499 lines, ignoring generated files. and removed size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. labels Aug 27, 2018
Copy link
Member

Choose a reason for hiding this comment

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

Indent is wonky here. Maybe tabs vs. spaces?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

updated to spaces, seems like that's what other fields do.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

fixed other places too in the file.

@yifan-gu yifan-gu force-pushed the minor_state branch 2 times, most recently from 594fe6f to 6357eda Compare August 28, 2018 00:30
@openshift-ci-robot openshift-ci-robot added size/XL Denotes a PR that changes 500-999 lines, ignoring generated files. and removed size/L Denotes a PR that changes 100-499 lines, ignoring generated files. labels Aug 28, 2018
Copy link
Member

@wking wking left a comment

Choose a reason for hiding this comment

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

A few more minor nits. I'm fine with these getting fixed here, and also with 6357eda landing as it stands and punting the nits to follow-up work.

Copy link
Member

Choose a reason for hiding this comment

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

nit: pkg/types/installconfig.go is file-level detail, but folks reading this in godoc.org will only care about package-level detail. Maybe something like:

// Package installconfig generates the install config assets based on its dependencies.
// The type itself is defined in ../pkg/types.

Or end with the full import path "...defined in github.com/openshift/installer/pkg/types.".

Copy link
Member

Choose a reason for hiding this comment

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

nit: Maybe just end with "...that holds the instantiated assets."?

Copy link
Member

Choose a reason for hiding this comment

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

nit: Should this optional type be omitempty?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

why this is optional?

Copy link
Member

@wking wking Aug 28, 2018

Choose a reason for hiding this comment

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

why this is optional?

Maybe the user doesn't care about SSH access? But mostly because it's omitempty here, and I'd rather stay consistent ;).

Copy link
Contributor Author

Choose a reason for hiding this comment

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

ok, updated

As now we will just accept the SSHKey from the prompt instead of
a KeyPairName.
@wking
Copy link
Member

wking commented Aug 28, 2018

/lgtm

@openshift-ci-robot openshift-ci-robot added the lgtm Indicates that a PR is ready to be merged. label Aug 28, 2018
@openshift-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: wking, yifan-gu

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@openshift-merge-robot openshift-merge-robot merged commit 2587b3e into openshift:master Aug 28, 2018
@yifan-gu yifan-gu deleted the minor_state branch August 28, 2018 22:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

approved Indicates a PR has been approved by an approver from all required OWNERS files. lgtm Indicates that a PR is ready to be merged. size/XL Denotes a PR that changes 500-999 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants