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

Specify linux fpm platform so packages are always created properly #94

Merged
merged 1 commit into from Nov 8, 2016

Conversation

Projects
None yet
3 participants
@jessecarbon
Contributor

jessecarbon commented Nov 4, 2016

I noticed this when building on OSX. Without these additional configs, RPM/DEBs were built for darwin, resulting in package collector-sidecar-0.0.9_cb1-1.x86_64 is intended for a darwin operating system when installing the resulting RPM on Linux.

This change results in fpm-cook passing --rpm-os linux to fpm, see https://github.com/jordansissel/fpm/wiki:

    --rpm-os OS                   (rpm only) The operating system to target this rpm for. You want to set this to 'linux' if you are using fpm on OS X, for example

Which results in "--target","x86_64-unknown-linux" being passed to rpmbuild, as well as the additional logging:

===> [FPM] Building target platforms: x86_64-unknown-linux {}

The ability to pass fpm attributes in fpm-cookery was added here.

Seems like explicitly specifying this doesn't hurt anything and is necessary for building on OSX (at least it was for me).

Specify linux fpm platform so packages are always created properly (#4)
Without this, RPM/DEBs are built for darwin when building on MacOS/OSX,
resulting in "package collector-sidecar-0.0.9_cb1-1.x86_64 is intended
for a darwin operating system" when installing.
@mariussturm

This comment has been minimized.

Member

mariussturm commented Nov 8, 2016

I never tried to build Linux packages on OSX but good catch! Thanks!

@mariussturm mariussturm merged commit 5e57716 into Graylog2:master Nov 8, 2016

2 checks passed

continuous-integration/travis-ci/pr The Travis CI build passed
Details
licence/cla Contributor License Agreement is signed.
Details
@bernd

This comment has been minimized.

Member

bernd commented Nov 8, 2016

I never tried to build Linux packages on OSX but good catch! Thanks!

Yeah, this is not really supported with fpm-cookery. 😉

@jessecarbon

This comment has been minimized.

Contributor

jessecarbon commented Nov 8, 2016

Yeah, this is not really supported with fpm-cookery. 😉

Seems to work fine!

jessecarbon added a commit to jessecarbon/collector-sidecar that referenced this pull request Dec 2, 2016

Specify linux fpm platform so packages are always created properly (#4)…
… (Graylog2#94)

Without this, RPM/DEBs are built for darwin when building on MacOS/OSX,
resulting in "package collector-sidecar-0.0.9_cb1-1.x86_64 is intended
for a darwin operating system" when installing.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment