mirror of
https://github.com/linuxserver/docker-project-template.git
synced 2026-02-20 02:41:25 +08:00
32 lines
1.3 KiB
Docker
32 lines
1.3 KiB
Docker
FROM linuxserver/baseimage
|
||
MAINTAINER Your Name <your@email.com>
|
||
ENV APTLIST="packages to install and update via apt"
|
||
#Applying stuff
|
||
RUN apt-get update -q && \
|
||
##DO STUFF HERE
|
||
## END EACH LINE WITH && \
|
||
## EXCEPT THE LINE BELOW
|
||
apt-get clean && rm -rf /tmp/* /var/lib/apt/lists/* /var/tmp/*
|
||
|
||
|
||
#Adding Custom files
|
||
ADD init/ /etc/my_init.d/
|
||
ADD services/ /etc/service/
|
||
ADD cron/ /etc/cron.d/
|
||
ADD defaults/ /defaults/
|
||
RUN chmod -v +x /etc/service/*/run && chmod -v +x /etc/my_init.d/*.sh
|
||
|
||
|
||
# Volumes and Ports
|
||
VOLUME /volume
|
||
EXPOSE PORT
|
||
|
||
## NOTES ##
|
||
## Delete files\folders not needed, e.g. if you dont run any cron commands, delete the cron folder and the "ADD cron/ /etc/cron.d/" line.
|
||
## The User abc, should be running everything, give that permission in any case you need it.
|
||
## Use linuxserver/baseimage as often as posible (or linuxserver/baseimage.nginx where applicable)
|
||
## When creating init's Use 10's where posible, its to allow add stuff in between when needed. also, do not be afraid to split custom code into several little ones.
|
||
## Make stuff as quiet as posible "e.g. apt-get update -qq" (Does not apply to the "app" itself. e.g. plex)
|
||
## user abc and folders /app /config /defaults are all created by baseimage
|
||
## the first available init script is 30<your script>.sh
|