Code Monkey home page Code Monkey logo

humhub-docker's Introduction

Alpine-based PHP-FPM and NGINX HumHub docker-container

Codacy Badge Build Docker Pulls Join the chat at https://gitter.im/humhub-docker/community

HumHub is a feature rich and highly flexible OpenSource Social Network Kit written in PHP. This container provides a quick, flexible and lightweight way to set up a proof-of-concept for detailed evaluation. Using this in production is possible, but please note that there is currently no official support available for this kind of setup.

Versions

This project provides different images and tags for different purposes. For evaluation use humhub:stable, for production consider using the newest minor-version tag (e.g. humhub:1.13).

  • latest : unstable master build (not recommended for production; use with caution, might be unstable!)
  • Minor (e.g 1.13): Always points to the latest release of given minor version. (Recommended)
  • Build (e.g 1.13.4): Always points to the latest release of given build. Very stable but might be outdated.
  • stable: Always points to oldest, still supported, therefore most mature version. Updates include minor-version changes which can include db-schema changes (higher risk).
  • legacy: Try to avoid this tag as much as possible. If your current installation is flagged as "deprecated" the related tag is also changed to "legacy". Please try to upgrade as fast as possible to avoid security and other issues.

Variants

There are 3 different variants of this image. Use the unspecific tag (e.g. humhub:1.13) if you what a running installation as fast as possible. Use the moving tags if you want to stay up-to-date, not caring about version-upgrades. For critical environments we recommend that you stick to the version-tags or digest, not using moving tags.

If plan to build some kind of hosted solution, have a look at docker-compose.prod.yml to understand how the variant images can be used.

  • all-in-one (e.g. humhub:1.13): Multi-service image (nginx + php-fpm). Use this if you are not sure what you need.
  • nginx (e.g. humhub:1.13-nginx): Only static files and nginx proxy config without php.
  • phponly (e.g. humhub:1.13-phponly): HumHub sources bundled with php-fpm. Needs a fcgi application-server to be able to deliver http.

Matrix

  • EndOfLife (EOL) means that there are no more continuous rebuilds happening. These versions can get removed at any time, so please do not use them or upgrade immediately.
  • Versions flagged as Deprecated will enter EOL soon. Please avoid using them or upgrade as soon a possible.
  • Stable Versions are broadly used and are receiving most attention. Using them will most likely provide the best experience.
  • You can use Testing Versions if you need special new features. The newest HumHub versions will be first released in this way to find migration bugs in a save way. If you want to test upgrades to the next major version, this can be done with this tag.
  • Experimental is reserved for development of this project and always defines an early and potentially broken build. We are doing our best to avoid broken releases to latest, but please be warned and do not use this in production environments.
Version Status AllInOne Nginx PHP-Only
1.12 👎 Deprecated humhub:1.12 humhub:1.12 humhub:1.12
1.13 👍 Stable humhub:1.13 humhub:1.13 humhub:1.13
1.14 💥 Experimental humhub:1.14 humhub:1.14 humhub:1.14
Flavor Stable Latest Legacy
AllInOne humhub:stable humhub:latest humhub:legacy
Nginx humhub:stable humhub:latest-nginx humhub:legacy-nginx
PHP-Only humhub:stable humhub:latest-phponly humhub:legacy-phponly

Quickstart

No database integrated. For persistency look at the Compose-File example.

  1. docker run -d --name humhub_db -e MYSQL_ROOT_PASSWORD=root -e MYSQL_DATABASE=humhub mariadb:10.2
  2. docker run -d --name humhub -p 80:80 --link humhub_db:db mriedmann/humhub:stable
  3. open http://localhost/ in browser
  4. complete the installation wizard (use db as database hostname and humhub as database name)
  5. finished

Composer File Example

version: '3.1'
services:
  humhub:
    image: mriedmann/humhub:stable
    links:
      - "db:db"
    ports:
      - "8080:80"
    volumes:
      - "config:/var/www/localhost/htdocs/protected/config"
      - "uploads:/var/www/localhost/htdocs/uploads"
      - "modules:/var/www/localhost/htdocs/protected/modules"
    environment:
      HUMHUB_DB_USER: humhub
      HUMHUB_DB_PASSWORD: humhub

  db:
    image: mariadb:10.2
    environment:
      MYSQL_ROOT_PASSWORD: root
      MYSQL_DATABASE: humhub
      MYSQL_USER: humhub
      MYSQL_PASSWORD: humhub

volumes:
  config: {}
  uploads: {}
  modules: {}

In some situations (e.g. with podman-compose) you have to run compose up twice to give it some time to create the named volumes.

Advanced Config

This container supports some further options which can be configured via environment variables. Look at the docker-compose.yml for some inspiration.

