-
Notifications
You must be signed in to change notification settings - Fork 5
/
Dockerfile
61 lines (37 loc) · 1.34 KB
/
Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
# -----------------------------------------------------------------------------
# This is base image of Ubuntu LTS with SSHD service.
#
# Authors: Art567
# Updated: Sep 20th, 2015
# Require: Docker (http://www.docker.io/)
# -----------------------------------------------------------------------------
# Base system is the latest LTS version of Ubuntu.
# from consol/ubuntu-xfce-vnc
# due to dependency issues vnc is still work in progress
from dorowu/ubuntu-desktop-lxde-vnc
# Switch to root user to install additional software
USER 0
# Make sure we don't get notifications we can't answer during building.
env DEBIAN_FRONTEND noninteractive
# Prepare scripts and configs
add ./scripts/start /start
# Download and install everything from the repos.
run apt-get -q -y update; apt-get -q -y upgrade && \
apt-get -q -y install sudo openssh-server && \
mkdir /var/run/sshd
# Set root password
run echo 'root:password' >> /root/passwdfile
# Create user and it's password
run useradd -m -G sudo master && \
echo 'master:password' >> /root/passwdfile
# Apply root password
run chpasswd -c SHA512 < /root/passwdfile && \
rm /root/passwdfile
# Port 22 is used for ssh
expose 22
# Assign /data as static volume.
volume ["/data"]
# Fix all permissions
run chmod +x /start
# Starting sshd
cmd ["/start"]