Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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
Add Makefile #221
Add Makefile #221
Changes from all commits
9d62278
1900a36
1bf100a
9ad4cbc
File filter
Filter by extension
Conversations
Jump to
There are no files selected for viewing
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.
Why changing this to
644
? We use640
literally everywhere.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.
I expect the permissions to still be taken care of by the packaging as the owner has to be set there anyways (and probably isn't even known until installation time due do dynamically allocated user/group IDs). I wouldn't have given
-m
at all (like I did for theinstall -d
above), but that would result in the file being executable.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.
Isn't this Makefile supposed to simplify the Debian rules file? If this file doesn't take care of permissions handling, as we already do in
override_dh_auto_install
, I don't see how this is supposed to make things simpler, other than to de-duplicate thego build ..
parts, for which by the way you don't use the same build flags as we do for the package builds.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.
It takes care of which files to build an where to install them.
So it should be possible to remove the
override_dh_auto_build
andoverride_dh_auto_install
targets fromdebian/rules
(those should callmake
/make install
automatically) and then simply set the permissions inoverride_dh_fixperms
(I'm not sure ifdebian/icinga-notifications
is the correct prefix for the path there):override_dh_fixperms: dh_fixperms chmod -R o= debian/icinga-notifications/etc/icinga-notifications
These can be set using an environment variable:
GOFLAGS='-buildvcs=false -trimpath'
We could consider always adding
-trimpath
, but I wouldn't add-buildvcs=false
to the Docker image builds as these are built from a Git checkout and thus receive the proper information that way.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.
The name
channel
does not make sense to me here, we will not have only one channel there, so I have already adapted this tochannels
in the Debian rules.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.
That has already come up in #210 (comment) as well. Simply using a different path here would introduce an inconsistency with the default path used in the binary:
icinga-notifications/internal/daemon/config.go
Line 16 in bd9633f
So if that's supposed to be changed, that's something for its own PR. I don't care too much if it's singular or plural, I wouldn't say any is more or less correct than the other.