mirror of
https://github.com/pterodactyl/development.git
synced 2025-12-10 10:44:48 -06:00
28 lines
1.1 KiB
Plaintext
28 lines
1.1 KiB
Plaintext
FROM ubuntu:20.04
|
|
|
|
LABEL maintainer="dane@daneeveritt.com" \
|
|
description="Base image used by Pterodactyl's development environments to provide SSH support for vagrant." \
|
|
org.opencontainers.image.source=https://github.com/pterodactyl/development
|
|
|
|
ENV DEBIAN_FRONTEND=noninteractive \
|
|
NOTVISIBLE="in users profile" \
|
|
LANG=en_US.UTF-8 \
|
|
LANGUAGE=en_US:en \
|
|
LC_ALL=en_US.UTF-8
|
|
|
|
RUN apt -y update \
|
|
&& apt -y upgrade \
|
|
&& apt -y --no-install-recommends install software-properties-common gpg-agent sudo openssh-server locales curl iproute2 iputils-ping lsb-release git \
|
|
&& sed -i -e 's/# en_US.UTF-8 UTF-8/en_US.UTF-8 UTF-8/' /etc/locale.gen \
|
|
&& locale-gen \
|
|
&& useradd -m -s /bin/bash -p $(echo "vagrant" | openssl passwd -1 -stdin) vagrant \
|
|
&& echo 'ALL ALL = (ALL) NOPASSWD: ALL' > /etc/sudoers \
|
|
&& sed 's@session\s*required\s*pam_loginuid.so@session optional pam_loginuid.so@g' -i /etc/pam.d/sshd \
|
|
&& echo "export VISIBLE=now" >> /etc/profile \
|
|
&& rm -rf /var/lib/apt/lists/*
|
|
|
|
EXPOSE 22
|
|
USER vagrant
|
|
|
|
ENTRYPOINT sudo su -c "service ssh start && /bin/bash"
|