Database Config

To avoid the visual installer at the first startup, set the HUMHUB_DB_PASSWORD and HUMHUB_DB_USER. If you use the --link argument please specify the name of the link as host (via HUMHUB_DB_HOST) or use db as linkname ( --link <container>:db ).

HUMHUB_DB_USER     []
HUMHUB_DB_PASSWORD []
HUMHUB_DB_NAME     [humhub]
HUMHUB_DB_HOST     [db]

Autoinstall Config

HUMHUB_AUTO_INSTALL [false]

If this and HUMHUB_DB_USER are set an automated installation will run during the first startup. This feature utilities a hidden installer-feature used for integration testing ( see code file ).

HUMHUB_PROTO [http]
HUMHUB_HOST  [localhost]

If these are defined during auto-installation, HumHub will be installed and configured to use URLs with those details. (i.e. If they are set as HUMHUB_PROTO=https, HUMHUB_HOST=example.com, HumHub will be installed and configured so that the base URL is https://example.com/. Leaving these as default will result in HumHub being installed and configured to be at http://localhost/.

HUMHUB_ADMIN_LOGIN    [admin]
HUMHUB_ADMIN_EMAIL    [[email protected]]
HUMHUB_ADMIN_PASSWORD [test]

If these are defined during auto-installation, HumHub admin will be created with those credentials.

Startup Config

INTEGRITY_CHECK [1]

This can be set to "false" to disable the startup integrity check. Use with caution!

WAIT_FOR_DB [1]

Can be used to let the startup fail if the db host is unavailable. To disable this, set it to "false". Can be useful if an external db-host is used, avoid when using a linked container.

SET_PJAX [1]

PJAX is a jQuery plugin that uses Ajax and pushState to deliver a fast browsing experience with real permalinks, page titles, and a working back button. (ref) This library is known to cause problems with some browsers during installation. This container starts with PJAX disabled to improve the installation reliability. If this is set (default), PJAX is enabled during the second startup. Set this to "false" to permanently disable PJAX. Please note that changing this after container-creation has no effect on this behavior.

Mailer Config

It is possible to configure HumHub email settings using the following environment variables:

HUMHUB_MAILER_SYSTEM_EMAIL_ADDRESS    [[email protected]]
HUMHUB_MAILER_SYSTEM_EMAIL_NAME       [HumHub]
HUMHUB_MAILER_TRANSPORT_TYPE          [php]
HUMHUB_MAILER_HOSTNAME                []
HUMHUB_MAILER_PORT                    []
HUMHUB_MAILER_USERNAME                []
HUMHUB_MAILER_PASSWORD                []
HUMHUB_MAILER_ENCRYPTION              []
HUMHUB_MAILER_ALLOW_SELF_SIGNED_CERTS []

LDAP Config

It is possible to configure HumHub LDAP authentication settings using the following environment variables:

HUMHUB_LDAP_ENABLED                               [0]
HUMHUB_LDAP_HOSTNAME                              []
HUMHUB_LDAP_PORT                                  []
HUMHUB_LDAP_ENCRYPTION                            []
HUMHUB_LDAP_USERNAME                              []
HUMHUB_LDAP_PASSWORD                              []
HUMHUB_LDAP_BASE_DN                               []
HUMHUB_LDAP_LOGIN_FILTER                          []
HUMHUB_LDAP_USER_FILTER                           []
HUMHUB_LDAP_USERNAME_ATTRIBUTE                    []
HUMHUB_LDAP_EMAIL_ATTRIBUTE                       []
HUMHUB_LDAP_ID_ATTRIBUTE                          []
HUMHUB_LDAP_REFRESH_USERS                         []
HUMHUB_ADVANCED_LDAP_THUMBNAIL_SYNC_PROPERTY      [thumbnailphoto]

PHP Config

It is also possible to change some php-config-settings. This comes in handy if you have to scale this container vertically.

Following environment variables can be used (default values in angle brackets):

PHP_POST_MAX_SIZE       [16M]
PHP_UPLOAD_MAX_FILESIZE [10M]
PHP_MAX_EXECUTION_TIME  [60]
PHP_MEMORY_LIMIT        [1G]
PHP_TIMEZONE            [UTC]

NGINX Config

Following variables can be used to configure the embedded Nginx. The config-file gets rewritten on every container startup and is not persisted. Avoid changing it by hand.

NGINX_CLIENT_MAX_BODY_SIZE [10m]
NGINX_KEEPALIVE_TIMEOUT    [65]
HUMHUB_REVERSEPROXY_WHITELIST ["127.0.0.1"]

HUMHUB_REVERSEPROXY_WHITELIST allows access to the /ping endpoint for the given IP-Address. CIDR notation is supported.

Contribution

Please use the issues-page for bugs or suggestions. Pull-requests are highly welcomed.

Special Thanks

Special thanks go to following contributors for there incredible work on this image:

And also to @luke- and his team for providing, building and maintaining HumHub.

humhub-docker's People

Contributors

actions-user avatar alea81 avatar bkmeneguello avatar bwalti avatar clasko avatar codacy-badger avatar dantefromhell avatar dependabot-preview[bot] avatar dependabot[bot] avatar felli avatar gitter-badger avatar jusdino avatar jvies avatar madmath03 avatar mirfire avatar mriedmann avatar mueller-ma avatar olekristensen avatar pandeybk avatar pascalberger avatar pferraris avatar r4nc0r avatar stffabi avatar timaschew avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

humhub-docker's Issues

nginx: [emerg] "keepalive_timeout" directive invalid value in /etc/nginx/nginx.conf

Hi

Today I tried to upgrade my humhub-docker image from version 1.6.2 to version 1.6.3. Unfortunately, the new container keeps crashing with the following error message:

nginx: [emerg] "keepalive_timeout" directive invalid value in /etc/nginx/nginx.conf:29

Returning to the old version (1.6.2) resolves the problem.

When looking at the /etc/nginx/nginx.conf config file at line 29 I see the following statement:

keepalive_timeout ${NGINX_KEEPALIVE_TIMEOUT};

In my case, the variable $NGINX_KEEPALIVE_TIMEOUT should be replaced by a default value of 65, as I have not defined said variable in my docker-compose.yml file.

I tried to emulate the problem by executing the following statements manually in the running 1.6.3 container:

export NGINX_KEEPALIVE_TIMEOUT=65
defined_envs=$(printf "\${%s} " $(env | grep -E "^NGINX_.*" | cut -d= -f1))
envsubst "$defined_envs" </etc/nginx/nginx.conf >/tmp/nginx.conf

The variable does not get set correctly in /tmp/nginx.conf. I also tried to set it explicitly in docker-compose.yml, with the same result. The problem pertains as well to other variables in /etc/nginx.nginx.conf such as NGINX_CLIENT_MAX_BODY_SIZE.

I am a bit at a loss on what to do here. I will consider host mounting nginx.conf and run with a static configuration if everything else fails.

Anyone seen this error before or know what I could investigate next?

Thank you.

Thomas

on installation, let admin creation be failable

Hi,

when I try to run a new Container with an existing DB, the container cannont complete the Installation becaus it tries to create the admin user and fails. Is it possible to make this a recoverable Error and just print an infromation, or check if DB is initialized and skip admin creation?

Wrong humhub version

Hi,

There is a bug while cloning the Humhub official repo from the Dockerfile. It's much better to use the Git tags than branches, for example, version 1.2.4 doesn't have its own branch, but it has its tag. See: https://github.com/humhub/humhub/releases

Here is the patch to fix it. It works perfectly for me:

diff --git a/Dockerfile b/Dockerfile
index c84568d..789b7b8 100644
--- a/Dockerfile
+++ b/Dockerfile
@@ -45,8 +45,9 @@ RUN chown -R nginx:nginx /var/lib/nginx/ && \
     chmod 777 /var/run/supervisor.sock
 
 RUN mkdir /usr/src && cd /usr/src/ && \
-    git clone --branch $HUMHUB_VERSION https://github.com/humhub/humhub.git humhub && \
+    git clone https://github.com/humhub/humhub.git humhub && \
     cd humhub && \
+    git checkout tags/$HUMHUB_VERSION && \
     sed -i '/YII_DEBUG/s/^/\/\//' index.php && \
     sed -i '/YII_ENV/s/^/\/\//' index.php

Hope it helps. Cheers!

How to integrate Let's Encrypt certificate

Hi,

where would be the best "entry point" to let the container automatically obtain (and refresh) a Let's encrypt certificate? Two new variables ala "DOMAIN" and "EMAIL" would be neccessary to configure the scripts automatically?

Would you consider integrating this into your default build?

kind regards

Michael

"Validation failed"

Hello! I am trying to set up this container with the provided docker-compose file in the repository.
I am getting the error "Validation Failed" from the humhub container.
Stacktrace:

humhub_1  | db (172.18.0.2:3306) open
humhub_1  | Creating database...
humhub_1  | PHP Warning:  Invalid argument supplied for foreach() in /var/www/localhost/htdocs/protected/vendor/yiisoft/yii2/helpers/BaseArrayHelper.php on line 123
humhub_1  | Exception 'yii\db\Exception' with message 'SQLSTATE[HY000] [2002] No such file or directory'
humhub_1  |
humhub_1  | in /var/www/localhost/htdocs/protected/vendor/yiisoft/yii2/db/Connection.php:584
humhub_1  |
humhub_1  | Stack trace:
humhub_1  | #0 /var/www/localhost/htdocs/protected/vendor/yiisoft/yii2/db/Connection.php(928): yii\db\Connection->open()
humhub_1  | #1 /var/www/localhost/htdocs/protected/vendor/yiisoft/yii2/db/Connection.php(915): yii\db\Connection->getMasterPdo()
humhub_1  | #2 /var/www/localhost/htdocs/protected/vendor/yiisoft/yii2/db/Command.php(219): yii\db\Connection->getSlavePdo()
humhub_1  | #3 /var/www/localhost/htdocs/protected/vendor/yiisoft/yii2/db/Command.php(910): yii\db\Command->prepare(true)
humhub_1  | #4 /var/www/localhost/htdocs/protected/vendor/yiisoft/yii2/db/Command.php(405): yii\db\Command->queryInternal('fetchAll', 7)
humhub_1  | #5 /var/www/localhost/htdocs/protected/vendor/yiisoft/yii2/db/mysql/Schema.php(352): yii\db\Command->queryColumn()
humhub_1  | #6 /var/www/localhost/htdocs/protected/vendor/yiisoft/yii2/db/Schema.php(234): yii\db\mysql\Schema->findTableNames('')
humhub_1  | #7 /var/www/localhost/htdocs/protected/humhub/components/console/Application.php(87): yii\db\Schema->getTableNames()
humhub_1  | #8 /var/www/localhost/htdocs/protected/humhub/components/console/Application.php(38): humhub\components\console\Application->isDatabaseInstalled()
humhub_1  | #9 /var/www/localhost/htdocs/protected/vendor/yiisoft/yii2/base/Object.php(107): humhub\components\console\Application->init()
humhub_1  | #10 /var/www/localhost/htdocs/protected/vendor/yiisoft/yii2/base/Application.php(205): yii\base\Object->__construct(Array)
humhub_1  | #11 /var/www/localhost/htdocs/protected/vendor/yiisoft/yii2/console/Application.php(89): yii\base\Application->__construct(Array)
humhub_1  | #12 /var/www/localhost/htdocs/protected/yii(28): yii\console\Application->__construct(Array)
humhub_1  | #13 {main}
humhub_1  | Installing...
humhub_1  | PHP Warning:  Invalid argument supplied for foreach() in /var/www/localhost/htdocs/protected/vendor/yiisoft/yii2/helpers/BaseArrayHelper.php on line 123
humhub_1  | Exception 'yii\db\Exception' with message 'SQLSTATE[HY000] [2002] No such file or directory'
humhub_1  |
humhub_1  | in /var/www/localhost/htdocs/protected/vendor/yiisoft/yii2/db/Connection.php:584
humhub_1  |
humhub_1  | Stack trace:
humhub_1  | #0 /var/www/localhost/htdocs/protected/vendor/yiisoft/yii2/db/Connection.php(928): yii\db\Connection->open()
humhub_1  | #1 /var/www/localhost/htdocs/protected/vendor/yiisoft/yii2/db/Connection.php(915): yii\db\Connection->getMasterPdo()
humhub_1  | #2 /var/www/localhost/htdocs/protected/vendor/yiisoft/yii2/db/Command.php(219): yii\db\Connection->getSlavePdo()
humhub_1  | #3 /var/www/localhost/htdocs/protected/vendor/yiisoft/yii2/db/Command.php(910): yii\db\Command->prepare(true)
humhub_1  | #4 /var/www/localhost/htdocs/protected/vendor/yiisoft/yii2/db/Command.php(405): yii\db\Command->queryInternal('fetchAll', 7)
humhub_1  | #5 /var/www/localhost/htdocs/protected/vendor/yiisoft/yii2/db/mysql/Schema.php(352): yii\db\Command->queryColumn()
humhub_1  | #6 /var/www/localhost/htdocs/protected/vendor/yiisoft/yii2/db/Schema.php(234): yii\db\mysql\Schema->findTableNames('')
humhub_1  | #7 /var/www/localhost/htdocs/protected/humhub/components/console/Application.php(87): yii\db\Schema->getTableNames()
humhub_1  | #8 /var/www/localhost/htdocs/protected/humhub/components/console/Application.php(38): humhub\components\console\Application->isDatabaseInstalled()
humhub_1  | #9 /var/www/localhost/htdocs/protected/vendor/yiisoft/yii2/base/Object.php(107): humhub\components\console\Application->init()
humhub_1  | #10 /var/www/localhost/htdocs/protected/vendor/yiisoft/yii2/base/Application.php(205): yii\base\Object->__construct(Array)
humhub_1  | #11 /var/www/localhost/htdocs/protected/vendor/yiisoft/yii2/console/Application.php(89): yii\base\Application->__construct(Array)
humhub_1  | #12 /var/www/localhost/htdocs/protected/yii(28): yii\console\Application->__construct(Array)
humhub_1  | #13 {main}
humhub_1  | Config preprocessing ...
humhub_1  | PHP Warning:  Invalid argument supplied for foreach() in /var/www/localhost/htdocs/protected/vendor/yiisoft/yii2/helpers/BaseArrayHelper.php on line 123
humhub_1  | Exception 'yii\db\Exception' with message 'SQLSTATE[HY000] [2002] No such file or directory'
humhub_1  |
humhub_1  | in /var/www/localhost/htdocs/protected/vendor/yiisoft/yii2/db/Connection.php:584
humhub_1  |
humhub_1  | Stack trace:
humhub_1  | #0 /var/www/localhost/htdocs/protected/vendor/yiisoft/yii2/db/Connection.php(928): yii\db\Connection->open()
humhub_1  | #1 /var/www/localhost/htdocs/protected/vendor/yiisoft/yii2/db/Connection.php(915): yii\db\Connection->getMasterPdo()
humhub_1  | #2 /var/www/localhost/htdocs/protected/vendor/yiisoft/yii2/db/Command.php(219): yii\db\Connection->getSlavePdo()
humhub_1  | #3 /var/www/localhost/htdocs/protected/vendor/yiisoft/yii2/db/Command.php(910): yii\db\Command->prepare(true)
humhub_1  | #4 /var/www/localhost/htdocs/protected/vendor/yiisoft/yii2/db/Command.php(405): yii\db\Command->queryInternal('fetchAll', 7)
humhub_1  | #5 /var/www/localhost/htdocs/protected/vendor/yiisoft/yii2/db/mysql/Schema.php(352): yii\db\Command->queryColumn()
humhub_1  | #6 /var/www/localhost/htdocs/protected/vendor/yiisoft/yii2/db/Schema.php(234): yii\db\mysql\Schema->findTableNames('')
humhub_1  | #7 /var/www/localhost/htdocs/protected/humhub/components/console/Application.php(87): yii\db\Schema->getTableNames()
humhub_1  | #8 /var/www/localhost/htdocs/protected/humhub/components/console/Application.php(38): humhub\components\console\Application->isDatabaseInstalled()
humhub_1  | #9 /var/www/localhost/htdocs/protected/vendor/yiisoft/yii2/base/Object.php(107): humhub\components\console\Application->init()
humhub_1  | #10 /var/www/localhost/htdocs/protected/vendor/yiisoft/yii2/base/Application.php(205): yii\base\Object->__construct(Array)
humhub_1  | #11 /var/www/localhost/htdocs/protected/vendor/yiisoft/yii2/console/Application.php(89): yii\base\Application->__construct(Array)
humhub_1  | #12 /var/www/localhost/htdocs/protected/yii(28): yii\console\Application->__construct(Array)
humhub_1  | #13 {main}
humhub_1  | validation failed!
humhub-docker_humhub_1 exited with code 1

Thanks!

DB Install should not set HumHub as installed

I think this is a mistake to set HumHub as installed after "only the database" has been installed

$this->setDatabaseInstalled();
$this->stdout(" * Finishing\n", Console::FG_YELLOW);
$this->setInstalled();

and especially since we already have another function to do HumHub actual install:

public function actionWriteSiteConfig($site_name='HumHub', $site_email='[email protected]'){
$this->stdout("Install Site:\n\n", Console::FG_YELLOW);
InitialData::bootstrap();
Yii::$app->settings->set('name', $site_name);
Yii::$app->settings->set('mailer.systemEmailName', $site_email);
Yii::$app->settings->set('secret', UUID::v4());
Yii::$app->settings->set('timeZone', Yii::$app->timeZone);
$this->setInstalled();

Issues with 1.3.2

We have tested 1.3.2:

  • Mark down for links not working: [Link](www.test.com)
  • After a post, the placeholder from the comment section does not vanish, you are standing at the and of that text.

(Maybe these are fixed with humhub version 1.3.7)

Also, there is a vulnerability with Humhub 1.3.6 fixed in 1.3.7 (https://www.humhub.org/de/news/9031)

Support push service

Upcoming 1.3 release will support an additional optional push service. Would be nice to have this supported out of the box by the docker container

Unexpected use of tag "latest"

The use of the tag "latest" isn't the expected, or the expected behaviour.

Tagged one image as "latest" is a bad idea for tagged a experimental image.

Use another, like "latest-experimental", or so on.

"latest" is, in the most of cases, the last stable version.

Regards.

Web config does not allow correct use behind reverse Proxy

If using this container behind a Reverse Proxy (to handle SSL for instance), you will get the following error in the manifest.json:

property 'start_url' ignored, should be same origin as document

This is because Yii filters the X-Forwarded-Proto headers of the reverse proxy:

Going to provide PR for default web config to trust all docker network.

Port 443 not responding

Hi,

I've setup my containers using the composer but added port 443. In my case I never get any response on this. Only port 80. Anyone else has issues with this?

Security Alert

mriedmann/humhub:latest (alpine 3.12.0)

Title Severity CVE Package Name Installed Version Fixed Version References
libxml2: Buffer Overflow vulnerability in xmlEncodeEntitiesInternal at libxml2/entities.c HIGH CVE-2020-24977 libxml2 2.9.10-r4 2.9.10-r5 http://lists.opensuse.org/opensuse-security-announce/2020-09/msg00036.html
https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2020-24977
https://gitlab.gnome.org/GNOME/libxml2/-/issues/178
https://lists.debian.org/debian-lts-announce/2020/09/msg00009.html
https://lists.fedoraproject.org/archives/list/[email protected]/message/2NQ5GTDYOVH26PBCPYXXMGW5ZZXWMGZC/

var/www/localhost/htdocs/composer.lock

Title Severity CVE Package Name Installed Version Fixed Version References
Unsafe deserialization in Yii 2 HIGH CVE-2020-15148 yiisoft/yii2 2.0.36 2.0.38 GHSA-699q-wcff-g9mj
yiisoft/yii2@9abccb9
GHSA-699q-wcff-g9mj
https://nvd.nist.gov/vuln/detail/CVE-2020-15148

CronJobs

At Administration > Information > CronJobs there is an alert about cron jobs. They are not configured. It's possible to setup then?

README

We should write a simple README.md with a short description, basic usage, contribution and licence information. Any kind of help is highly welcomed!

Issues with 1.2.2/1.2.3

Trying to start 1.2.3 gives the following error for me:

docker: Error response from daemon: oci runtime error: container_linux.go:265: starting container process caused "exec: "docker-entrypoint.sh": executable file not found in $PATH".

For me in 1.2.2 the initializing of the databases times out and after login I receive Class GroupPermission not found in PermissionManager.

Dunno if it is humhub itself related or not:
FireFox and Chrome don't work they remain stuck on the first step.
While IE works it returns to start pretty much after every 2 steps orso.

Mounting volumes

How is this container supposed to work with external mounted volumes? I prefere to store the data on a share mounted to the host and mount them to the available volumes. But currently files are written to the volumes during build, and if I afterwards mount empty volums the files are missing.
I can copy the files created during build to my external shares to have them available, but I'm not sure if this is supposed to work with future updates of this container?

Unable to login using Repo Config Files

I was able to get HumHub running using your config files, running with docker-compose, and when I went to set it up it installed automatically. Are you able to expand on how the config files setup a default instance and where the admin login would be?

I see on the docker-entrypoint "Writing config file.." but no username or password.

Thanks

HumHub loading times

Hi,

we are running Humhub hosted in a Docker Swarm behind a Traefik(Reverse Proxy) with a external MariaDB.
But the loading times are a little Problem. It isnt very slow but also not really responsive. Is there anything that I could do to speed that up? I'm seeing some things about a redis cache, but none of that is documented.

Greetings

Error when sending test mail

I'm getting an error when trying to change the email that's used to send mail from Humhub when using the docker container at version 1.6.2.

humhub_1 | [30-Nov-2020 23:18:44] WARNING: [pool www] child 32 said into stderr: "sendmail: can't connect to remote host (127.0.0.1): Connection refused"

PHP is set as the mail transport type. Is SMTP required to get mail working correctly or am I doing something wrong here?

How to use SET_PJAX environment variable?

version: '3.1'
services:
  humhub:
    image: mriedmann/humhub:1.6.2
    ports:
      - "8080:80"
    volumes:
      - "./config:/var/www/localhost/htdocs/protected/config"
      - "./uploads:/var/www/localhost/htdocs/uploads"
      - "./modules:/var/www/localhost/htdocs/protected/modules"
    environment:
      HUMHUB_DB_USER: humhub
      HUMHUB_DB_PASSWORD: humhub
      SET_PJAX: "true"
    depends_on:
      - db

  db:
    image: mariadb:10.2
    environment:
      MYSQL_ROOT_PASSWORD: root
      MYSQL_DATABASE: humhub
      MYSQL_USER: humhub
      MYSQL_PASSWORD: humhub
    volumes:
      - "./db/:/var/lib/mysql"

I tried to set SET_PJAX like this, but it seems not working:
In /var/www/localhost/htdocs/protected/config/common.php, enablePjax is still false.

<?php
/**
 * This file provides to overwrite the default HumHub / Yii configuration by your local common (Console and Web) environments
 * @see http://www.yiiframework.com/doc-2.0/guide-concept-configurations.html
 * @see http://docs.humhub.org/admin-installation-configuration.html
 * @see http://docs.humhub.org/dev-environment.html
 */
return [
	'params' => [
        'enablePjax' => false
    ],
    'components' => [
        'urlManager' => [
            'showScriptName' => false,
            'enablePrettyUrl' => true,
        ],
    ]
];

Documentation: Mail Setup

#112 implemented the possibility to configure mail during initial installation. There should be a short readme section describing the process.

SMTP settings partially saved and functionnal

Hi,

When I try to set the SMTP settings for notifications, I do receive the "Saved" snackbar but the mail setting page resets itself to the defaults parameters:

What's even weirder is that if I check the config file dynamic.php, my SMTP settings are here:

'mailer' =>
array (
  'transport' =>
  array (
    'class' => 'Swift_SmtpTransport',
    'host' => 'mail.domain.net',
    'username' => 'my_correct_username',
    'password' => 'my_correct_password',
    'encryption' => 'ssl',
    'port' => '465',
  ),

And trying to send an email such as password reset, it is indeed sent correctly but from the wrong name [email protected] and wrong address [email protected] which is not ideal.

Any help is appreciated.
Thanks

Inconsistence between documentation and tags.

In the README, you put:

Versions

latest: unstable master build (not recommended)
1.2.2: latest stable release (recommended)
1.0.1: latest 1.0.x release (not recommended)
experimental: test build (testing only)

But on the Docker hub, the last version, is 1.2.0; so, if anyone can use the mriedmann/humhub:1.2.2, he will get a response as:

ERROR: manifest for mriedmann/humhub:1.2.2 not found

Please, update the tags / README files.

Regards.

Environment Variables do not increase the Upload size to 100M

Changing these Environment Variables in the docker-compose does not seem to make any difference. When uploading a large file, it gives an error of max size to 5.243MB

  PHP_POST_MAX_SIZE: '100M'
  PHP_UPLOAD_MAX_FILESIZE: '100M'
  NGINX_CLIENTMAX_BODY_SIZE: '100M'

Error "is too big. Its size cannot exceed 5.243 MB."

Disable debug mode

In Administration > Information there is an alert:
"HumHub is currently in debug mode. Disable it when running on production!
See installation manual for more details."
It's possible to start without debug?

version 2.5

Hi,
I am trying to use your image on docker for synology. Version 1.0.1 works, but version 2.5 does not. I follow your quick start instructions, I get to the first configuration page, but when I click "next" the page remains stuck in loading and the log keeps recording the same message:

2018-05-10 04:50:03 stdout IP - - [10/May/2018:04:50:03 +0000] "GET /index.php?r=installer%2Findex&pjax=%23layout-content&=1525927784576 HTTP/1.1" 302 5 "http://local:port/index.php?r=installer%2Findex%2Fgo" "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_13_4) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/11.1 Safari/605.1.15" "-"
2018-05-10 04:50:03 stdout - -  10/May/2018:04:50:03 +0000 "GET /index.php" 302

This happens with Chorme and with Safari as well.
Is there any known issue about this?

No install process, no default user

Hi. Thanks for your docker install. Trying to get it running but when accessing via browser I get requested to login. I thought an installation process should start and can't guess the default user and password.
image

Chrome Firefox issues

from #20:

Dunno if it is humhub itself related or not:
FireFox and Chrome don't work they remain stuck on the first step.
While IE works it returns to start pretty much after every 2 steps orso.

I was able to reproduce the issue, but got no clue what causes this problem. Can someone check against a "non-docker" humhub installation?

Missing features for production ?

From the README:

Using this in production is possible, but not recommended

so, I would like to know what are your specific thoughts about what's missing to use this docker image in production ?
Also, would you like some help to make it production ready ?

config-dir permissions problem on windows

After updating Docker (for Windows) to 17.09.1 setting permissions on a host-mounted config volume is no longer possible. Therefor the installer is failing and normal usage of this image is not possible.

Currently the only known workaround is to not specify a volume and therefor use the MobyLinux FS on the volume. I hope that there is some clean solution to this problem. If someone can provide some information on this topic, please comment to this issue.

Running on ARMv7 - No MySQL, run with postgres db?

I want to build from your repository and run on ARMv7.

Useful Information

pi@naspi:~/rpi4_server $ cat /proc/device-tree/model
Raspberry Pi 4 Model B Rev 1.1
pi@naspi:~/rpi4_server $ uname -a 
Linux naspi 5.4.51-v7l+ #1333 SMP Mon Aug 10 16:51:40 BST 2020 armv7l GNU/Linux
pi@naspi:~/rpi4_server $ lsb_release -a
No LSB modules are available.
Distributor ID: Raspbian
Description:    Raspbian GNU/Linux 10 (buster)
Release:        10
Codename:       buster
pi@naspi:~/rpi4_server $ docker --version
Docker version 19.03.13, build 4484c46
pi@naspi:~/rpi4_server $ docker-compose --version
docker-compose version 1.27.4, build unknown

Build steps

Only the docker for amd64 is available, so we have to build locally.

Building from docker-compose

Local build fails if done from compose file, using the default compose file.

version: "3.8"
services:
  humhub:
    image: fremmen/humhub:armv7
    build: https://github.com/mriedmann/humhub-docker.git
    ...
docker-compose build humhub

Building locally

git clone https://github.com/mriedmann/humhub-docker
cd humhub-docker
docker build . --network host -t fremmen/humhub:armv7

The option --network host was added due to a npm install error - getaddrinfo EAI_AGAIN showing up without it and following this issue. The build succeeds.

Running

Humhub requires a database, but there is no MySQL docker for armv7.
I tried the following setup:

version: "3.8"
services:
  humhub:
    image: fremmen/humhub:armv7
    ## Docker-compose build humhub does not work due to 
    #     npm install error - getaddrinfo EAI_AGAIN
    # build locally by
    # git clone https://github.com/mriedmann/humhub-docker.git && cd humhub-docker
    # docker build . --network host -t fremmen/humhub:armv7
    build: https://github.com/mriedmann/humhub-docker.git
    links:
      - "humhubdb:db"
    ports:
      - "${HUMHUB_PORT}:80"
    volumes:
      - ${APPDATA_ROOT}/humhub/config:/var/www/localhost/htdocs/protected/config
      - ${APPDATA_ROOT}/humhub/uploads:/var/www/localhost/htdocs/uploads
      - ${APPDATA_ROOT}/humhub/modules:/var/www/localhost/htdocs/protected/modules
    environment:
      - HUMHUB_DB_HOST=humhubdb
      - HUMHUB_DB_NAME=humhub
      - HUMHUB_DB_USER=humhub
      - HUMHUB_DB_PASSWORD=${HUMHUB_DB_ROOT_PW}
    depends_on:
      - humhubdb
  humhubdb:
    image: postgres:alpine
    restart: unless-stopped
    volumes:
      - humhub_db:/var/lib/postgresql/data
    environment:
      - PUID=${PUID}
      - PGID=${PGID}
      - TZ=${TIMEZONE}
      - POSTGRES_DB=humhub
      - POSTGRES_USER=humhub
      - POSTGRES_PASSWORD=${HUMHUB_DB_ROOT_PW}
    ports:
      - "${HUMHUB_DB_PORT}:5432"
volumes:
  humhub_db:

But I get the following message

humhub       | Waiting for database connection...

Is postgres not supported? What can I do to get it working with armv7?

PHP Config not enough for big files upload

Hi,
I tried to set PHP_POST_MAX_SIZE and PHP_UPLOAD_MAX_FILESIZE, in order to upload bigger files on humhub, but it resulted in a "413 Entity too large" http error.

To fix this error, i modified the nginx.conf file, setting
client_max_body_size 1024m;
and recompiled the container

In order to avoid reconpilation, could this setting be parametrized with PHP_POST_MAX_SIZE too?

Best regards
Mauro

Security Alert

mriedmann/humhub:latest (alpine 3.12.0)

Title Severity CVE Package Name Installed Version Fixed Version References
libxml2: Buffer Overflow vulnerability in xmlEncodeEntitiesInternal at libxml2/entities.c HIGH CVE-2020-24977 libxml2 2.9.10-r4 2.9.10-r5 http://lists.opensuse.org/opensuse-security-announce/2020-09/msg00036.html
https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2020-24977
https://gitlab.gnome.org/GNOME/libxml2/-/issues/178
https://lists.debian.org/debian-lts-announce/2020/09/msg00009.html
https://lists.fedoraproject.org/archives/list/[email protected]/message/2NQ5GTDYOVH26PBCPYXXMGW5ZZXWMGZC/

var/www/localhost/htdocs/composer.lock

Title Severity CVE Package Name Installed Version Fixed Version References
Unsafe deserialization in Yii 2 HIGH CVE-2020-15148 yiisoft/yii2 2.0.36 2.0.38 GHSA-699q-wcff-g9mj
yiisoft/yii2@9abccb9
GHSA-699q-wcff-g9mj
https://nvd.nist.gov/vuln/detail/CVE-2020-15148

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.