File tree Expand file tree Collapse file tree 3 files changed +9
-3
lines changed
Expand file tree Collapse file tree 3 files changed +9
-3
lines changed Original file line number Diff line number Diff line change @@ -502,7 +502,10 @@ function bom_pass {
502502 run cp go.sum go.sum.tmp || return 2
503503 run cp go.mod go.mod.tmp || return 2
504504
505- output=$( GOFLAGS=-mod=mod run_go_tool github.com/appscodelabs/license-bill-of-materials \
505+ # BOM file should be generated for linux. Otherwise running this command on other operating systems such as OSX
506+ # results in certain dependencies being excluded from the BOM file, such as procfs.
507+ # For more info, https://github.com/etcd-io/etcd/issues/19665
508+ output=$( GOOS=linux GOFLAGS=-mod=mod run_go_tool github.com/appscodelabs/license-bill-of-materials \
506509 --override-file ./bill-of-materials.override.json \
507510 " ${modules[@]} " )
508511 code=" $? "
Original file line number Diff line number Diff line change @@ -320,7 +320,7 @@ function tool_pkg_dir {
320320# tool_get_bin [tool]
321321function run_go_tool {
322322 local cmdbin
323- if ! cmdbin=$( GOARCH=" " tool_get_bin " ${1} " ) ; then
323+ if ! cmdbin=$( GOARCH=" " GOOS= " " tool_get_bin " ${1} " ) ; then
324324 log_warning " Failed to install tool '${1} '"
325325 return 2
326326 fi
Original file line number Diff line number Diff line change @@ -14,7 +14,10 @@ function bom_fixlet {
1414 # shellcheck disable=SC2207
1515 modules=($( modules_for_bom) )
1616
17- if GOFLAGS=-mod=mod run_go_tool " github.com/appscodelabs/license-bill-of-materials" \
17+ # BOM file should be generated for linux. Otherwise running this command on other operating systems such as OSX
18+ # results in certain dependencies being excluded from the BOM file, such as procfs.
19+ # For more info, https://github.com/etcd-io/etcd/issues/19665
20+ if GOOS=linux GOFLAGS=-mod=mod run_go_tool " github.com/appscodelabs/license-bill-of-materials" \
1821 --override-file ./bill-of-materials.override.json \
1922 " ${modules[@]} " > ./bill-of-materials.json.tmp; then
2023 cp ./bill-of-materials.json.tmp ./bill-of-materials.json
You can’t perform that action at this time.
0 commit comments