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

Add DroneCI pipeline stage to validate loki example configs; create example configuration files #4358

Conversation

JordanRushing
Copy link
Contributor

@JordanRushing JordanRushing commented Sep 20, 2021

What this PR does / why we need it:
We want to provide some form of basic validation for example configurations that we provide to users to lower potential friction when experimenting with Loki.

This PR introduces:

  • New make targets validate-example-configs, generate-example-config-doc, check-example-config-doc
  • New DroneCI steps under check to validate example configs
  • docs/sources/configuration/examples.md is now dynamically generated based on the file contents of ./docs/sources/configuation/examples/*.yaml

Which issue(s) this PR fixes:
N/A

Special notes for your reviewer:
N/A

Checklist

  • Documentation added
  • Tests updated

@JordanRushing JordanRushing self-assigned this Sep 20, 2021
@JordanRushing JordanRushing force-pushed the jordanrushing/loki/validate-provided-example-configs branch from 333e7d3 to 833ae9d Compare September 20, 2021 21:24
Copy link
Member

@owen-d owen-d left a comment

Choose a reason for hiding this comment

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

This is looking good! I'd really like to see us template these configs themselves into the documentation to ensure they're continually up to date in the docs and that we're testing the correct configs.

Makefile Show resolved Hide resolved
@JordanRushing JordanRushing force-pushed the jordanrushing/loki/validate-provided-example-configs branch from cdab508 to ed2d53f Compare October 7, 2021 23:02
@pull-request-size pull-request-size bot added size/XL and removed size/L labels Oct 7, 2021
@JordanRushing JordanRushing force-pushed the jordanrushing/loki/validate-provided-example-configs branch from ed2d53f to 0338028 Compare October 7, 2021 23:06
@JordanRushing JordanRushing marked this pull request as ready for review October 7, 2021 23:11
Copy link
Contributor

@KMiller-Grafana KMiller-Grafana left a comment

Choose a reason for hiding this comment

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

I've made quite a few suggestions on the comments in the YAML files. The files are all missing newlines at the end. It is good to have them in YAML files.

docs/sources/configuration/examples/aws-basic-config.yaml Outdated Show resolved Hide resolved
JordanRushing and others added 2 commits October 8, 2021 16:18
Co-authored-by: Karen Miller <84039272+KMiller-Grafana@users.noreply.github.com>
@JordanRushing JordanRushing force-pushed the jordanrushing/loki/validate-provided-example-configs branch from d874f02 to f0954df Compare October 8, 2021 21:18
Copy link
Contributor

@KMiller-Grafana KMiller-Grafana left a comment

Choose a reason for hiding this comment

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

Thanks, @JordanRushing. LGTM.

@owen-d
Copy link
Member

owen-d commented Oct 8, 2021

We can work out the generation check in CI with more idiomatic make targets, but happy to do that in a followup PR. Nice work!

@owen-d owen-d merged commit 4c5b084 into grafana:main Oct 8, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants