Skip to content

Commit 3d7526e

Browse files
authored
fix: add safe directory to git (#57)
1 parent c173881 commit 3d7526e

File tree

2 files changed

+14
-1
lines changed

2 files changed

+14
-1
lines changed

Dockerfile

+8-1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,10 @@
1-
FROM python:3.8
1+
FROM python:3.11-alpine
2+
3+
RUN set -eux; \
4+
apk add --no-cache \
5+
git \
6+
gpg \
7+
bash \
8+
;
29
COPY entrypoint.sh /entrypoint.sh
310
ENTRYPOINT ["/entrypoint.sh"]

entrypoint.sh

+6
Original file line numberDiff line numberDiff line change
@@ -2,14 +2,20 @@
22

33
set -e
44

5+
# Reporting
56
gpg --version
7+
git --version
68

79
if [[ -z $INPUT_GITHUB_TOKEN ]]; then
810
echo 'Missing input "github_token: ${{ secrets.GITHUB_TOKEN }}".' >&2
911
exit 1
1012
fi
1113

1214
echo "Configuring Git username, email, and pull behavior..."
15+
16+
# Fix #56
17+
git config --global --add safe.directory "*"
18+
1319
git config --local user.name "${INPUT_GIT_NAME}"
1420
git config --local user.email "${INPUT_GIT_EMAIL}"
1521
git config --local pull.rebase true

0 commit comments

Comments
 (0)