Commit Graph

68 Commits

Author SHA1 Message Date
J0WI 0e725c6fa5
Revert "update docker-entrypoint.sh" (#2175) 2024-03-04 21:00:00 +00:00
Simon L e869267b20 update docker-entrypoint.sh
Signed-off-by: Simon L <szaimen@e.mail.de>
2024-02-05 11:52:18 +01:00
Yevhen Kolomeiko d89def24d1
Fix for PR #2095 breaking post-installation scripts in k8s (#2115)
* Fix docker-entrypoint.sh

Signed-off-by: Yevhen Kolomeiko <Jarvis2709@gmail.com>

* Fix docker-entrypoint.sh for alpine

Signed-off-by: Yevhen Kolomeiko <Jarvis2709@gmail.com>

* Use '-o' instead of two find's in docker-entrypoint.sh

Signed-off-by: Yevhen Kolomeiko <Jarvis2709@gmail.com>

* Use more laconic find parameters set in docker-entrypoint.sh

Signed-off-by: Yevhen Kolomeiko <Jarvis2709@gmail.com>

---------

Signed-off-by: Yevhen Kolomeiko <Jarvis2709@gmail.com>
2024-01-09 22:31:39 +00:00
Dennis Værum 23d099bc33
Bug fix: not found error if hook folder contains files but non ending with `*.sh` (#2095)
* Use `find` to located `*.sh`

Signed-off-by: Dennis Vestergaard Værum <github@varum.dk>

* added msg if hook folder does not exist

Signed-off-by: Dennis Vestergaard Værum <github@varum.dk>

* Updated info message

Co-authored-by: J0WI <J0WI@users.noreply.github.com>
Signed-off-by: Dennis Værum <6872940+dvaerum@users.noreply.github.com>

* Update docker-entrypoint.sh

Small adjustments

Signed-off-by: Dennis Værum <6872940+dvaerum@users.noreply.github.com>

---------

Signed-off-by: Dennis Vestergaard Værum <github@varum.dk>
Signed-off-by: Dennis Værum <6872940+dvaerum@users.noreply.github.com>
Co-authored-by: J0WI <J0WI@users.noreply.github.com>
2023-11-14 23:11:10 +00:00
Antonin Delpeuch a68c6ef348
Block upgrade if it is not supported because major versions are too different (#2018)
* Block upgrade if it is not supported

Closes #1809. This prevents the install from getting in a state where none
of the Docker images will accept running given the contents of the volumes.

Signed-off-by: Antonin Delpeuch <antonin@delpeuch.eu>

* Update docker-entrypoint.sh

Co-authored-by: J0WI <J0WI@users.noreply.github.com>
Signed-off-by: Antonin Delpeuch <antonin@delpeuch.eu>

* Update docker-entrypoint.sh

Co-authored-by: J0WI <J0WI@users.noreply.github.com>
Signed-off-by: Antonin Delpeuch <antonin@delpeuch.eu>

* Remove extra function

Signed-off-by: Antonin Delpeuch <antonin@delpeuch.eu>

* Update docker-entrypoint.sh

Co-authored-by: J0WI <J0WI@users.noreply.github.com>
Signed-off-by: Antonin Delpeuch <antonin@delpeuch.eu>

---------

Signed-off-by: Antonin Delpeuch <antonin@delpeuch.eu>
Co-authored-by: J0WI <J0WI@users.noreply.github.com>
2023-07-09 20:20:10 +00:00
Dennis Værum d3251467e6
Added entrypoint hooks for your own custom scripts (#1964)
* Added entrypoint hooks for your own custom scripts

Signed-off-by: Dennis Vestergaard Værum <github@varum.dk>

* Small changes:
- Only execute shell-scripts (mening files ending with .sh)
- Sort the files before executing them, had forgotten 😅
- Added a message when a hook script finish
- Added prefix arror to message to show the are related

Signed-off-by: Dennis Vestergaard Værum <github@varum.dk>

* Show in the search msg that it only searches for '*.sh' files

Signed-off-by: Dennis Vestergaard Værum <github@varum.dk>

* Fixed spelling mistake

Co-authored-by: J0WI <J0WI@users.noreply.github.com>
Signed-off-by: Dennis Værum <6872940+dvaerum@users.noreply.github.com>

* Updated the `README.md` file

Signed-off-by: Dennis Vestergaard Værum <github@varum.dk>

* change from using find to using a for-loop to located the `.sh` files

Signed-off-by: Dennis Vestergaard Værum <github@varum.dk>

* Fix bug - that would make docker-entrypoint.sh failed, hook folders was empty

Signed-off-by: Dennis Vestergaard Værum <github@varum.dk>

---------

Signed-off-by: Dennis Vestergaard Værum <github@varum.dk>
Signed-off-by: Dennis Værum <6872940+dvaerum@users.noreply.github.com>
Co-authored-by: J0WI <J0WI@users.noreply.github.com>
2023-06-22 16:06:37 +00:00
Remi Rampin 405e815285 Un-factor do_install_or_upgrade()
Signed-off-by: Remi Rampin <remi@rampin.org>
2023-02-08 14:05:08 -05:00
Remi Rampin 8aabc4b3ea Remove NEXTCLOUD_INIT_LOCK
Signed-off-by: Remi Rampin <remi@rampin.org>
2023-02-08 14:05:00 -05:00
Remi Rampin 4667cbe149 Use flock to lock the whole upgrade process
Signed-off-by: Remi Rampin <remi@rampin.org>
2023-01-27 11:08:06 -05:00
Remi Rampin df9653a00c Remove old locking logic
Signed-off-by: Remi Rampin <remi@rampin.org>
2023-01-27 11:08:04 -05:00
Remi Rampin 7a0aba93a2 Factor do_install_or_upgrade()
Signed-off-by: Remi Rampin <remi@rampin.org>
2023-01-27 11:07:43 -05:00
J0WI 24440af0d5
Enhance shell syntax (#1868)
Signed-off-by: J0WI <J0WI@users.noreply.github.com>

Signed-off-by: J0WI <J0WI@users.noreply.github.com>
2022-11-28 16:12:46 +00:00
MAbeeTT (Matías Pecchia) aa779c7c92
prevents running `occ maintenance:update:htaccess` on a first run volume (#1843)
Signed-off-by: Matías Pecchia <179218+mabeett@users.noreply.github.com>

Signed-off-by: Matías Pecchia <179218+mabeett@users.noreply.github.com>
2022-11-03 16:13:35 +00:00
J0WI 19256cdbf8
Allow to run with custom uid (#1812)
fix: #359, #772, #1081, #1087, #1278

Signed-off-by: J0WI <J0WI@users.noreply.github.com>

Signed-off-by: J0WI <J0WI@users.noreply.github.com>
2022-09-06 16:46:03 +00:00
John Molakvoæ 209d65d0b6
Add `NEXTCLOUD_INIT_HTACCESS` to run `occ maintenance:update:htaccess` after init (#1761)
Signed-off-by: John Molakvoæ <skjnldsv@protonmail.com>
2022-06-30 12:59:15 +00:00
John Molakvoæ 83d5e72596
Add `NEXTCLOUD_INIT_LOCK` to enable shared html volume update
Signed-off-by: John Molakvoæ <skjnldsv@protonmail.com>
2022-06-01 08:18:10 +02:00
J0WI 7a89d751ca
Limit until loop (#1741)
Signed-off-by: J0WI <J0WI@users.noreply.github.com>
2022-04-28 18:32:38 +00:00
John Molakvoæ 35b8ebf954 Allow simultaneous initialization of common html volume
Signed-off-by: John Molakvoæ <skjnldsv@protonmail.com>
2022-04-22 10:05:17 +02:00
Doncho N. Gunchev ababef74e9
Revert "Simplify first character check in entrypoint.sh (#1679)" #1699 (#1701)
.In php:8.0-fpm-bullseye /bin/sh is dash, which does not support "${X:0:1}"
(substring expansion).

This reverts commit 0536522175.

Signed-off-by: Doncho N. Gunchev <dgunchev@gmail.com>
2022-02-18 18:28:09 +00:00
Doncho N. Gunchev 0536522175
Simplify first character check in entrypoint.sh (#1679)
Signed-off-by: Doncho N. Gunchev <dgunchev@gmail.com>
2022-02-08 18:43:35 +00:00
Michael Griego 9b057aafb0
Enable session locking for the redis session handler and use more sane locking configs. (#1364)
Signed-off-by: Mike Griego <mike@griegocentral.com>
2021-03-24 22:03:48 +00:00
KnallbertLp e2e521023f
enable usage of REDIS_HOST_PASSWORD_FILE (#1325) 2020-12-20 22:20:51 +00:00
J0WI 1e6d0620af Revert "Fix triggering install and update script (#1181)"
This reverts commit de90bed706.
2020-07-28 14:40:22 +02:00
stackcoder de90bed706
Fix triggering install and update script (#1181)
* Match cmd provided by Dockerfile again with entrypoint.sh

Signed-off-by: stackcoder <stackcoder@gmail.com>

* Fixup README.md

Signed-off-by: stackcoder <stackcoder@gmail.com>
2020-07-26 14:32:24 +00:00
J0WI 3ac6fde8d6
Remove db prefix option (#1131)
* Remove db prefix option

Signed-off-by: J0WI <J0WI@users.noreply.github.com>

* Upgrade to 18.0.6

Signed-off-by: J0WI <J0WI@users.noreply.github.com>
2020-06-09 13:26:33 +00:00
kesselb 63438ef792
Disable rewriteip for apache image (#1010)
* Disable rewrite ip for apache image

Signed-off-by: Daniel Kesselberg <mail@danielkesselberg.de>

* Run update.sh

Signed-off-by: Daniel Kesselberg <mail@danielkesselberg.de>
2020-04-06 20:44:58 +00:00
Boris Gorbylev efe3caebdc
Compatibility with docker secrets (#560)
* Read passwords from files specified with *_PASSWORD_FILE variables (docker secrets)

Fixes #731

Signed-off-by: Boris Gorbylev <ekho@ekho.name>
Signed-off-by: Jonas Thelemann <e-mail@jonas-thelemann.de>

* Add NEXTCLOUD_ADMIN_USER, POSTGRES_DB, POSTGRES_USER

Signed-off-by: Jonas Thelemann <e-mail@jonas-thelemann.de>

* Fix Variables

Signed-off-by: Jonas Thelemann <e-mail@jonas-thelemann.de>

Co-authored-by: Jonas Thelemann <e-mail@jonas-thelemann.de>
2020-03-31 14:23:57 +00:00
J0WI 13be446667
Change sleep time from 3s to 10s in all entrypoint.sh files (#963)
Signed-off-by: Nils Wittenbrink <nilswittenbrink@web.de>

Co-authored-by: Nils160988 <nilswittenbrink@web.de>
2020-01-13 18:10:28 +00:00
Tortue Torche d9ab30a969 Fix Redis Unix socket support (#944)
* Fix Redis Unix socket support

Rebase and rewrite the @epma01 pull request, based on last Nextcloud Docker changes
See: https://github.com/nextcloud/docker/pull/735

Signed-off-by: Tortue Torche <tortuetorche@users.noreply.github.com>

* Fix CI tests with update.sh script

Signed-off-by: Tortue Torche <tortuetorche@users.noreply.github.com>
2020-01-10 23:38:38 +00:00
algakzru 73ff5c860d Set redis password (#856) 2019-09-10 02:31:16 +02:00
J0WI a87f914de3 Avoid empty table prefix
Signed-off-by: J0WI <J0WI@users.noreply.github.com>
2019-06-22 18:22:15 +02:00
Tilo Spannagel f0fd46a989 Revert "Compatibility with docker secrets (Fix #560)"
[skip travis]

Signed-off-by: Tilo Spannagel <development@tilosp.de>
2019-04-30 13:06:03 +02:00
J0WI 343169d233 Compatibility with docker secrets (Fix #560)
Signed-off-by: J0WI <J0WI@users.noreply.github.com>
2019-04-29 14:59:35 +02:00
J0WI 83ea69d54b Add Redis session handler
Signed-off-by: J0WI <J0WI@users.noreply.github.com>
2019-04-26 15:49:59 +02:00
Tilo Spannagel 9c769f4ffc
Copy version.php last
Signed-off-by: Tilo Spannagel <development@tilosp.de>
2019-03-13 17:47:29 +01:00
Richard Steinmetz 8bd688664d Fix typo in docker-entrypoint.sh
Signed-off-by: Richard Steinmetz <steinmetz.richard@googlemail.com>
2018-12-12 19:24:24 +01:00
Tilo Spannagel 424364e2e1
Merge pull request #515 from SnowMB/add_update_variable
Add NEXTCLOUD_UPDATE for containers started with non-default commands
2018-10-16 18:30:39 +02:00
Arthur Schiwon 3f931009c5
add a mechanism to set trusted domains on install 2018-10-15 15:29:32 +02:00
Marc Brückner 63710a75a3 added new environment variable 2018-10-15 15:01:39 +02:00
Tilo Spannagel 91adc66fae
Merge pull request #480 from SnowMB/fix_sleeps
added retry loop and decreased sleep time
2018-10-03 17:56:15 +02:00
Marc Brückner 6eb8f3fa16 added retry loop and decreased sleep time 2018-10-02 10:45:00 +02:00
Tilo Spannagel a46493fbc4
Use exclude file for the updater
Signed-off-by: Tilo Spannagel <development@tilosp.de>
2018-10-01 22:31:34 +02:00
Marc Bihlmaier efe4edb8eb echo to stdout when migration-script is running (#333)
* echo to stdout when migration-script is running

* specifying output

* output Initializing new instance

* simplify output
2018-09-29 20:15:08 +02:00
Tilo Spannagel 6b10932e81
Ignore shellcheck errors
Signed-off-by: Tilo Spannagel <development@tilosp.de>
2018-09-27 13:04:47 +02:00
Marc Brückner dbadf5520b fixed expansion of environment variables 2018-09-27 09:58:47 +02:00
Marc Brückner bdc2d3e610 fix regex for apache 2018-09-14 08:25:49 +02:00
Marc Brückner a3cce50b00 only initialize / update when the command is apache* or php-fpm (do nothing on thins like bash, echo) 2018-09-13 14:36:50 +02:00
Marc Brückner f5d3234fca - using defaults from autoconfig.php
- using '-n' instead of '! -z'
- adding quotes
2018-09-13 11:32:56 +02:00
Marc Brückner 7f485eb9fa implement #455: auto-install via occ maintenance:install 2018-09-12 14:32:05 +02:00
Louis Matthijssen f6abe4472b
Fix small typo in upgrade script 2018-09-09 14:25:54 +02:00