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

Full set of bom READMEs and documentation #2109

Merged
merged 4 commits into from
Jun 7, 2021

Conversation

puerco
Copy link
Member

@puerco puerco commented Jun 6, 2021

/kind documentation

What this PR does / why we need it:

This PR adds the documentation for the first version of the bom utility. Still missing is the YAML composition
documentation, but the PR has not yet merged.

Specifically, this commit does the following:

  • Adds bom to the main releng repo readme
  • Adds the bom command reference, in the same style we have for krel.
  • Adds an in-depth guide about how to generate your own bill of materials
  • README.md for the cmd/bom directory

Another commit adds bom to the compile-release-tools script so that end users can compile it.

Which issue(s) this PR fixes:

Part of: #1837

Special notes for your reviewer:

Does this PR introduce a user-facing change?

- Add documentation for the `bom` utility
- In-depth HOWTO guide to generating an SPDX Bill of Materials using our tools

@k8s-ci-robot k8s-ci-robot added release-note Denotes a PR that will be considered when it comes time to generate release notes. kind/documentation Categorizes issue or PR as related to documentation. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. needs-priority area/release-eng Issues or PRs related to the Release Engineering subproject labels Jun 6, 2021
@k8s-ci-robot k8s-ci-robot added sig/release Categorizes an issue or PR as relevant to SIG Release. approved Indicates a PR has been approved by an approver from all required OWNERS files. size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. labels Jun 6, 2021
@puerco puerco changed the title Bom docs Full set of bom READMEs and documentation Jun 6, 2021
@puerco puerco mentioned this pull request Jun 6, 2021
19 tasks
Copy link
Member

@saschagrunert saschagrunert left a comment

Choose a reason for hiding this comment

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

Great documentation, I added a few nits and clarifications. 👍

docs/bom/README.md Outdated Show resolved Hide resolved
docs/bom/README.md Outdated Show resolved Hide resolved
Bill of Materials project. It enables software authors to generate an
SBOM for their projects in a simple, yet powerful way.

[![asciicast](https://asciinema.org/a/418528.svg)](https://asciinema.org/a/418528)
Copy link
Member

Choose a reason for hiding this comment

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

Does it make sense to put the svg into this repository?

Copy link
Member Author

Choose a reason for hiding this comment

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

OK, I've found a way to rewrite the asciinema cast to an animated one. I've uploaded it

cmd/bom/README.md Outdated Show resolved Hide resolved
@@ -0,0 +1,76 @@
# bom (Bill of Materials)
Copy link
Member

Choose a reason for hiding this comment

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

For consistency, we should clarify how we want to spell the abbreviation, like:

  • bom when referring to the binary
  • BOM when referring to "Bill of Materials"

Copy link
Member Author

Choose a reason for hiding this comment

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

I've seen that as of late SBOM has been gaining more traction and BOM is getting left behind. I used SBOM to abbreviate a generic bill of materials. I will set all instances of bom in backticks to refer to the binary

docs/bom/create-a-bill-of-materials.md Outdated Show resolved Hide resolved
docs/bom/create-a-bill-of-materials.md Outdated Show resolved Hide resolved
docs/bom/create-a-bill-of-materials.md Outdated Show resolved Hide resolved

Packages are a non-specific element in SPDX representing anything that can
group other elements. An `.rpm` or `.deb` package can be an SPDX package, but
so can be a docker image or a tarball. Packages contain files, but can also
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
so can be a docker image or a tarball. Packages contain files, but can also
so can be a container image or a tarball. Packages contain files, but can also

I'll not highlight more of those since it will occur in multiple places in the following paragraphs. I assume it works with OCI images in the same way as Docker v2 manifests, right? Then we should always refer the OCI format aka the term "container image".

Copy link
Member Author

Choose a reason for hiding this comment

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

Absolutely right. I have to change that automatic behavior of always writing "docker image". I changed all of them in the dock.

docs/bom/create-a-bill-of-materials.md Outdated Show resolved Hide resolved
@puerco puerco force-pushed the bom-docs branch 3 times, most recently from 0c2bc36 to 1e7377a Compare June 7, 2021 14:49
Copy link
Contributor

@wilsonehusin wilsonehusin left a comment

Choose a reason for hiding this comment

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

here's my first pass, mostly nitpicky. well done on the overall write up!

cmd/bom/README.md Outdated Show resolved Hide resolved
cmd/bom/README.md Show resolved Hide resolved
cmd/bom/README.md Outdated Show resolved Hide resolved
packing the data along with licensing information.

bom is still in its early stages and it is an effort to open
the libraries developed for the Kubernetes SBOM for other
Copy link
Contributor

Choose a reason for hiding this comment

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

I made suggestions on BOM / SBOM references but generally I have mixed feelings on the usage of them. On one hand it increases search hits to use both, but on the other I think we should be consistent on which term to use. I'm leaning on saying SBOM for sake of consistency, since we already mention SBOM in the document for "What is Bill of Materials".

Copy link
Member Author

Choose a reason for hiding this comment

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

+1 I've noticed SBOM gaining more acceptance in discussions happening everywhere. Following up on @saschagrunert comment someplace else, I think we should settle on:
bom for the binary
SBOM to refer to a software bill of materials in general.

docs/bom/create-a-bill-of-materials.md Show resolved Hide resolved
docs/bom/generate.md Outdated Show resolved Hide resolved
This commit adds an in-depth howto with instructions
to generate a Bill of Materials.

Signed-off-by: Adolfo García Veytia (Puerco) <adolfo.garcia@uservers.net>
Signed-off-by: Adolfo García Veytia (Puerco) <adolfo.garcia@uservers.net>
This commit adds the bom utility readme. It features an asciinema
recording show how it is used.
This commit adds the raw documentation for bom and
its only subcommand: generate.

The format mimics previous docs for our tools (like krel).

Signed-off-by: Adolfo García Veytia (Puerco) <adolfo.garcia@uservers.net>
@puerco
Copy link
Member Author

puerco commented Jun 7, 2021

I think I've addressed all nits, PTAL @saschagrunert , @wilsonehusin

Copy link
Contributor

@wilsonehusin wilsonehusin left a comment

Choose a reason for hiding this comment

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

/lgtm

📦

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Jun 7, 2021
@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: puerco, wilsonehusin

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@k8s-ci-robot k8s-ci-robot merged commit e7e0f5c into kubernetes:master Jun 7, 2021
@k8s-ci-robot k8s-ci-robot added this to the v1.22 milestone Jun 7, 2021
@puerco puerco deleted the bom-docs branch June 7, 2021 18:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. area/release-eng Issues or PRs related to the Release Engineering subproject cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. kind/documentation Categorizes issue or PR as related to documentation. lgtm "Looks good to me", indicates that a PR is ready to be merged. needs-priority release-note Denotes a PR that will be considered when it comes time to generate release notes. sig/release Categorizes an issue or PR as relevant to SIG Release. size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants