1tbfree commited on
Commit
ee37255
·
verified ·
1 Parent(s): adc55c2

Create Dockerfile

Browse files

Username: myuser
Password: password

Files changed (1) hide show
  1. Dockerfile +27 -0
Dockerfile ADDED
@@ -0,0 +1,27 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # Use the official Ubuntu image as the base
2
+ FROM ubuntu:20.04
3
+
4
+ # Set environment variables
5
+ ENV DEBIAN_FRONTEND=noninteractive
6
+
7
+ # Update the package list and install necessary packages
8
+ RUN apt-get update && \
9
+ apt-get install -y \
10
+ shellinabox \
11
+ sudo \
12
+ && apt-get clean \
13
+ && rm -rf /var/lib/apt/lists/*
14
+
15
+ # Create a new user and set a password using chpasswd
16
+ RUN useradd -m myuser && \
17
+ echo "myuser:password" | chpasswd && \
18
+ adduser myuser sudo
19
+
20
+ # Expose the Shell In A Box port
21
+ EXPOSE 7860
22
+
23
+ # Configure Shell In A Box to listen on port 7060
24
+ RUN sed -i 's/--port=4200/--port=7860/g' /etc/default/shellinabox
25
+
26
+ # Start Shell In A Box
27
+ CMD ["shellinaboxd", "-t", "--no-beep", "--disable-ssl"]