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

Replace cookiecutter to generate beats by internal script #2996

Merged
merged 1 commit into from
Jan 13, 2017

Conversation

ruflin
Copy link
Member

@ruflin ruflin commented Nov 14, 2016

Currently cookiecutter is needed to generate a beat. This adds an additional dependency to generate a beat and does not give us a lot of control over which checks should be executed during execution. As our template is quite simple it can be done with basic string replacements. A simple python script is now done for the task which leads to less inputs needed by the user and allows us to do checks like GOPATH setup etc.

The script could potentially be done in Golang but the setup of python is needed anyways for development.

Further changes:

  • Rename .go files to .go.tmpl so they are not checked for correct syntax
  • Update documentation

NOTES:

  • Changes for the metricbeat generator will follow in a second PR.

@ruflin ruflin added the in progress Pull request is currently in progress. label Nov 14, 2016
@ruflin ruflin force-pushed the remove-cookiecutter branch from f19f92c to 23fcaaa Compare December 16, 2016 11:47
@ruflin ruflin added :Generator Related to code generators for building custom Beats or modules. libbeat review and removed in progress Pull request is currently in progress. labels Dec 16, 2016
@ruflin ruflin force-pushed the remove-cookiecutter branch from 23fcaaa to 2c780ad Compare January 5, 2017 12:39
@ruflin
Copy link
Member Author

ruflin commented Jan 9, 2017

Blog posts where updated to fetch changes from the 5.1 branch. This is now ready to move forward.

Currently cookiecutter is needed to generate a beat. This adds an additional dependency to generate a beat and does not give us a lot of control over which checks should be executed during execution. As our template is quite simple it can be done with basic string replacements. A simple python script is now done for the task which leads to less inputs needed by the user and allows us to do checks like GOPATH setup etc.

The script could potentially be done in Golang but the setup of python is needed anyways for development.

Further changes:

* Rename .go files to .go.tmpl so they are not checked for correct syntax
* Update documentation

NOTES:
* Changes for the metricbeat generator will follow in a second PR.
* Blog post about creating a beat should be updated to point to 5.1. See elastic#3197
@ruflin ruflin force-pushed the remove-cookiecutter branch from 2c780ad to 8a81e92 Compare January 9, 2017 12:52
@monicasarbu monicasarbu merged commit 15991e4 into elastic:master Jan 13, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
:Generator Related to code generators for building custom Beats or modules. libbeat review
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants