From 9da471a4f7e9f2ae335ea71dc04782cf11e589a2 Mon Sep 17 00:00:00 2001 From: Philipp Holzer Date: Mon, 28 May 2018 21:22:41 +0200 Subject: [PATCH 1/2] Bugfixing friendica script and added some README text --- .bin/friendica | 3 +-- 2018.05-rc/apache/bin/friendica | 3 +-- 2018.05-rc/fpm-alpine/bin/friendica | 3 +-- 2018.05-rc/fpm/bin/friendica | 3 +-- README-MAINTENANCE.md | 12 ++++++++---- README.md | 3 ++- 6 files changed, 14 insertions(+), 13 deletions(-) diff --git a/.bin/friendica b/.bin/friendica index f931605..da77b29 100644 --- a/.bin/friendica +++ b/.bin/friendica @@ -96,8 +96,7 @@ friendica_help() { # executes the Friendica console console() { cd $WORKDIR - # Todo starting a php-executable without quoting the arguments seems not secure (but is the only way it works) - sh -c "php $WORKDIR/bin/console.php $@" + php $WORKDIR/bin/console.php "$@" } # executes the composer.phar binary of Friendica diff --git a/2018.05-rc/apache/bin/friendica b/2018.05-rc/apache/bin/friendica index f931605..da77b29 100644 --- a/2018.05-rc/apache/bin/friendica +++ b/2018.05-rc/apache/bin/friendica @@ -96,8 +96,7 @@ friendica_help() { # executes the Friendica console console() { cd $WORKDIR - # Todo starting a php-executable without quoting the arguments seems not secure (but is the only way it works) - sh -c "php $WORKDIR/bin/console.php $@" + php $WORKDIR/bin/console.php "$@" } # executes the composer.phar binary of Friendica diff --git a/2018.05-rc/fpm-alpine/bin/friendica b/2018.05-rc/fpm-alpine/bin/friendica index f931605..da77b29 100644 --- a/2018.05-rc/fpm-alpine/bin/friendica +++ b/2018.05-rc/fpm-alpine/bin/friendica @@ -96,8 +96,7 @@ friendica_help() { # executes the Friendica console console() { cd $WORKDIR - # Todo starting a php-executable without quoting the arguments seems not secure (but is the only way it works) - sh -c "php $WORKDIR/bin/console.php $@" + php $WORKDIR/bin/console.php "$@" } # executes the composer.phar binary of Friendica diff --git a/2018.05-rc/fpm/bin/friendica b/2018.05-rc/fpm/bin/friendica index f931605..da77b29 100644 --- a/2018.05-rc/fpm/bin/friendica +++ b/2018.05-rc/fpm/bin/friendica @@ -96,8 +96,7 @@ friendica_help() { # executes the Friendica console console() { cd $WORKDIR - # Todo starting a php-executable without quoting the arguments seems not secure (but is the only way it works) - sh -c "php $WORKDIR/bin/console.php $@" + php $WORKDIR/bin/console.php "$@" } # executes the composer.phar binary of Friendica diff --git a/README-MAINTENANCE.md b/README-MAINTENANCE.md index 0494669..b3d69de 100644 --- a/README-MAINTENANCE.md +++ b/README-MAINTENANCE.md @@ -9,17 +9,21 @@ Never ever change a file/folder inside a directory without a `.` at the beginnin This folder will get updated automatically based on the templates you want to change. All changes in such folders will get overwritten during an update. -# [`.bin`](https://github.com/friendica/docker/tree/master/.bin) +# Basic files and folders + +Most of the time you want to change one of the followed files. + +## [`.bin`](https://github.com/friendica/docker/tree/master/.bin) This directory holds the binary/shell files for docker images. They get copied into the docker images at `/usr/local/bin`. -# [`.config`](https://github.com/friendica/docker/tree/master/.config) +## [`.config`](https://github.com/friendica/docker/tree/master/.config) This directory holds the config files for docker images. They get copied into the docker images at `/usr/src/config`. -## `htconfig.php` +### `htconfig.php` This file is based on the sample [`htconfig.php`](https://github.com/friendica/friendica/blob/559250b8b3a7a5d0e524d3e3e2d347d18d6c3a2a/htconfig.php) in the Friendica repository. @@ -28,7 +32,7 @@ The differences: - Removed all hard-coded DB settings - Added environment variables for mailname, tz, language -# Templates & shell-scripts +## Templates & shell-scripts - If you want to update/upgrade Dockerfiles, use the right `*.template` file for it. - If you want to update/change the behavior of **every** start of Docker-image, change `docker-entrypoint.sh` diff --git a/README.md b/README.md index dc49298..9a1b1de 100644 --- a/README.md +++ b/README.md @@ -123,7 +123,8 @@ You can preconfigure everything that is asked on the install page on first run. **MYSQL/MariaDB**: -- `MYSQL_USERNAME` Username for the database user using mysql / mariadb. +- `MYSQL_USERNAME` Username for the database user using mysql. +- `MYSQL_USER` Username for the database user using mariadb. - `MYSQL_PASSWORD` Password for the database user using mysql / mariadb. - `MYSQL_DATABASE` Name of the database using mysql / mariadb. - `MYSQL_HOST` Hostname of the database server using mysql / mariadb. From 9400a02db960a7ab9d7a2a5beb6c8e73c95de814 Mon Sep 17 00:00:00 2001 From: Philipp Holzer Date: Mon, 28 May 2018 21:25:18 +0200 Subject: [PATCH 2/2] fixed TAB for README --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 9a1b1de..5ea87e0 100644 --- a/README.md +++ b/README.md @@ -124,7 +124,7 @@ You can preconfigure everything that is asked on the install page on first run. **MYSQL/MariaDB**: - `MYSQL_USERNAME` Username for the database user using mysql. -- `MYSQL_USER` Username for the database user using mariadb. +- `MYSQL_USER` Username for the database user using mariadb. - `MYSQL_PASSWORD` Password for the database user using mysql / mariadb. - `MYSQL_DATABASE` Name of the database using mysql / mariadb. - `MYSQL_HOST` Hostname of the database server using mysql / mariadb.