Skip to content

Commit d2d67b4

Browse files
committed
Link out to SBOM formats
Link to format definitions and use the term SBOM as opposed to BOM Signed-off-by: Aidan Delaney <[email protected]>
1 parent 4a24d5e commit d2d67b4

File tree

2 files changed

+9
-9
lines changed

2 files changed

+9
-9
lines changed

content/docs/buildpack-author-guide/create-buildpack/adding-bill-of-materials.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ Processes:
3838

3939
Apart from the above standard metadata, buildpacks can also populate information about the dependencies they have provided in form of a `Bill-of-Materials`. Let's see how we can use this to populate information about the version of `ruby` that was installed in the output app image.
4040

41-
To add the `ruby` version to the output of `pack download sbom`, we will have to provide a `Bill-of-Materials` (`BOM`) containing this information. There are three "standard" ways to report SBOM data. You'll need to choose to use on of CycloneDX, SPDX or Syft update the `ruby.sbom.<ext>` (where `<ext>` is the extension appropriate for your BOM standard, one of `cdx.json`, `spdx.json` or `syft.json`) at the end of your `build` script. Discussion of which BOM format to choose is outside the scope of this tutorial, but we will note that the SBOM format you choose to use is likely to be the output format of any BOM scanner (eg: [`syft cli`](https://github.com/anchore/syft)) you might choose to use. In this example we will use the CycloneDX json format.
41+
To add the `ruby` version to the output of `pack download sbom`, we will have to provide a [Software `Bill-of-Materials`](https://en.wikipedia.org/wiki/Software_bill_of_materials) (`SBOM`) containing this information. There are three "standard" ways to report SBOM data. You'll need to choose to use on of [CycloneDX](https://cyclonedx.org/), [SPDX](https://spdx.dev/) or [Syft](https://github.com/anchore/syft) update the `ruby.sbom.<ext>` (where `<ext>` is the extension appropriate for your SBOM standard, one of `cdx.json`, `spdx.json` or `syft.json`) at the end of your `build` script. Discussion of which SBOM format to choose is outside the scope of this tutorial, but we will note that the SBOM format you choose to use is likely to be the output format of any SBOM scanner (eg: [`syft cli`](https://github.com/anchore/syft)) you might choose to use. In this example we will use the CycloneDX json format.
4242

4343
First, annotate the `buildpack.toml` to specify that it emits CycloneDX:
4444

@@ -58,7 +58,7 @@ api = "0.7"
5858
id = "io.buildpacks.samples.stacks.bionic"
5959
```
6060

61-
Then, in our buildpack implemetnation we will generate the necessary BOM metadata:
61+
Then, in our buildpack implemetnation we will generate the necessary SBOM metadata:
6262

6363
```bash
6464
# ...
@@ -80,7 +80,7 @@ cat >> "$layersdir/ruby.sbom.cdx.json" << EOL
8080
EOL
8181
```
8282

83-
We can also add an BOM entry for each dependency listed in `Gemfile.lock`. Here we use `jq` to add a new record to the `components` array in `bundler.sbom.cdx.json`:
83+
We can also add an SBOM entry for each dependency listed in `Gemfile.lock`. Here we use `jq` to add a new record to the `components` array in `bundler.sbom.cdx.json`:
8484

8585
```bash
8686
crubybom="${layersdir}/ruby.sbom.cdx.json"
@@ -187,7 +187,7 @@ command = "bundle exec ruby worker.rb"
187187
EOL
188188
189189
# ========== ADDED ===========
190-
# 9. ADD A BOM
190+
# 9. ADD A SBOM
191191
rubybom="${layersdir}/ruby.sbom.cdx.json"
192192
cat >> ${rubybom} << EOL
193193
{

katacoda/scenarios/buildpack-author-guide/adding-bill-of-materials.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ Processes:
3434

3535
Apart from the above standard metadata, buildpacks can also populate information about the dependencies they have provided in form of a `Bill-of-Materials`. Let's see how we can use this to populate information about the version of `ruby` that was installed in the output app image.
3636

37-
To add the `ruby` version to the output of `pack download sbom`, we will have to provide a `Bill-of-Materials` (`BOM`) containing this information. There are three "standard" ways to report SBOM data. You'll need to choose to use on of CycloneDX, SPDX or Syft update the `ruby.sbom.<ext>` (where `<ext>` is the extension appropriate for your BOM standard, one of `cdx.json`, `spdx.json` or `syft.json`) at the end of your `build` script. Discussion of which BOM format to choose is outside the scope of this tutorial, but we will note that the SBOM format you choose to use is likely to be the output format of any BOM scanner (eg: [`syft cli`](https://github.com/anchore/syft)) you might choose to use. In this example we will use the CycloneDX json format.
37+
To add the `ruby` version to the output of `pack download sbom`, we will have to provide a [Software `Bill-of-Materials`](https://en.wikipedia.org/wiki/Software_bill_of_materials) (`SBOM`) containing this information. There are three "standard" ways to report SBOM data. You'll need to choose to use on of [CycloneDX](https://cyclonedx.org/), [SPDX](https://spdx.dev/) or [Syft](https://github.com/anchore/syft) update the `ruby.sbom.<ext>` (where `<ext>` is the extension appropriate for your SBOM standard, one of `cdx.json`, `spdx.json` or `syft.json`) at the end of your `build` script. Discussion of which SBOM format to choose is outside the scope of this tutorial, but we will note that the SBOM format you choose to use is likely to be the output format of any SBOM scanner (eg: [`syft cli`](https://github.com/anchore/syft)) you might choose to use. In this example we will use the CycloneDX json format.
3838

3939
First, annotate the `buildpack.toml` to specify that it emits CycloneDX:
4040

@@ -54,7 +54,7 @@ api = "0.7"
5454
id = "io.buildpacks.samples.stacks.bionic"
5555
</pre>
5656

57-
Then, in our buildpack implemetnation we will generate the necessary BOM metadata:
57+
Then, in our buildpack implemetnation we will generate the necessary SBOM metadata:
5858

5959
```bash
6060
# ...
@@ -76,7 +76,7 @@ cat >> "$layersdir/ruby.sbom.cdx.json" << EOL
7676
EOL
7777
```
7878

79-
We can also add an BOM entry for each dependency listed in `Gemfile.lock`. Here we use `jq` to add a new record to the `components` array in `bundler.sbom.cdx.json`:
79+
We can also add an SBOM entry for each dependency listed in `Gemfile.lock`. Here we use `jq` to add a new record to the `components` array in `bundler.sbom.cdx.json`:
8080

8181
```bash
8282
crubybom="${layersdir}/ruby.sbom.cdx.json"
@@ -183,7 +183,7 @@ command = "bundle exec ruby worker.rb"
183183
EOL
184184

185185
# ========== ADDED ===========
186-
# 9. ADD A BOM
186+
# 9. ADD A SBOM
187187
rubybom="${layersdir}/ruby.sbom.cdx.json"
188188
cat >> ${rubybom} << EOL
189189
{
@@ -239,7 +239,7 @@ You should find that the included `ruby` version is `2.5.0` as expected.
239239
```text
240240
{
241241
"bomFormat": "CycloneDX",
242-
"specVersion": "1.3",
242+
"specVersion": "1.4",
243243
"version": 1,
244244
"components": [
245245
{

0 commit comments

Comments
 (0)