Skip to content

Commit e73cd26

Browse files
authored
Merge pull request #179 from step-security/fix/github-context
"fix: fixed github context issue for docker-based actions"
2 parents 6586c63 + 9d91b8c commit e73cd26

3 files changed

Lines changed: 2 additions & 3 deletions

File tree

Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
FROM alpine:3.23@sha256:25109184c71bdad752c8312a8623239686a9a2071e8825f20acb8f2198c3f659
2-
RUN apk add --no-cache curl docker-cli
2+
RUN apk add --no-cache curl docker-cli jq
33
COPY start-mongodb.sh /start-mongodb.sh
44
RUN chmod +x /start-mongodb.sh
55
ENTRYPOINT ["/start-mongodb.sh"]

action.yml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -58,5 +58,3 @@ runs:
5858
- ${{ inputs.mongodb-username }}
5959
- ${{ inputs.mongodb-password }}
6060
- ${{ inputs.mongodb-container-name }}
61-
env:
62-
REPO_PRIVATE: ${{ github.event.repository.private }}

start-mongodb.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@ MONGODB_CONTAINER_NAME=$8
1414
UPSTREAM="supercharge/mongodb-github-action"
1515
ACTION_REPO="${GITHUB_ACTION_REPOSITORY:-}"
1616
DOCS_URL="https://docs.stepsecurity.io/actions/stepsecurity-maintained-actions"
17+
REPO_PRIVATE=$(jq -r '.repository.private | tostring' "$GITHUB_EVENT_PATH" 2>/dev/null || echo "")
1718

1819
echo ""
1920
echo -e "\033[1;36mStepSecurity Maintained Action\033[0m"

0 commit comments

Comments
 (0)