mirror of
https://github.com/nextcloud/docker.git
synced 2025-07-27 09:08:04 +02:00
Compare commits
5 commits
917b9526e4
...
f7b5eab902
Author | SHA1 | Date | |
---|---|---|---|
|
f7b5eab902 | ||
|
29d959acfd | ||
|
d3341b61c1 | ||
|
0ee77f1a92 | ||
|
53c3162c83 |
11 changed files with 46 additions and 21 deletions
|
@ -14,8 +14,8 @@ if (getenv('OBJECTSTORE_S3_BUCKET')) {
|
||||||
'port' => getenv('OBJECTSTORE_S3_PORT') ?: '',
|
'port' => getenv('OBJECTSTORE_S3_PORT') ?: '',
|
||||||
'storageClass' => getenv('OBJECTSTORE_S3_STORAGE_CLASS') ?: '',
|
'storageClass' => getenv('OBJECTSTORE_S3_STORAGE_CLASS') ?: '',
|
||||||
'objectPrefix' => getenv("OBJECTSTORE_S3_OBJECT_PREFIX") ? getenv("OBJECTSTORE_S3_OBJECT_PREFIX") : "urn:oid:",
|
'objectPrefix' => getenv("OBJECTSTORE_S3_OBJECT_PREFIX") ? getenv("OBJECTSTORE_S3_OBJECT_PREFIX") : "urn:oid:",
|
||||||
'autocreate' => (strtolower($autocreate) === 'false' || $autocreate == false) ? false : true,
|
'autocreate' => strtolower($autocreate) !== 'false',
|
||||||
'use_ssl' => (strtolower($use_ssl) === 'false' || $use_ssl == false) ? false : true,
|
'use_ssl' => strtolower($use_ssl) !== 'false',
|
||||||
// required for some non Amazon S3 implementations
|
// required for some non Amazon S3 implementations
|
||||||
'use_path_style' => $use_path == true && strtolower($use_path) !== 'false',
|
'use_path_style' => $use_path == true && strtolower($use_path) !== 'false',
|
||||||
// required for older protocol versions
|
// required for older protocol versions
|
||||||
|
|
|
@ -14,8 +14,8 @@ if (getenv('OBJECTSTORE_S3_BUCKET')) {
|
||||||
'port' => getenv('OBJECTSTORE_S3_PORT') ?: '',
|
'port' => getenv('OBJECTSTORE_S3_PORT') ?: '',
|
||||||
'storageClass' => getenv('OBJECTSTORE_S3_STORAGE_CLASS') ?: '',
|
'storageClass' => getenv('OBJECTSTORE_S3_STORAGE_CLASS') ?: '',
|
||||||
'objectPrefix' => getenv("OBJECTSTORE_S3_OBJECT_PREFIX") ? getenv("OBJECTSTORE_S3_OBJECT_PREFIX") : "urn:oid:",
|
'objectPrefix' => getenv("OBJECTSTORE_S3_OBJECT_PREFIX") ? getenv("OBJECTSTORE_S3_OBJECT_PREFIX") : "urn:oid:",
|
||||||
'autocreate' => (strtolower($autocreate) === 'false' || $autocreate == false) ? false : true,
|
'autocreate' => strtolower($autocreate) !== 'false',
|
||||||
'use_ssl' => (strtolower($use_ssl) === 'false' || $use_ssl == false) ? false : true,
|
'use_ssl' => strtolower($use_ssl) !== 'false',
|
||||||
// required for some non Amazon S3 implementations
|
// required for some non Amazon S3 implementations
|
||||||
'use_path_style' => $use_path == true && strtolower($use_path) !== 'false',
|
'use_path_style' => $use_path == true && strtolower($use_path) !== 'false',
|
||||||
// required for older protocol versions
|
// required for older protocol versions
|
||||||
|
|
|
@ -14,8 +14,8 @@ if (getenv('OBJECTSTORE_S3_BUCKET')) {
|
||||||
'port' => getenv('OBJECTSTORE_S3_PORT') ?: '',
|
'port' => getenv('OBJECTSTORE_S3_PORT') ?: '',
|
||||||
'storageClass' => getenv('OBJECTSTORE_S3_STORAGE_CLASS') ?: '',
|
'storageClass' => getenv('OBJECTSTORE_S3_STORAGE_CLASS') ?: '',
|
||||||
'objectPrefix' => getenv("OBJECTSTORE_S3_OBJECT_PREFIX") ? getenv("OBJECTSTORE_S3_OBJECT_PREFIX") : "urn:oid:",
|
'objectPrefix' => getenv("OBJECTSTORE_S3_OBJECT_PREFIX") ? getenv("OBJECTSTORE_S3_OBJECT_PREFIX") : "urn:oid:",
|
||||||
'autocreate' => (strtolower($autocreate) === 'false' || $autocreate == false) ? false : true,
|
'autocreate' => strtolower($autocreate) !== 'false',
|
||||||
'use_ssl' => (strtolower($use_ssl) === 'false' || $use_ssl == false) ? false : true,
|
'use_ssl' => strtolower($use_ssl) !== 'false',
|
||||||
// required for some non Amazon S3 implementations
|
// required for some non Amazon S3 implementations
|
||||||
'use_path_style' => $use_path == true && strtolower($use_path) !== 'false',
|
'use_path_style' => $use_path == true && strtolower($use_path) !== 'false',
|
||||||
// required for older protocol versions
|
// required for older protocol versions
|
||||||
|
|
|
@ -14,8 +14,8 @@ if (getenv('OBJECTSTORE_S3_BUCKET')) {
|
||||||
'port' => getenv('OBJECTSTORE_S3_PORT') ?: '',
|
'port' => getenv('OBJECTSTORE_S3_PORT') ?: '',
|
||||||
'storageClass' => getenv('OBJECTSTORE_S3_STORAGE_CLASS') ?: '',
|
'storageClass' => getenv('OBJECTSTORE_S3_STORAGE_CLASS') ?: '',
|
||||||
'objectPrefix' => getenv("OBJECTSTORE_S3_OBJECT_PREFIX") ? getenv("OBJECTSTORE_S3_OBJECT_PREFIX") : "urn:oid:",
|
'objectPrefix' => getenv("OBJECTSTORE_S3_OBJECT_PREFIX") ? getenv("OBJECTSTORE_S3_OBJECT_PREFIX") : "urn:oid:",
|
||||||
'autocreate' => (strtolower($autocreate) === 'false' || $autocreate == false) ? false : true,
|
'autocreate' => strtolower($autocreate) !== 'false',
|
||||||
'use_ssl' => (strtolower($use_ssl) === 'false' || $use_ssl == false) ? false : true,
|
'use_ssl' => strtolower($use_ssl) !== 'false',
|
||||||
// required for some non Amazon S3 implementations
|
// required for some non Amazon S3 implementations
|
||||||
'use_path_style' => $use_path == true && strtolower($use_path) !== 'false',
|
'use_path_style' => $use_path == true && strtolower($use_path) !== 'false',
|
||||||
// required for older protocol versions
|
// required for older protocol versions
|
||||||
|
|
|
@ -14,8 +14,8 @@ if (getenv('OBJECTSTORE_S3_BUCKET')) {
|
||||||
'port' => getenv('OBJECTSTORE_S3_PORT') ?: '',
|
'port' => getenv('OBJECTSTORE_S3_PORT') ?: '',
|
||||||
'storageClass' => getenv('OBJECTSTORE_S3_STORAGE_CLASS') ?: '',
|
'storageClass' => getenv('OBJECTSTORE_S3_STORAGE_CLASS') ?: '',
|
||||||
'objectPrefix' => getenv("OBJECTSTORE_S3_OBJECT_PREFIX") ? getenv("OBJECTSTORE_S3_OBJECT_PREFIX") : "urn:oid:",
|
'objectPrefix' => getenv("OBJECTSTORE_S3_OBJECT_PREFIX") ? getenv("OBJECTSTORE_S3_OBJECT_PREFIX") : "urn:oid:",
|
||||||
'autocreate' => (strtolower($autocreate) === 'false' || $autocreate == false) ? false : true,
|
'autocreate' => strtolower($autocreate) !== 'false',
|
||||||
'use_ssl' => (strtolower($use_ssl) === 'false' || $use_ssl == false) ? false : true,
|
'use_ssl' => strtolower($use_ssl) !== 'false',
|
||||||
// required for some non Amazon S3 implementations
|
// required for some non Amazon S3 implementations
|
||||||
'use_path_style' => $use_path == true && strtolower($use_path) !== 'false',
|
'use_path_style' => $use_path == true && strtolower($use_path) !== 'false',
|
||||||
// required for older protocol versions
|
// required for older protocol versions
|
||||||
|
|
|
@ -14,8 +14,8 @@ if (getenv('OBJECTSTORE_S3_BUCKET')) {
|
||||||
'port' => getenv('OBJECTSTORE_S3_PORT') ?: '',
|
'port' => getenv('OBJECTSTORE_S3_PORT') ?: '',
|
||||||
'storageClass' => getenv('OBJECTSTORE_S3_STORAGE_CLASS') ?: '',
|
'storageClass' => getenv('OBJECTSTORE_S3_STORAGE_CLASS') ?: '',
|
||||||
'objectPrefix' => getenv("OBJECTSTORE_S3_OBJECT_PREFIX") ? getenv("OBJECTSTORE_S3_OBJECT_PREFIX") : "urn:oid:",
|
'objectPrefix' => getenv("OBJECTSTORE_S3_OBJECT_PREFIX") ? getenv("OBJECTSTORE_S3_OBJECT_PREFIX") : "urn:oid:",
|
||||||
'autocreate' => (strtolower($autocreate) === 'false' || $autocreate == false) ? false : true,
|
'autocreate' => strtolower($autocreate) !== 'false',
|
||||||
'use_ssl' => (strtolower($use_ssl) === 'false' || $use_ssl == false) ? false : true,
|
'use_ssl' => strtolower($use_ssl) !== 'false',
|
||||||
// required for some non Amazon S3 implementations
|
// required for some non Amazon S3 implementations
|
||||||
'use_path_style' => $use_path == true && strtolower($use_path) !== 'false',
|
'use_path_style' => $use_path == true && strtolower($use_path) !== 'false',
|
||||||
// required for older protocol versions
|
// required for older protocol versions
|
||||||
|
|
|
@ -14,8 +14,8 @@ if (getenv('OBJECTSTORE_S3_BUCKET')) {
|
||||||
'port' => getenv('OBJECTSTORE_S3_PORT') ?: '',
|
'port' => getenv('OBJECTSTORE_S3_PORT') ?: '',
|
||||||
'storageClass' => getenv('OBJECTSTORE_S3_STORAGE_CLASS') ?: '',
|
'storageClass' => getenv('OBJECTSTORE_S3_STORAGE_CLASS') ?: '',
|
||||||
'objectPrefix' => getenv("OBJECTSTORE_S3_OBJECT_PREFIX") ? getenv("OBJECTSTORE_S3_OBJECT_PREFIX") : "urn:oid:",
|
'objectPrefix' => getenv("OBJECTSTORE_S3_OBJECT_PREFIX") ? getenv("OBJECTSTORE_S3_OBJECT_PREFIX") : "urn:oid:",
|
||||||
'autocreate' => (strtolower($autocreate) === 'false' || $autocreate == false) ? false : true,
|
'autocreate' => strtolower($autocreate) !== 'false',
|
||||||
'use_ssl' => (strtolower($use_ssl) === 'false' || $use_ssl == false) ? false : true,
|
'use_ssl' => strtolower($use_ssl) !== 'false',
|
||||||
// required for some non Amazon S3 implementations
|
// required for some non Amazon S3 implementations
|
||||||
'use_path_style' => $use_path == true && strtolower($use_path) !== 'false',
|
'use_path_style' => $use_path == true && strtolower($use_path) !== 'false',
|
||||||
// required for older protocol versions
|
// required for older protocol versions
|
||||||
|
|
|
@ -14,8 +14,8 @@ if (getenv('OBJECTSTORE_S3_BUCKET')) {
|
||||||
'port' => getenv('OBJECTSTORE_S3_PORT') ?: '',
|
'port' => getenv('OBJECTSTORE_S3_PORT') ?: '',
|
||||||
'storageClass' => getenv('OBJECTSTORE_S3_STORAGE_CLASS') ?: '',
|
'storageClass' => getenv('OBJECTSTORE_S3_STORAGE_CLASS') ?: '',
|
||||||
'objectPrefix' => getenv("OBJECTSTORE_S3_OBJECT_PREFIX") ? getenv("OBJECTSTORE_S3_OBJECT_PREFIX") : "urn:oid:",
|
'objectPrefix' => getenv("OBJECTSTORE_S3_OBJECT_PREFIX") ? getenv("OBJECTSTORE_S3_OBJECT_PREFIX") : "urn:oid:",
|
||||||
'autocreate' => (strtolower($autocreate) === 'false' || $autocreate == false) ? false : true,
|
'autocreate' => strtolower($autocreate) !== 'false',
|
||||||
'use_ssl' => (strtolower($use_ssl) === 'false' || $use_ssl == false) ? false : true,
|
'use_ssl' => strtolower($use_ssl) !== 'false',
|
||||||
// required for some non Amazon S3 implementations
|
// required for some non Amazon S3 implementations
|
||||||
'use_path_style' => $use_path == true && strtolower($use_path) !== 'false',
|
'use_path_style' => $use_path == true && strtolower($use_path) !== 'false',
|
||||||
// required for older protocol versions
|
// required for older protocol versions
|
||||||
|
|
|
@ -14,8 +14,8 @@ if (getenv('OBJECTSTORE_S3_BUCKET')) {
|
||||||
'port' => getenv('OBJECTSTORE_S3_PORT') ?: '',
|
'port' => getenv('OBJECTSTORE_S3_PORT') ?: '',
|
||||||
'storageClass' => getenv('OBJECTSTORE_S3_STORAGE_CLASS') ?: '',
|
'storageClass' => getenv('OBJECTSTORE_S3_STORAGE_CLASS') ?: '',
|
||||||
'objectPrefix' => getenv("OBJECTSTORE_S3_OBJECT_PREFIX") ? getenv("OBJECTSTORE_S3_OBJECT_PREFIX") : "urn:oid:",
|
'objectPrefix' => getenv("OBJECTSTORE_S3_OBJECT_PREFIX") ? getenv("OBJECTSTORE_S3_OBJECT_PREFIX") : "urn:oid:",
|
||||||
'autocreate' => (strtolower($autocreate) === 'false' || $autocreate == false) ? false : true,
|
'autocreate' => strtolower($autocreate) !== 'false',
|
||||||
'use_ssl' => (strtolower($use_ssl) === 'false' || $use_ssl == false) ? false : true,
|
'use_ssl' => strtolower($use_ssl) !== 'false',
|
||||||
// required for some non Amazon S3 implementations
|
// required for some non Amazon S3 implementations
|
||||||
'use_path_style' => $use_path == true && strtolower($use_path) !== 'false',
|
'use_path_style' => $use_path == true && strtolower($use_path) !== 'false',
|
||||||
// required for older protocol versions
|
// required for older protocol versions
|
||||||
|
|
|
@ -14,8 +14,8 @@ if (getenv('OBJECTSTORE_S3_BUCKET')) {
|
||||||
'port' => getenv('OBJECTSTORE_S3_PORT') ?: '',
|
'port' => getenv('OBJECTSTORE_S3_PORT') ?: '',
|
||||||
'storageClass' => getenv('OBJECTSTORE_S3_STORAGE_CLASS') ?: '',
|
'storageClass' => getenv('OBJECTSTORE_S3_STORAGE_CLASS') ?: '',
|
||||||
'objectPrefix' => getenv("OBJECTSTORE_S3_OBJECT_PREFIX") ? getenv("OBJECTSTORE_S3_OBJECT_PREFIX") : "urn:oid:",
|
'objectPrefix' => getenv("OBJECTSTORE_S3_OBJECT_PREFIX") ? getenv("OBJECTSTORE_S3_OBJECT_PREFIX") : "urn:oid:",
|
||||||
'autocreate' => (strtolower($autocreate) === 'false' || $autocreate == false) ? false : true,
|
'autocreate' => strtolower($autocreate) !== 'false',
|
||||||
'use_ssl' => (strtolower($use_ssl) === 'false' || $use_ssl == false) ? false : true,
|
'use_ssl' => strtolower($use_ssl) !== 'false',
|
||||||
// required for some non Amazon S3 implementations
|
// required for some non Amazon S3 implementations
|
||||||
'use_path_style' => $use_path == true && strtolower($use_path) !== 'false',
|
'use_path_style' => $use_path == true && strtolower($use_path) !== 'false',
|
||||||
// required for older protocol versions
|
// required for older protocol versions
|
||||||
|
|
27
README.md
27
README.md
|
@ -87,13 +87,38 @@ If you want to use named volumes for all of these, it would look like this:
|
||||||
```console
|
```console
|
||||||
$ docker run -d \
|
$ docker run -d \
|
||||||
-v nextcloud:/var/www/html \
|
-v nextcloud:/var/www/html \
|
||||||
-v apps:/var/www/html/custom_apps \
|
-v custom_apps:/var/www/html/custom_apps \
|
||||||
-v config:/var/www/html/config \
|
-v config:/var/www/html/config \
|
||||||
-v data:/var/www/html/data \
|
-v data:/var/www/html/data \
|
||||||
-v theme:/var/www/html/themes/<YOUR_CUSTOM_THEME> \
|
-v theme:/var/www/html/themes/<YOUR_CUSTOM_THEME> \
|
||||||
nextcloud
|
nextcloud
|
||||||
```
|
```
|
||||||
|
|
||||||
|
If you'd prefer to use bind mounts instead of named volumes, for instance, when working with different device or network mounts for user data files and configuration:
|
||||||
|
```console
|
||||||
|
$ docker run -d \
|
||||||
|
-v $(pwd)/nextcloud:/var/www/html \
|
||||||
|
-v $(pwd)/custom_apps:/var/www/html/custom_apps \
|
||||||
|
-v $(pwd)/config:/var/www/html/config \
|
||||||
|
-v $(pwd)/data:/var/www/html/data \
|
||||||
|
-v $(pwd)/theme:/var/www/html/themes/<YOUR_CUSTOM_THEME> \
|
||||||
|
nextcloud
|
||||||
|
```
|
||||||
|
|
||||||
|
Here’s the same example using Docker's more detailed `--mount`. Note that with `-v` or `--volume`, the specified folders are created automatically if they don't exist. However, when using `--mount` for bind mounts, the directories must already exist on the host, or Docker will return an error.
|
||||||
|
```console
|
||||||
|
$ docker run -d \
|
||||||
|
--mount type=bind,source=$(pwd)/nextcloud,target=/var/www/html \
|
||||||
|
--mount type=bind,source=$(pwd)/custom_apps,target=/var/www/html/custom_apps \
|
||||||
|
--mount type=bind,source=$(pwd)/config,target=/var/www/html/config \
|
||||||
|
--mount type=bind,source=$(pwd)/data,target=/var/www/html/data \
|
||||||
|
--mount type=bind,source=$(pwd)/theme,target=/var/www/html/themes/<YOUR_CUSTOM_THEME> \
|
||||||
|
nextcloud
|
||||||
|
```
|
||||||
|
The examples above use the current directory for bind mounts. If this isn't suitable, you can modify the paths by using either a relative or absolute path.
|
||||||
|
|
||||||
|
NOTE: Do not confuse the `apps` and `custom_apps` folders. These folders contain different sets of apps, and mixing them will result in a broken installation. The former contains "shipped" apps, which come with Nextcloud Server. The latter contains apps you install from the App Store.
|
||||||
|
|
||||||
### Custom volumes
|
### Custom volumes
|
||||||
|
|
||||||
If mounting additional volumes under `/var/www/html`, you should consider:
|
If mounting additional volumes under `/var/www/html`, you should consider:
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue