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

ci: build & test otelcol-config #1656

Merged
merged 7 commits into from
Aug 16, 2024
Merged

Conversation

amdprophet
Copy link
Contributor

Adds build & test CI jobs for the new otelcol-config command. Refactors the toolchain code used for building FIPS images to allow the Docker container to build other binaries.

Comment on lines 139 to 144
# TODO: find a way to test if the binary runs
# - name: Test binary
# if: inputs.arch_os == env.ARCH_OS
# working-directory: ./pkg/tools/otelcol-config
# run: |
# ./${{ steps.set-binary-name.outputs.binary_name }} -t foo
Copy link
Collaborator

Choose a reason for hiding this comment

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

There's already a smoke test in otelcol-config itself, so this is probably not needed

Copy link
Contributor Author

Choose a reason for hiding this comment

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

This was copied from the otelcol-sumo build job. It's meant to ensure that the binary runs after running make. We ran into an issue where the binaries were actually text files in the past.

It may be better to check the file type for every platform instead. We'd need to check for the correct file type for the platform though (e.g. Mach-O 64-bit executable arm64 versus ELF 64-bit LSB executable, ARM aarch64, version 1 (SYSV), statically linked, Go BuildID=vataBbMZrfQgeqsJPb3y/CT0CNbBkuU-ZpeiBCFvZ/rX1IRAQtPBnQNJWqqDt9/SENzp0KECm910ny3Zm29, stripped)

Copy link
Collaborator

Choose a reason for hiding this comment

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

That seems kind of nitty to me. How did it regress to a text file?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I'm not positive but I believe it was a problem with binaries moving between jobs through the CI cache system which isn't happening the same way here. We can leave this out.

@amdprophet amdprophet marked this pull request as ready for review August 15, 2024 23:36
@amdprophet amdprophet requested a review from a team as a code owner August 15, 2024 23:36
@amdprophet
Copy link
Contributor Author

@echlebek ready for review!

Copy link
Collaborator

@echlebek echlebek left a comment

Choose a reason for hiding this comment

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

Looking forward to packaging, inshallah 🙏

@amdprophet amdprophet merged commit c1d4756 into main Aug 16, 2024
73 checks passed
@amdprophet amdprophet deleted the dev-build/ci-otelcol-config branch August 16, 2024 23:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants