docker-autopostgresqlbackup/Dockerfile

26 lines
656 B
Docker
Raw Normal View History

2021-10-03 13:01:10 +02:00
FROM alpine:3
2018-01-23 18:01:22 +01:00
# Labels
2019-05-29 23:40:12 +02:00
LABEL maintainer="Charles Lu <github.com/charleszlu>"
2018-01-23 18:01:22 +01:00
# Environment variables (with default values)
2018-01-24 01:08:19 +01:00
ENV CRON_LOG_LEVEL=8
2018-01-23 18:01:22 +01:00
# Packages installation
2019-05-29 23:44:25 +02:00
RUN apk --update add --no-cache bash bzip2 gzip postgresql-client tzdata
2018-01-23 18:01:22 +01:00
2018-01-23 18:13:52 +01:00
# Copy files to the image
2019-05-29 23:59:37 +02:00
COPY autopostgresqlbackup.conf /etc/default/autopostgresqlbackup
COPY autopostgresqlbackup /usr/sbin/autopostgresqlbackup
RUN chmod 755 /usr/sbin/autopostgresqlbackup
2018-01-23 18:13:52 +01:00
2018-01-23 18:01:22 +01:00
# Configure entrypoint
2019-05-29 23:59:37 +02:00
COPY docker-entrypoint.sh /docker-entrypoint.sh
2018-01-23 18:01:22 +01:00
RUN chmod +x /docker-entrypoint.sh
# Volumes declaration
VOLUME ["/backups"]
2018-01-23 18:01:22 +01:00
# Start the container process
ENTRYPOINT ["/docker-entrypoint.sh"]