mirror of
https://gitee.com/mirrors_adrian-thurston/yq.git
synced 2026-01-14 23:43:38 +08:00
Fixed docker permission issue #1014
This commit is contained in:
@@ -20,6 +20,9 @@ WORKDIR /workdir
|
||||
RUN set -eux; \
|
||||
addgroup -g 1000 yq; \
|
||||
adduser -u 1000 -G yq -s /bin/sh -h /home/yq -D yq
|
||||
|
||||
RUN chown -R yq:yq /workdir
|
||||
|
||||
USER yq
|
||||
|
||||
ENTRYPOINT ["/usr/bin/yq"]
|
||||
|
||||
5
scripts/test-docker.sh
Executable file
5
scripts/test-docker.sh
Executable file
@@ -0,0 +1,5 @@
|
||||
#! /bin/bash
|
||||
set -e
|
||||
|
||||
docker build . -t temp
|
||||
docker run --rm -it --entrypoint sh temp -c 'touch a'
|
||||
Reference in New Issue
Block a user