initial
This commit is contained in:
32
Dockerfile
Normal file
32
Dockerfile
Normal file
@@ -0,0 +1,32 @@
|
|||||||
|
FROM debian:trixie-slim
|
||||||
|
|
||||||
|
RUN set -eux; \
|
||||||
|
groupadd -r postgres --gid=5432; \
|
||||||
|
useradd -r -g postgres --uid=5432 --home-dir=/var/lib/postgresql --shell=/bin/bash postgres; \
|
||||||
|
install --verbose --directory --owner postgres --group postgres --mode 1755 /var/lib/postgresql
|
||||||
|
|
||||||
|
RUN apt-get update; \
|
||||||
|
apt-get install -y --no-install-recommends \
|
||||||
|
openssh-server \
|
||||||
|
sudo \
|
||||||
|
; \
|
||||||
|
rm -rf /var/lib/apt/lists/*; \
|
||||||
|
echo "postgres ALL = (ALL) NOPASSWD:ALL" >> /etc/sudoers; \
|
||||||
|
echo "X11Forwarding no" >> /etc/ssh/sshd_config; \
|
||||||
|
echo "PasswordAuthentication no" >> /etc/ssh/sshd_config; \
|
||||||
|
echo "StrictHostKeyChecking no" >> /etc/ssh/ssh_config
|
||||||
|
|
||||||
|
RUN set -eux; \
|
||||||
|
grep -q '/usr/share/locale' /etc/dpkg/dpkg.cfg.d/docker; \
|
||||||
|
sed -ri '/\/usr\/share\/locale/d' /etc/dpkg/dpkg.cfg.d/docker; \
|
||||||
|
! grep -q '/usr/share/locale' /etc/dpkg/dpkg.cfg.d/docker; \
|
||||||
|
apt-get update; \
|
||||||
|
apt-get install -y --no-install-recommends \
|
||||||
|
locales; \
|
||||||
|
rm -rf /var/lib/apt/lists/*; \
|
||||||
|
echo 'en_US.UTF-8 UTF-8' >> /etc/locale.gen; \
|
||||||
|
locale-gen; \
|
||||||
|
locale -a | grep 'en_US.utf8'
|
||||||
|
ENV LANG=en_US.utf8
|
||||||
|
|
||||||
|
ENTRYPOINT ["bash"]
|
||||||
Reference in New Issue
Block a user