Skip to content

Commit 621cabf

Browse files
committed
During startup, make sure there is no migration lock held.
1 parent 1ac9e93 commit 621cabf

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

rootfs/etc/cont-init.d/nginx-proxy-manager.sh

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -114,6 +114,12 @@ if [ ! -f /config/db_init_in_progress ]; then
114114
/usr/bin/mysql_upgrade --silent
115115
fi
116116

117+
# Make sure there is no migration lock held.
118+
# See https://github.com/jlesage/docker-nginx-proxy-manager/issues/4
119+
if [ ! -f /config/db_init_in_progress ]; then
120+
echo 'DELETE FROM nginxproxymanager.migrations_lock WHERE is_locked = 1;' | mysql
121+
fi
122+
117123
# Database initialized properly.
118124
rm -f /config/db_init_in_progress
119125

0 commit comments

Comments
 (0)