File tree Expand file tree Collapse file tree 3 files changed +11
-25
lines changed
Expand file tree Collapse file tree 3 files changed +11
-25
lines changed Original file line number Diff line number Diff line change @@ -94,12 +94,14 @@ RUN set -ex; \
9494 || gpg --batch --keyserver pgp.mit.edu --recv-keys "$GPGKEY" \
9595 || gpg --batch --keyserver keyserver.pgp.com --recv-keys "$GPGKEY"; \
9696 gpg --batch --verify phpMyAdmin.tar.xz.asc phpMyAdmin.tar.xz; \
97- mkdir /usr/src/phpmyadmin; \
98- tar -xf phpMyAdmin.tar.xz -C /usr/src/phpmyadmin --strip-components=1; \
97+ tar -xf phpMyAdmin.tar.xz -C /var/www/html --strip-components=1; \
98+ mkdir -p /var/www/html/tmp; \
99+ chown www-data:www-data /var/www/html/tmp; \
99100 gpgconf --kill all; \
100101 rm -r "$GNUPGHOME" phpMyAdmin.tar.xz phpMyAdmin.tar.xz.asc; \
101- rm -rf /usr/src/phpmyadmin/setup/ /usr/src/phpmyadmin/examples/ /usr/src/phpmyadmin/test/ /usr/src/phpmyadmin/po/ /usr/src/phpmyadmin/composer.json /usr/src/phpmyadmin/RELEASE-DATE-$VERSION; \
102- sed -i "s@define('CONFIG_DIR'.*@define('CONFIG_DIR', '/etc/phpmyadmin/');@" /usr/src/phpmyadmin/libraries/vendor_config.php; \
102+ rm -rf /var/www/html/setup/ /var/www/html/examples/ /var/www/html/test/ /var/www/html/po/ /var/www/html/composer.json /var/www/html/RELEASE-DATE-$VERSION; \
103+ sed -i "s@define('CONFIG_DIR'.*@define('CONFIG_DIR', '/etc/phpmyadmin/');@" /var/www/html/libraries/vendor_config.php; \
104+
103105# Add directory for sessions to allow session persistence
104106 apk del --no-network .fetch-deps
105107
Original file line number Diff line number Diff line change @@ -101,12 +101,13 @@ RUN set -ex; \
101101 || gpg --batch --keyserver pgp.mit.edu --recv-keys "$GPGKEY" \
102102 || gpg --batch --keyserver keyserver.pgp.com --recv-keys "$GPGKEY"; \
103103 gpg --batch --verify phpMyAdmin.tar.xz.asc phpMyAdmin.tar.xz; \
104- mkdir /usr/src/phpmyadmin; \
105- tar -xf phpMyAdmin.tar.xz -C /usr/src/phpmyadmin --strip-components=1; \
104+ tar -xf phpMyAdmin.tar.xz -C /var/www/html --strip-components=1; \
105+ mkdir -p /var/www/html/tmp; \
106+ chown www-data:www-data /var/www/html/tmp; \
106107 gpgconf --kill all; \
107108 rm -r "$GNUPGHOME" phpMyAdmin.tar.xz phpMyAdmin.tar.xz.asc; \
108- rm -rf /usr/src/phpmyadmin /setup/ /usr/src/phpmyadmin /examples/ /usr/src/phpmyadmin /test/ /usr/src/phpmyadmin /po/ /usr/src/phpmyadmin /composer.json /usr/src/phpmyadmin /RELEASE-DATE-$VERSION; \
109- sed -i "s@define('CONFIG_DIR'.*@define('CONFIG_DIR', '/etc/phpmyadmin/');@" /usr/src/phpmyadmin /libraries/vendor_config.php; \
109+ rm -rf /var/www/html /setup/ /var/www/html /examples/ /var/www/html /test/ /var/www/html /po/ /var/www/html /composer.json /var/www/html /RELEASE-DATE-$VERSION; \
110+ sed -i "s@define('CONFIG_DIR'.*@define('CONFIG_DIR', '/etc/phpmyadmin/');@" /var/www/html /libraries/vendor_config.php; \
110111# Add directory for sessions to allow session persistence
111112 \
112113 apt-mark auto '.*' > /dev/null; \
Original file line number Diff line number Diff line change @@ -16,23 +16,6 @@ if [[ "$1" == apache2* ]] || [ "$1" == php-fpm ]; then
1616 group=" $( id -g) "
1717 fi
1818
19- if ! [ -e index.php -a -e url.php ]; then
20- echo >&2 " phpMyAdmin not found in $PWD - copying now..."
21- if [ " $( ls -A) " ]; then
22- echo >&2 " WARNING: $PWD is not empty - press Ctrl+C now if this is an error!"
23- ( set -x; ls -A; sleep 10 )
24- fi
25- tar --create \
26- --file - \
27- --one-file-system \
28- --directory /usr/src/phpmyadmin \
29- --owner " $user " --group " $group " \
30- . | tar --extract --file -
31- echo >&2 " Complete! phpMyAdmin has been successfully copied to $PWD "
32- mkdir -p tmp; \
33- chmod -R 777 tmp; \
34- fi
35-
3619 if [ ! -f /etc/phpmyadmin/config.secret.inc.php ]; then
3720 cat > /etc/phpmyadmin/config.secret.inc.php << EOT
3821<?php
You can’t perform that action at this time.
0 commit comments