-
Notifications
You must be signed in to change notification settings - Fork 772
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
move git and related functions from openshift.go into a separate file #651
Conversation
#655 will unblock this PR |
@surajnarwade Yes it will unblock this PR. |
Actually... there's a lot of things weird going on in this PR, weird indenting, changing of code to buildconfig. This all should just be a quick move and function name change, shouldn't it? |
|
||
// sort all object so all services are first | ||
o.SortServicesFirst(&allobjects) | ||
} |
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.
move weird changes
// sort all object so all services are first | ||
o.SortServicesFirst(&allobjects) | ||
// If docker-compose has a volumes_from directive it will be handled here | ||
o.VolumesFrom(&allobjects, komposeObject) |
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.
weird changes
} | ||
} else { | ||
svc := o.CreateHeadlessService(name, service, objects) | ||
objects = append(objects, svc) |
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.
again, changes to unrelated code
// If ports not provided in configuration we will not make service | ||
if o.PortsExist(name, service) { | ||
svc := o.CreateService(name, service, objects) | ||
objects = append(objects, svc) |
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.
weird indenting?
if err != nil { | ||
return nil, errors.Wrap(err, "Buildconfig cannot be created because current git branch couldn't be detected.") | ||
} | ||
} |
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.
weird indenting again, you indented all of this code.
@procrypt run gofmt |
@surajnarwade makes sense to put in different folder even though only OpenShift uses it.. we may use it for Kubernetes in the future? |
@surajnarwade we will be using it for Functional Tests also. |
LGTM |
Ping @kadel Please review. |
Should those functions be used in openshift code for buildconfig stuff etc...? |
@kadel , yeah buildconfig stuff |
@procrypt Mind fixing the conflicting file and then we can do another review / possible merge? |
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.
@surajnarwade the PR says that code is being moved, but I don't see code being removed from somewhere else, it's just code addition? can you please elaborate what is happening?
This LGTM. |
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.
Now this LGTM
Fixes #640 and we can use the same functions in #518
cc: @kadel @surajssd