mirror of
https://github.com/cwinfo/powerdns-admin.git
synced 2025-01-07 10:55:40 +00:00
Merge remote-tracking branch '7digital/feature/docker-wait-for-mysql'
This commit is contained in:
commit
c43743aac0
@ -22,6 +22,9 @@ RUN echo "deb https://dl.yarnpkg.com/debian/ stable main" > /etc/apt/sources.lis
|
|||||||
RUN apt-get update -y
|
RUN apt-get update -y
|
||||||
RUN apt-get install -y yarn
|
RUN apt-get install -y yarn
|
||||||
|
|
||||||
|
# Install Netcat for DB healthcheck
|
||||||
|
RUN apt-get install -y netcat
|
||||||
|
|
||||||
# lib for building mysql db driver
|
# lib for building mysql db driver
|
||||||
RUN apt-get install -y libmysqlclient-dev
|
RUN apt-get install -y libmysqlclient-dev
|
||||||
|
|
||||||
@ -29,7 +32,7 @@ RUN apt-get install -y libmysqlclient-dev
|
|||||||
RUN apt-get install -y libsasl2-dev libldap2-dev libssl-dev
|
RUN apt-get install -y libsasl2-dev libldap2-dev libssl-dev
|
||||||
|
|
||||||
# lib for building python3-saml
|
# lib for building python3-saml
|
||||||
RUN apt-get install -y libxml2-dev libxslt1-dev libxmlsec1-dev libffi-dev pkg-config
|
RUN apt-get install -y libxml2-dev libxslt1-dev libxmlsec1-dev libffi-dev pkg-config
|
||||||
|
|
||||||
COPY ./requirements.txt /powerdns-admin/requirements.txt
|
COPY ./requirements.txt /powerdns-admin/requirements.txt
|
||||||
RUN pip3 install -r requirements.txt
|
RUN pip3 install -r requirements.txt
|
||||||
|
@ -1,5 +1,14 @@
|
|||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
|
|
||||||
|
# Wait for us to be able to connect to MySQL before proceeding
|
||||||
|
until nc -zv \
|
||||||
|
$PDA_DB_HOST \
|
||||||
|
3306;
|
||||||
|
do
|
||||||
|
echo "MySQL ($PDA_DB_HOST) is unavailable - sleeping"
|
||||||
|
sleep 1
|
||||||
|
done
|
||||||
|
|
||||||
cd /powerdns-admin
|
cd /powerdns-admin
|
||||||
|
|
||||||
if [ ! -d "/powerdns-admin/migrations" ]; then
|
if [ ! -d "/powerdns-admin/migrations" ]; then
|
||||||
|
Loading…
Reference in New Issue
Block a user