1
0
mirror of https://github.com/bitwarden/server.git synced 2024-11-22 12:15:36 +01:00
bitwarden-server/util/MsSql/Dockerfile

28 lines
822 B
Docker
Raw Normal View History

2019-05-07 17:14:37 +02:00
FROM mcr.microsoft.com/mssql/server:2017-CU14
LABEL com.bitwarden.product="bitwarden"
2017-08-21 16:58:00 +02:00
RUN apt-get update \
&& apt-get install -y --no-install-recommends \
cron \
2018-03-27 03:38:32 +02:00
gosu \
2017-08-21 16:58:00 +02:00
&& rm -rf /var/lib/apt/lists/*
COPY crontab /etc/cron.d/bitwarden-cron
2018-03-27 20:55:33 +02:00
RUN chmod 0644 /etc/cron.d/bitwarden-cron
2017-08-21 16:58:00 +02:00
COPY backup-db.sql /
COPY backup-db.sh /
COPY entrypoint.sh /
2018-03-26 17:21:03 +02:00
2018-03-27 20:55:33 +02:00
RUN chmod +x /entrypoint.sh \
&& chmod +x /backup-db.sh
2018-04-16 21:30:07 +02:00
RUN /opt/mssql/bin/mssql-conf set telemetry.customerfeedback false
# As the setting above does not work, let's use the workaround below
RUN echo 127.0.0.1 settings-win.data.microsoft.com >> /etc/hosts
RUN echo 127.0.0.1 vortex.data.microsoft.com >> /etc/hosts
2019-07-26 18:16:38 +02:00
HEALTHCHECK --timeout=3s CMD sqlcmd -S localhost -U sa -P ${SA_PASSWORD} -Q "SELECT 1" || exit 1
ENTRYPOINT ["/entrypoint.sh"]