- Created package.json for managing workspaces (frontend and backend) - Added scripts for development, build, testing, and Docker operations - Implemented kill-dev-processes.sh script to terminate development processes gracefully
26 lines
565 B
Docker
26 lines
565 B
Docker
FROM node:18
|
|
|
|
# Install git and other useful tools
|
|
RUN apt-get update && apt-get install -y \
|
|
git \
|
|
curl \
|
|
vim \
|
|
&& rm -rf /var/lib/apt/lists/*
|
|
|
|
# Set working directory
|
|
WORKDIR /workspace
|
|
|
|
# Install global packages
|
|
RUN npm install -g typescript ts-node nodemon
|
|
|
|
# Create user with same UID as host (for file permissions)
|
|
ARG USERNAME=node
|
|
ARG USER_UID=1000
|
|
ARG USER_GID=$USER_UID
|
|
|
|
RUN groupmod --gid $USER_GID $USERNAME \
|
|
&& usermod --uid $USER_UID --gid $USER_GID $USERNAME \
|
|
&& chown -R $USER_UID:$USER_GID /home/$USERNAME
|
|
|
|
USER $USERNAME
|