Skip to content

ci: Add workflow to run a FOSSA scan#451

Merged
qmonnet merged 1 commit intomainfrom
pr/qmonnet/fossa-action
May 12, 2025
Merged

ci: Add workflow to run a FOSSA scan#451
qmonnet merged 1 commit intomainfrom
pr/qmonnet/fossa-action

Conversation

@qmonnet
Copy link
Member

@qmonnet qmonnet commented May 9, 2025

Apparently the "Quick Import" feature from FOSSA is not good enough for Rust projects, and we need to run the FOSSA CLI tool, either ourselves or using the official GitHub Action. This commit introduces a new workflow that uses this Action to perform a scan on Pull Requests and on pushes to the main branch.

@qmonnet qmonnet requested a review from mvachhar May 9, 2025 22:06
@qmonnet qmonnet added the ci Continuous Integration label May 9, 2025
@qmonnet qmonnet force-pushed the pr/qmonnet/fossa-action branch from 5fcc100 to e8d48ec Compare May 9, 2025 22:13
@qmonnet qmonnet requested a review from Frostman May 9, 2025 22:16
@qmonnet
Copy link
Member Author

qmonnet commented May 9, 2025

We need to figure out:

  • Is there any useful info that we can leverage here from the report? The report is generated and published at the URL provided in the logs (although it's private and one needs to be logged in as a member of the team on FOSSA - we should probably make this project public, by the way).

  • Does the Action fail loudly when we break things? When do we break things, exactly?

  • I own the API token in use which means all reports are marked as sent by me, which probably doesn't matter. I haven't found another way to create an authentication for the CI.

@qmonnet
Copy link
Member Author

qmonnet commented May 9, 2025

Related: #332

@qmonnet
Copy link
Member Author

qmonnet commented May 9, 2025

Right now the scan is “failing”: FOSSA Status

But the Action and workflow returns successfully 🙃, go figure. I haven't found a way to 1) fix the report and 2) make the workflow fail when the scan fails

@qmonnet
Copy link
Member Author

qmonnet commented May 9, 2025

The branch for scans on PRs is also marked as “master” in the interface, not sure why. Maybe that's the branch name created by the checkout action? Anyway, this means we probably don't have an easy way to identify which PR a given report comes from, in the FOSSA web interface.

@daniel-noland
Copy link
Collaborator

we should probably make this project public, by the way

??? dataplane is already public?

@qmonnet
Copy link
Member Author

qmonnet commented May 10, 2025

??? dataplane is already public?

Sorry I meant, in the FOSSA interface. If you click on the badge above, I'd expect you to get a 404.

@Frostman
Copy link
Member

Screenshot 2025-05-10 at 4 27 22 PM

I've made it public

Screenshot 2025-05-10 at 4 27 58 PM Screenshot 2025-05-10 at 4 28 08 PM Screenshot 2025-05-10 at 4 28 24 PM

@qmonnet
Copy link
Member Author

qmonnet commented May 12, 2025

I think the issue in routing is a bug in FOSSA's tool. The file is not ours, looking at the author's name I think it considered https://crates.io/crates/routing instead of our own crate. Not sure of the best way to fix this: we could ignore this dependency, but I suppose would cause the tool to ignore any issue in our routing crate, which is also not what we want. We can also rename our own crate, but just for the sake of making the FOSSA CLI happy that sounds a bit silly.

As for the other two in dpdk-sys - they're interesting, are we allowed to ship these GPL/LGPL files even if they're only header definitions? I wouldn't bet on it. What alternative do we have? Recreating our own definition file?

Apparently the "Quick Import" feature from FOSSA is not good enough for
Rust projects, and we need to run the FOSSA CLI tool, either ourselves
or using the official GitHub Action. This commit introduces a new
workflow that uses this Action to perform a scan on pushes to the main
branch.

Signed-off-by: Quentin Monnet <qmo@qmon.net>
@qmonnet qmonnet force-pushed the pr/qmonnet/fossa-action branch from e8d48ec to 70b51a3 Compare May 12, 2025 15:37
@qmonnet qmonnet marked this pull request as ready for review May 12, 2025 15:38
@qmonnet qmonnet requested a review from a team as a code owner May 12, 2025 15:38
@qmonnet qmonnet requested review from daniel-noland and removed request for a team May 12, 2025 15:38
@qmonnet
Copy link
Member Author

qmonnet commented May 12, 2025

Just updated the workflow to run on pushes to main only, given that it doesn't bring anything useful in the case of PRs.

@qmonnet qmonnet added this pull request to the merge queue May 12, 2025
Merged via the queue into main with commit 9c603ce May 12, 2025
15 checks passed
@qmonnet qmonnet deleted the pr/qmonnet/fossa-action branch May 12, 2025 16:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ci Continuous Integration

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants