Skip to content

Commit

Permalink
Testing nss wrapper
Browse files Browse the repository at this point in the history
  • Loading branch information
Garrett Potts committed Oct 8, 2018
1 parent abd8f93 commit 4be560d
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 1 deletion.
2 changes: 1 addition & 1 deletion build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ buildscript {
rm /etc/apt/sources.list.d/nodejs.list && \\
apt-get clean""",
"COPY / /home/omar",
"""RUN chown -R 1001:0 /home/omar && chmod -R g+w /home/omar && \\
"""RUN chown -R 1001:0 /home/omar && chmod -R g+w /home/omar && chmod 777 /home/omar && \\
rm -rf /data && \\
cd /home/omar && \\
npm install --production && \\
Expand Down
9 changes: 9 additions & 0 deletions docker/run.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,13 @@
#!/bin/bash
export USER_ID=$(id -u)
export GROUP_ID=$(id -g)
sed '/^omar/d' /etc/passwd > /tmp/passwd
echo omar:x:$USER_ID:$GROUP_ID:Default Application User:$HOME:/sbin/nologin >> /tmp/passwd

export LD_PRELOAD=/usr/lib64/libnss_wrapper.so
export NSS_WRAPPER_PASSWD=/tmp/passwd
export NSS_WRAPPER_GROUP=/etc/group

start-stop-daemon --start --pidfile ~/xvfb.pid --make-pidfile --background --exec /usr/bin/Xvfb -- :99 -screen 0 1024x768x24 -ac +extension GLX +render -noreset
sleep 1

Expand Down

0 comments on commit 4be560d

Please sign in to comment.