From cbc337f849e76dbdaed5b9b95a020cbf94a3d422 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tim=20D=C3=BCsterhus?= Date: Sun, 16 Apr 2017 22:09:08 +0200 Subject: [PATCH] Update adminer/content.md This introduces sections for the plugin and design support. --- adminer/content.md | 38 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 38 insertions(+) diff --git a/adminer/content.md b/adminer/content.md index 0267a0f36..51eda4286 100644 --- a/adminer/content.md +++ b/adminer/content.md @@ -26,6 +26,44 @@ Then point your web server to port 9000 of the container. Note: This exposes the FastCGI socket to the Internet. Make sure to add proper firewall rules or use a private Docker network instead to prevent a direct access. +### Loading plugins + +This image bundles all official adminer plugins. You can find the list of plugins on GitHub: https://github.com/vrana/adminer/tree/master/plugins. + +To load plugins you can pass a list of filenames in `ADMINER_PLUGINS`: + + $ docker run --link some_database:db -p 8080:8080 -e ADMINER_PLUGINS='tables-filter tinymce' adminer + +If a plugin *requires* parameters to work correctly you will need to add a custom file to the container: + + $ docker run --link some_database:db -p 8080:8080 -e ADMINER_PLUGINS='login-servers' adminer + Unable to load plugin file "login-servers", because it has required parameters: servers + Create a file "/var/www/html/plugins-enabled/login-servers.php" with the following contents to load the plugin: + + $description) or array($category => array()) + * @param string + */ + return new AdminerLoginServers( + $servers = ???, + $driver = 'server' + ); + +To load a custom plugin you can add PHP scripts that return the instance of the plugin object to `/var/www/html/plugins-enabled/`. + +### Choosing a design + +The image bundles all the designs that are available in the source package of adminer. You can find the list of designs on GitHub: https://github.com/vrana/adminer/tree/master/designs. + +To use a bundled design you can pass its name in `ADMINER_DESIGN`: + + $ docker run --link some_database:db -p 8080:8080 -e ADMINER_DESIGN='nette' adminer + +To use a custom design you can add a file called `/var/www/html/adminer.css`. + ## Supported Drivers While Adminer supports a wide range of database drivers this image only supports the following out of the box: