These are some guides for various use.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

152 lines
4.2 KiB

7 months ago
7 months ago
7 months ago
7 months ago
7 months ago
7 months ago
7 months ago
7 months ago
7 months ago
7 months ago
7 months ago
7 months ago
7 months ago
7 months ago
7 months ago
7 months ago
7 months ago
7 months ago
7 months ago
  1. # Owncloud
  2. ## Setup Server
  3. ### Docker
  4. The official container and documentation was made by [owncloud](https://hub.docker.com/_/owncloud).
  5. This docker-rebuild is made up by a `docker-compose.yml` file.
  6. The services in this files are explained seperately.
  7. #### Owncloud
  8. ##### Volumes
  9. Set the following volumes in the `volumes:` section of the docker-compose file.
  10. | Volume-Name | Container mount | Description |
  11. | ----------- | ---------------------- | ---------------------------- |
  12. | `owncloud` | `/var/www/html` | storage for owncloud plugins |
  13. | `config` | `/var/www/html/config` | storage for owncloud config |
  14. ##### Ports
  15. Set the following ports in the `ports:` section.
  16. | Container Port | Recommended outside port | Protocol | Description |
  17. | -------------- | ------------------------ | -------- | ----------- |
  18. | `80` | `80` | TCP | WebUI |
  19. #### Maria DB
  20. ##### Environment-variables
  21. Set the following environment-variables in the `environment:` section of the
  22. docker-compose file.
  23. | Name | Usage | Default |
  24. | --------------------- | ---------------------------- | ------- |
  25. | `MYSQL_ROOT_PASSWORD` | set the mysql admin password | |
  26. ##### Volumes
  27. Set the following volumes in the `volumes:` section of the docker-compose file.
  28. | Volume-Name | Container mount | Description |
  29. | ----------- | ---------------- | ------------------------- |
  30. | `mariadb` | `/var/lib/mysql` | storage for owncloud data |
  31. #### Rebuild
  32. ```shell
  33. #!/bin/sh
  34. docker-compose down
  35. docker pull owncloud
  36. docker pull mariadb
  37. docker-compose up -d
  38. ```
  39. #### Docker-Compose.yml
  40. ```yml
  41. version: "3.1"
  42. services:
  43. owncloud:
  44. image: owncloud
  45. restart: unless-stopped
  46. ports:
  47. - 80:80
  48. volumes:
  49. - owncloud:/var/www/html
  50. - config:/var/www/html/config
  51. mariadb:
  52. image: mariadb
  53. restart: unless-stopped
  54. environment:
  55. MYSQL_ROOT_PASSWORD: pass
  56. volumes:
  57. - mariadb:/var/lib/mysql
  58. volumes:
  59. owncloud:
  60. driver: local
  61. mariadb:
  62. driver: local
  63. config:
  64. driver: local
  65. ```
  66. ## Setup Client
  67. ### Docker
  68. The original container and documentation are made by [tiynger](https://hub.docker.com/r/tiynger/owncloudclient)
  69. #### Environment-variables
  70. Set the following variables with the -e tag.
  71. | Name | Usage | Default |
  72. | ---------- | --------------------------------------------------- | ----------- |
  73. | `USER` | username of OwnCloud server | `admin` |
  74. | `PASSWORD` | password of OwnCloud server | `admin` |
  75. | `URL` | url of OwnCloud server (dont forget the http(s)://) | `localhost` |
  76. #### Additional
  77. There are some special variables to set.
  78. | Flag | Usage |
  79. | -------------------- | ---------------------------------------------------------- |
  80. | `--opt-log max-size` | prevent log file from growing to large (`50m` recommended) |
  81. #### Volumes
  82. Set the following volumes with the -v tag.
  83. | Volume-Name | Container mount | Description |
  84. | ----------- | --------------- | ----------------------------------- |
  85. | `data` | `/data` | directory for the owncloud contents |
  86. #### Rebuild
  87. ```shell
  88. #!/bin/sh
  89. docker stop owncloudcli
  90. docker rm owncloudcli
  91. docker pull tiynger/owncloudclient
  92. docker run --name owncloudcli \
  93. --restart unless-stopped \
  94. -v owncloudcli:/data \
  95. -e USER='user' \
  96. -e PASSWORD='password' \
  97. -e URL='https://subdomain.domain.tld' \
  98. --log-opt max-size=50m \
  99. -d tiynger/owncloudclient
  100. ```
  101. ## Error handling
  102. ### Problems with a locked file
  103. It is possible that you can't remove or move a locked file.
  104. If this problem doesn't resolve after a restart you can try to disable locking
  105. in the owncloud config.
  106. This is done by adding the line `'filelocking.enabled' => false,` into the file `config/config.php`.
  107. Then try to resolve the error.
  108. Afterwards enable locking again by removing the added line.
  109. The reason I choose this process over editing the database file, is ease of use.
  110. The editing of the database is much more time consuming especially if run with docker.