-
Notifications
You must be signed in to change notification settings - Fork 9
Expand file tree
/
Copy pathDockerfile
More file actions
63 lines (51 loc) · 1.28 KB
/
Dockerfile
File metadata and controls
63 lines (51 loc) · 1.28 KB
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
62
63
FROM node:24-trixie-slim
# Install additional terminal utilities and prerequisites
RUN apt-get update && apt-get upgrade -y && apt-get install -y --fix-missing \
apt-utils \
curl \
wget \
ssh \
git \
vim \
nano \
htop \
net-tools \
iputils-ping \
fontconfig \
unzip \
locales \
traceroute \
build-essential \
python3 \
&& rm -rf /var/lib/apt/lists/*
# Configure locales
RUN sed -i '/en_US.UTF-8/s/^# //g' /etc/locale.gen && \
locale-gen en_US.UTF-8 && \
update-locale LANG=en_US.UTF-8 LC_ALL=en_US.UTF-8
# Set environment variables for locale
ENV LANG=en_US.UTF-8 \
LANGUAGE=en_US:en \
LC_ALL=en_US.UTF-8 \
SHELL=/bin/bash
# Install Starship
RUN curl -sS https://starship.rs/install.sh | sh -s -- --yes
WORKDIR /app
# Copy package files first for better layer caching
COPY package*.json ./
# Install dependencies
RUN npm ci --production && \
npm cache clean --force
# Copy entrypoint script and set permissions
COPY entrypoint.sh /entrypoint.sh
RUN chmod +x /entrypoint.sh
# Create data directory
RUN mkdir -p data
# Copy application files
COPY . .
# Build node-pty and copy xterm files
RUN npm run copy-xterm
# Expose port
EXPOSE 3000
# Start the application
ENTRYPOINT ["/entrypoint.sh"]
CMD ["npm", "start"]