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

when building the broker for image always build for linux OS. #525

Merged
merged 1 commit into from
Oct 31, 2017

Conversation

shawn-hurley
Copy link
Contributor

Describe what this PR does and why we need it:
Always build the broker binary for OS of Linux and output to the build directory

Which issue this PR fixes (This will close that issue when PR gets merged)
fixes #521

@openshift-ci-robot openshift-ci-robot added the size/XS Denotes a PR that changes 0-9 lines, ignoring generated files. label Oct 31, 2017
build-image: broker ## Build a docker image with the broker binary
cp broker build/broker
build-image: ## Build a docker image with the broker binary
env GOOS=linux go build -i -ldflags="-s -s" -o ${BUILD_DIR}/broker ./cmd/broker
Copy link
Contributor

Choose a reason for hiding this comment

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

The only downside to this is that it will build everytime, where the previous version only did it if the broker was out of date. One could argue though you wouldn't be calling build-image if you didn't cause a change

Copy link
Contributor

@jmrodri jmrodri left a comment

Choose a reason for hiding this comment

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

ACK, was trying to see if there was a clever way of calling the broker build target with the necessary parameters but that hurt my brain. This is works well enough.

@jmrodri jmrodri added the build label Oct 31, 2017
@jmrodri jmrodri merged commit fbd808b into openshift:master Oct 31, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
build size/XS Denotes a PR that changes 0-9 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

ASBD fails to run in image when created on a Mac
4 participants