Fossil SCM

Switched from "adduser" and "addgroup" commands for setting up the "fossil" user to direct echo-into-output, same as we already do for the root user. We had to to it for root since the BusyBox implementation of adduser/addgroup won't create these files if they're missing, but that meant we had two different ways of creating users and groups. This not only removes a weak dependency, it's more consistent.

wyoung 2023-03-24 05:20 trunk
Commit fff11fc60486f2d2682b2fb7c7533682a6f96c1ac1edbfcc5d8e5bae36d998d4
1 file changed +4 -4
+4 -4
--- Dockerfile
+++ Dockerfile
@@ -71,14 +71,14 @@
7171
7272
### Set up that base OS for our specific use without tying it to
7373
### anything likely to change often. So long as the user leaves
7474
### UID alone, this layer will be durable.
7575
RUN set -x \
76
- && echo 'root:x:0:0:SysAdmin:/:/bin/nologin' > /etc/passwd \
77
- && echo 'root:x:0:root' > /etc/group \
78
- && addgroup -S -g ${UID} fossil \
79
- && adduser -S -h `pwd` -g 'Fossil User' -G fossil -u ${UID} fossil \
76
+ && echo "root:x:0:0:Admin:/:/false" > /etc/passwd \
77
+ && echo "root:x:0:root" > /etc/group \
78
+ && echo "fossil:x:${UID}:${UID}:User:/jail:/false" >> /etc/passwd \
79
+ && echo "fossil:x:${UID}:fossil" >> /etc/group \
8080
&& install -d -m 700 -o fossil -g fossil log museum \
8181
&& install -d -m 755 -o fossil -g fossil dev \
8282
&& install -d -m 755 -o root -g root /usr/bin \
8383
&& install -d -m 400 -o root -g root /run \
8484
&& install -d -m 1777 -o root -g root /tmp \
8585
--- Dockerfile
+++ Dockerfile
@@ -71,14 +71,14 @@
71
72 ### Set up that base OS for our specific use without tying it to
73 ### anything likely to change often. So long as the user leaves
74 ### UID alone, this layer will be durable.
75 RUN set -x \
76 && echo 'root:x:0:0:SysAdmin:/:/bin/nologin' > /etc/passwd \
77 && echo 'root:x:0:root' > /etc/group \
78 && addgroup -S -g ${UID} fossil \
79 && adduser -S -h `pwd` -g 'Fossil User' -G fossil -u ${UID} fossil \
80 && install -d -m 700 -o fossil -g fossil log museum \
81 && install -d -m 755 -o fossil -g fossil dev \
82 && install -d -m 755 -o root -g root /usr/bin \
83 && install -d -m 400 -o root -g root /run \
84 && install -d -m 1777 -o root -g root /tmp \
85
--- Dockerfile
+++ Dockerfile
@@ -71,14 +71,14 @@
71
72 ### Set up that base OS for our specific use without tying it to
73 ### anything likely to change often. So long as the user leaves
74 ### UID alone, this layer will be durable.
75 RUN set -x \
76 && echo "root:x:0:0:Admin:/:/false" > /etc/passwd \
77 && echo "root:x:0:root" > /etc/group \
78 && echo "fossil:x:${UID}:${UID}:User:/jail:/false" >> /etc/passwd \
79 && echo "fossil:x:${UID}:fossil" >> /etc/group \
80 && install -d -m 700 -o fossil -g fossil log museum \
81 && install -d -m 755 -o fossil -g fossil dev \
82 && install -d -m 755 -o root -g root /usr/bin \
83 && install -d -m 400 -o root -g root /run \
84 && install -d -m 1777 -o root -g root /tmp \
85

Keyboard Shortcuts

Open search /
Next entry (timeline) j
Previous entry (timeline) k
Open focused entry Enter
Show this help ?
Toggle theme Top nav button