generated from oci/template
All checks were successful
Build Docker Image on Commit / build-and-publish (push) Successful in 2m53s
46 lines
1.1 KiB
Docker
46 lines
1.1 KiB
Docker
FROM eclipse-temurin:17-jammy
|
|
|
|
# Install all required packages
|
|
RUN apt-get update && apt-get install -y \
|
|
postgresql-common \
|
|
emacs-nox \
|
|
net-tools \
|
|
netcat \
|
|
vim \
|
|
unzip \
|
|
curl \
|
|
sudo \
|
|
gosu
|
|
|
|
RUN yes | /usr/share/postgresql-common/pgdg/apt.postgresql.org.sh
|
|
RUN apt-get update && apt-get install -y \
|
|
postgresql-15 \
|
|
postgresql-15-postgis-3 \
|
|
postgresql-client-15 \
|
|
postgresql-contrib-15
|
|
|
|
RUN apt-get clean && \
|
|
rm -rf /var/lib/apt/lists/*
|
|
|
|
# Create tak user and directories
|
|
RUN useradd -m -s /bin/bash tak && \
|
|
mkdir -p /opt/tak /opt/tak/logs /takserver-zip && \
|
|
chown -R tak:tak /opt/tak
|
|
|
|
# Configure PostgreSQL data directory (initialization will be done at runtime)
|
|
RUN mkdir -p /var/lib/postgresql/15/main && \
|
|
chown -R postgres:postgres /var/lib/postgresql
|
|
|
|
# Copy all scripts into the container
|
|
COPY entrypoint.sh /entrypoint.sh
|
|
COPY scripts/ /scripts/
|
|
|
|
# Make all scripts executable
|
|
RUN chmod +x /entrypoint.sh && \
|
|
chmod +x /scripts/*.sh
|
|
|
|
# Expose common TAK server ports
|
|
EXPOSE 5432 8080 8443 8444 8446
|
|
|
|
# Set the entrypoint
|
|
ENTRYPOINT ["/entrypoint.sh"]
|