Skip to content

Commit 492b80f

Browse files
author
Calvin A. Allen
committed
Don't scan on PRs
1 parent e103bf1 commit 492b80f

File tree

2 files changed

+10
-3
lines changed

2 files changed

+10
-3
lines changed

.github/workflows/build_image.yml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,4 +32,3 @@ jobs:
3232
BROWSER_TRUST_KEY=${{ secrets.BROWSER_TRUST_KEY }}
3333
BROWSER_AGENT_ID=${{ secrets.BROWSER_AGENT_ID }}
3434
BROWSER_APPLICATION_ID=${{ secrets.BROWSER_APPLICATION_ID }}
35-
FOSSA_API_KEY=${{ secrets.FOSSA_API_KEY }}

Dockerfile

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -41,8 +41,16 @@ ENV FOSSA_API_KEY=$FOSSA_API_KEY
4141
RUN --mount=type=cache,target=/root/.gradle ./gradlew downloadNewRelicAgent --console=plain --info --no-daemon --no-watch-fs
4242
RUN --mount=type=cache,target=/root/.gradle ./gradlew build --console=plain --info --no-daemon --no-watch-fs
4343

44-
RUN curl -H 'Cache-Control: no-cache' https://raw.githubusercontent.com/fossas/fossa-cli/master/install-latest.sh | bash
45-
RUN fossa analyze
44+
RUN if [ -z "$FOSSA_API_KEY" ] ; then \
45+
echo --SKIPPING FOSSA CLI DOWNLOAD ; \
46+
else \
47+
curl -H 'Cache-Control: no-cache' https://raw.githubusercontent.com/fossas/fossa-cli/master/install-latest.sh | bash; \
48+
fi
49+
RUN if [ -z "$FOSSA_API_KEY" ] ; then \
50+
echo --SKIPPING FOSSA SCAN ; \
51+
else \
52+
fossa analyze; \
53+
fi
4654

4755
FROM base AS final
4856
WORKDIR /app

0 commit comments

Comments
 (0)