File tree Expand file tree Collapse file tree 2 files changed +20
-7
lines changed
Expand file tree Collapse file tree 2 files changed +20
-7
lines changed Original file line number Diff line number Diff line change 8080 base_uri : https://eu-2.ast.checkmarx.net/
8181 cx_client_id : ${{ secrets.CX_CLIENT_ID }}
8282 cx_client_secret : ${{ secrets.CX_CLIENT_SECRET_EU }}
83- additional_params : --scs-repo-url https://github.com/midnightntwrk/midnight-node-docker --scs-repo-token ${{ secrets.MIDNIGHTCI_REPO }}
83+ additional_params : >
84+ --report-format sarif
85+ --scs-repo-url https://github.com/midnightntwrk/midnight-node-docker
86+ --scs-repo-token ${{ secrets.MIDNIGHTCI_REPO }}
87+ - name : Filter out repo level issues that github can't handle
88+ run : |
89+ mv ./cx_result.sarif ./cx_result.sarif.orig
90+ jq '. | .runs[0].results |= map(select(.locations[0].physicalLocation.artifactLocation.uri != ""))' cx_result.sarif.orig > cx_result.sarif
91+
92+ # Upload results to github
93+ - name : Upload SARIF file
94+ uses : github/codeql-action/upload-sarif@86b04fb0e47484f7282357688f21d5d0e32175fe # v3.29.2
95+ with :
96+ sarif_file : cx_result.sarif
Original file line number Diff line number Diff line change 44CONTAINER_NAME=" midnight"
55
66# Check if the container already exists
7- if [ $( docker ps -a -f name=^${CONTAINER_NAME} $ --format ' {{.Names}}' | grep -w ${CONTAINER_NAME} | wc -l ) -eq 0 ]; then
7+ if [ " $( docker ps -a -f name=^${CONTAINER_NAME} $ --format ' {{.Names}}' | grep -c -w " ${CONTAINER_NAME} " ) " -eq 0 ]; then
88 echo " Container '${CONTAINER_NAME} ' does not exist. Creating and starting it..."
9-
9+
1010 # Run the container with the specified configuration
1111 docker run -it \
1212 --name ${CONTAINER_NAME} \
@@ -18,13 +18,13 @@ if [ $(docker ps -a -f name=^${CONTAINER_NAME}$ --format '{{.Names}}' | grep -w
1818 " ${MIDNIGHT_NODE_IMAGE} "
1919else
2020 echo " Container '${CONTAINER_NAME} ' already exists. Opening an interactive shell..."
21-
21+
2222 # Check if the container is running, if not, start it
23- if [ $( docker ps -f name=^${CONTAINER_NAME} $ --format ' {{.Names}}' | grep -w ${CONTAINER_NAME} | wc -l ) -eq 0 ]; then
23+ if [ " $( docker ps -f name=^${CONTAINER_NAME} $ --format ' {{.Names}}' | grep -c -w " ${CONTAINER_NAME} " ) " -eq 0 ]; then
2424 echo " Starting container '${CONTAINER_NAME} '..."
2525 docker start ${CONTAINER_NAME}
2626 fi
27-
27+
2828 # Open an interactive shell in the container
2929 docker exec -it ${CONTAINER_NAME} /bin/bash
30- fi
30+ fi
You can’t perform that action at this time.
0 commit comments