Files

70 lines
1.4 KiB
Docker
Raw Permalink Normal View History

2026-04-18 21:16:17 -05:00
# 1. A: Define a base image
# FROM scratch
# FROM busybox
# FROM alpine:3.22.1
# FROM alpine:latest
# FROM python:3.12
# FROM debian:bookworm-slim
FROM nginx:1.29
ARG USERNAME=itdominator
ARG UID=1000
ARG GID=1000
2026-04-18 21:16:17 -05:00
# 1. B: Set ENV Variables
ENV TERM=xterm-256color
# 2. Setup home user
RUN groupadd -g ${GID} ${USERNAME}
RUN useradd -u ${UID} -g ${GID} -s /bin/bash -m ${USERNAME}
COPY env/* /home/${USERNAME}/
RUN /bin/bash -c 'mkdir -p /home/${USERNAME}/{Coding,Downloads,LazyShare,.local,.config,.cache,.thumbnails}'
RUN chown ${USERNAME}:${USERNAME} -R /home/${USERNAME}
2026-04-18 21:16:17 -05:00
# 3. A: Install dependencies
RUN apt-get update && apt-get install -y \
2026-04-18 21:16:17 -05:00
--no-install-recommends \
--no-install-suggests \
pkg-config \
ca-certificates \
libreadline-dev \
liblzma-dev \
libsqlite3-dev \
libncurses5-dev \
libncursesw5-dev \
libgirepository1.0-dev \
libssl-dev libcairo2-dev \
libgdk-pixbuf-xlib-2.0-0 \
python3-gi gir1.2-gtk-3.0 \
gir1.2-gdkpixbuf-2.0 \
bash-completion \
parallel \
bat \
7zip \
zip \
unzip \
2026-04-18 21:16:17 -05:00
tar \
curl \
wget \
fzf \
less \
tree \
ripgrep \
htop \
nano \
git \
ranger
# 4. Copy files over
# 5. Cleanup
RUN apt-get autoremove -y --purge && apt-get autoclean
2026-04-18 21:16:17 -05:00
RUN rm -rf /var/lib/apt/lists/*
2026-04-18 21:16:17 -05:00
RUN rm -rf /tmp/*
# 6. Expose Port and define the command used to run the app
EXPOSE 80
EXPOSE 443
CMD ["bash"]