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

Update gadgets metadata and keep them in sync #2642

Merged
merged 3 commits into from
Mar 25, 2024
Merged

Conversation

alban
Copy link
Member

@alban alban commented Mar 25, 2024

Update gadgets metadata and keep them in sync

This PR updates the gadgets metadata (gadget.yaml) and adds a CI check that it stays in sync.

How to use

A gadget metadata can be updated manually with:

GADGET_BUILD_PARAMS="--update-metadata" make -C gadgets/ trace_dns

Testing done

The CI.

This allows to run 'make' with custom build parameters, such as
--update-metadata.

Signed-off-by: Alban Crequy <albancrequy@linux.microsoft.com>
Signed-off-by: Alban Crequy <albancrequy@linux.microsoft.com>
Signed-off-by: Alban Crequy <albancrequy@linux.microsoft.com>
@alban alban merged commit ef25d34 into main Mar 25, 2024
60 checks passed
@alban alban deleted the alban_metadata_update branch March 25, 2024 14:00
Comment on lines +372 to +383
build-official-image-based-gadgets:
name: Build gadgets
# level: 1
needs: build-ig
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Check if metadata files are updated
run: |
GADGET_BUILD_PARAMS="--update-metadata" make build-gadgets
git diff --exit-code HEAD --

Choose a reason for hiding this comment

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

What about this approach to avoid building the gadgets twice?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants