@@ -1023,6 +1023,55 @@ jobs:
10231023 uses : actions/checkout@v6
10241024 with :
10251025 fetch-depth : 0
1026+
1027+ - name : Configure git for private Go modules
1028+ env :
1029+ GOPRIVATE : ${{ inputs.go-private-modules }}
1030+ run : git config --global url."https://${{ secrets.GH_TOKEN }}@github.com/".insteadOf "https://github.com/"
1031+
1032+ - name : Install build tools for Erlang
1033+ if : inputs.language == 'erlang'
1034+ run : |
1035+ sudo apt-get update
1036+ sudo apt-get install -y build-essential
1037+
1038+ - name : Set up Erlang/OTP and rebar3
1039+ if : inputs.language == 'erlang'
1040+ uses : erlef/setup-beam@v1
1041+ with :
1042+ otp-version : ' 25.3.2.16'
1043+ rebar3-version : ' 3.22.0'
1044+
1045+ - name : Set up Ruby
1046+ if : inputs.language == 'ruby'
1047+ uses : ruby/setup-ruby@v1
1048+ with :
1049+ ruby-version : ' 3.0'
1050+ bundler-cache : false
1051+
1052+ - name : Create bundle stub for Erlang SAST scan
1053+ if : inputs.language == 'erlang'
1054+ working-directory : ${{ github.workspace }}
1055+ run : |
1056+ # Polaris scans Erlang source code for SAST - Ruby gems not needed
1057+ # System ruby-dev from apt provides Ruby runtime (already installed)
1058+ # Create bundle stub to skip gem installation during Polaris scan
1059+ echo "Creating bundle stub to bypass Ruby gem installation"
1060+
1061+ # Create no-op bundle script
1062+ mkdir -p "$HOME/.polaris-stubs"
1063+ cat > "$HOME/.polaris-stubs/bundle" << 'EOF'
1064+ #!/bin/bash
1065+ # Stub: skips gem installation during SAST scan
1066+ echo "[STUB] Skipping bundle $@ - not needed for Erlang SAST"
1067+ exit 0
1068+ EOF
1069+ chmod +x "$HOME/.polaris-stubs/bundle"
1070+
1071+ # Prepend to PATH so stub is found before any system bundler
1072+ echo "$HOME/.polaris-stubs" >> $GITHUB_PATH
1073+
1074+ echo "Bundle stub created and added to PATH"
10261075
10271076 - name : Starting Black Duck Polaris scan
10281077 run : |
@@ -1332,7 +1381,7 @@ jobs:
13321381 name : ' Generating SBOM'
13331382 # Create software bill-of-materials (SBOM) using SPDX format
13341383 if : ${{ inputs.generate-sbom == true }}
1335- uses : chef/common-github-actions/.github/workflows/sbom.yml@main
1384+ uses : chef/common-github-actions/.github/workflows/sbom.yml@sandhi/fix-blackduc-sca
13361385 needs : checkout # TODO: fix set-application-version
13371386 secrets : inherit
13381387 with :
0 commit comments