Skip to content
This repository has been archived by the owner on Oct 12, 2024. It is now read-only.

Commit

Permalink
added setting of uid
Browse files Browse the repository at this point in the history
  • Loading branch information
tomoyk committed Jan 1, 2019
1 parent 409662d commit fe05d09
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 2 deletions.
2 changes: 1 addition & 1 deletion Compose.py
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ def add_service(self, info = {
'memswap_limit': '40m',
'sysctls': {
'net.core.somaxconn': 128,
'net.ipv4.tcp_syncookies': 0,
# 'net.ipv4.tcp_syncookies': 0,
},
'ulimits': {
'nproc': 512,
Expand Down
1 change: 1 addition & 0 deletions ssh-server/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ FROM alpine:3.8
MAINTAINER Tomoyuki KOYAMA <webmaster@koyama.me>

ENV SSH_USER guest22
ENV SSH_USER_UID 2000
ENV SSH_PASSWORD L1nuxCLU8
ENV SSH_PORT 22
ENV MAX_SESSION 3
Expand Down
2 changes: 2 additions & 0 deletions ssh-server/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,8 @@ These variables can be defined before running.
- Default: `22/tcp`
- `SSH_USER` : SSH User to connect
- Default: `guest22`
- `SSH_USER_UID` : SSH User's uid
- Default: `2000`
- `SSH_PASSWORD` : SSH Password to connect
- Default: `L1nuxCLU8`
- `MAX_SESSION` : SSH Maximum session
Expand Down
2 changes: 1 addition & 1 deletion ssh-server/entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ sed -i -e "s|#Banner none|Banner /etc/ssh/sshd_banner|g" $SSH_CONF

echo -e "\n===== ADD SSH USER ====="
mkdir /www-data/public_html
adduser -h /www-data -s /bin/sh -D ${SSH_USER}
adduser -h /www-data -s /bin/sh -u ${SSH_USER_UID} -D ${SSH_USER}
chown ${SSH_USER}:${SSH_USER} /www-data

echo -e "\n===== SET SSH PASSWORD ====="
Expand Down

0 comments on commit fe05d09

Please sign in to comment.