Setup an independent build for x-pack/winlogbeat#11679
Setup an independent build for x-pack/winlogbeat#11679andrewkroh merged 3 commits intoelastic:masterfrom
Conversation
ruflin
left a comment
There was a problem hiding this comment.
Skimmed through it and so far looks good to me. But I think me or someone else should go through it again in more detail.
If I understand this correctly quite a few of the changes are actual cleanups of the existing code and not directly related to the x-pack/winlogbeat? I wonder if we should split it up in more PR's? ;-)
eca9fca to
8990542
Compare
This is the split up version of the massive #9842. 😅 |
|
I'm pretty sure I asked there the same question 🤦♂️ |
eba6935 to
0002d0e
Compare
ruflin
left a comment
There was a problem hiding this comment.
LGTM, great job.
Would be great to have a deep dive session for beats contributors on all the mage magic at one time in the future ;-)
winlogbeat/magefile.go
Outdated
There was a problem hiding this comment.
mage:import is great and will simplify things a lot.
winlogbeat/scripts/mage/config.go
Outdated
There was a problem hiding this comment.
This feels quite a bit hidden in scripts package but not something to address for this PR, more a general comment.
winlogbeat/scripts/mage/update.go
Outdated
There was a problem hiding this comment.
Nit: Had to search for the definition of this. Would probably be nicer to have a more descriptive name or defined directly in here.
Put the infrastructure in place to give x-pack/winlogbeat its own independent build.
This adds some utility code that can be used by other beats to reduce duplication.
cd winlogbeat && mage -l
Targets:
goTestUnit is an alias for goUnitTest.
update is an alias for update:all.
check formats code, updates generated content, check for common errors, and checks for any modified files.
clean cleans all generated files and build artifacts.
dumpVariables writes the template variables and values to stdout.
fmt formats source code (.go and .py) and adds license headers.
build builds the Beat binary.
buildGoDaemon builds the go-daemon binary (use crossBuildGoDaemon).
crossBuild cross-builds the beat for all target platforms.
crossBuildGoDaemon cross-builds the go-daemon binary using Docker.
golangCrossBuild build the Beat binary inside of the golang-builder.
packageTest tests the generated packages in build/distributions.
dashboards:export exports a dashboard from Kibana and writes it into the correct directory.
dashboards:import imports dashboards to Kibana using the Beat setup command.
docs generates the documentation for the Beat.
test runs all available tests (unitTest + integTest).
goUnitTest executes the Go unit tests.
pythonUnitTest executes the python system tests.
unitTest executes the unit tests (Go and Python).
update:all updates all generated content.
update:config updates the Beat's config files.
update:dashboards collects all the dashboards and generates index patterns.
update:fieldDocs updates the field documentation.
update:fields updates all fields files (.go, .yml).
package packages the Beat for distribution.
0002d0e to
d650124
Compare
Put the infrastructure in place to give x-pack/winlogbeat its own independent build.
This adds some utility code that can be used by other beats to reduce duplication.