summaryrefslogtreecommitdiffstats
path: root/lib/private/Setup
Commit message (Collapse)AuthorAgeFilesLines
* Bump nextcloud/coding-standard from 0.3.0 to 0.5.0dependabot-preview[bot]2021-02-181-1/+1
| | | | | | | | | | Bumps [nextcloud/coding-standard](https://github.com/nextcloud/coding-standard) from 0.3.0 to 0.5.0. - [Release notes](https://github.com/nextcloud/coding-standard/releases) - [Changelog](https://github.com/nextcloud/coding-standard/blob/master/CHANGELOG.md) - [Commits](https://github.com/nextcloud/coding-standard/compare/v0.3.0...v0.5.0) Signed-off-by: dependabot-preview[bot] <support@dependabot.com> Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Only use alphanumeric chars for mysql passwordJoas Schilling2021-01-181-1/+2
| | | | | | / and + can cause problems with other tools that you might want to run on your Nextcloud database. Signed-off-by: Joas Schilling <coding@schilljs.com>
* Bump doctrine/dbal from 2.12.0 to 3.0.0Christoph Wurst2021-01-083-29/+28
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Add more previous exceptions to database setup codeMorris Jobke2021-01-073-4/+4
| | | | Signed-off-by: Morris Jobke <hey@morrisjobke.de>
* Update all license headers for Nextcloud 21Christoph Wurst2020-12-161-2/+1
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Revert "Revert "Installation goes brrrr""Joas Schilling2020-11-111-1/+1
|
* Revert "Installation goes brrrr"Christoph Wurst2020-11-111-1/+1
|
* Only update the schema when we install anywayJoas Schilling2020-11-111-1/+1
| | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* Format code to a single space around binary operatorsChristoph Wurst2020-10-052-6/+6
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Remove @suppress SqlInjectionCheckerMorris Jobke2020-09-161-1/+0
| | | | Signed-off-by: Morris Jobke <hey@morrisjobke.de>
* Update license headers for 19Christoph Wurst2020-04-292-1/+1
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Format control structures, classes, methods and functionChristoph Wurst2020-04-102-8/+7
| | | | | | | | | | | | | | | To continue this formatting madness, here's a tiny patch that adds unified formatting for control structures like if and loops as well as classes, their methods and anonymous functions. This basically forces the constructs to start on the same line. This is not exactly what PSR2 wants, but I think we can have a few exceptions with "our" style. The starting of braces on the same line is pracrically standard for our code. This also removes and empty lines from method/function bodies at the beginning and end. Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Use elseif instead of else ifChristoph Wurst2020-04-102-5/+5
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Update the license headers for Nextcloud 19Christoph Wurst2020-03-313-1/+3
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Use the short array syntax, everywhereChristoph Wurst2020-03-263-13/+13
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Check the new connection on setup like with PostgreSQL and OracleJoas Schilling2020-02-051-0/+10
| | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* Only provide the auth method for MySQL 8.0+ to not break MariaDBJoas Schilling2020-02-051-4/+13
| | | | | | Provide the auth method for MySQL 8.0+ Signed-off-by: Joas Schilling <coding@schilljs.com>
* Update license headersChristoph Wurst2019-12-055-6/+9
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Some php-cs fixesRoeland Jago Douma2019-11-223-0/+3
| | | | | | | | | | | * Order the imports * No leading slash on imports * Empty line before namespace * One line per import * Empty after imports * Emmpty line at bottom of file Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* Fix installing with MySQL 8.0.4+Joas Schilling2019-11-201-2/+2
| | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* Merge pull request #15187 from vitormattos/bugfix-create-database-userRoeland Jago Douma2019-08-081-0/+4
|\ | | | | Bugfix: user is not allowed
| * solve code reviewVitor Mattos2019-04-221-1/+1
| | | | | | | | Signed-off-by: Vitor Mattos <vitor@php.rio>
| * Check if database exists and grand permissionVitor Mattos2019-04-211-2/+4
| | | | | | | | Signed-off-by: Vitor Mattos <vitor@php.rio>
| * Bugfix: user is not allowedVitor Mattos2019-04-211-0/+2
| | | | | | | | | | | | The created user don't has permission to connect to database. I changed the code to give permission Signed-off-by: Vitor Mattos <vitor@php.rio>
* | Use specific privileges when creating adminOliver Salzburg2019-07-161-1/+1
|/ | | | | | | | | | | Using the ALL shorthand can cause problems when not all privileges are available to the user. For example, AWS RDS MariaDB/MySQL will not grant the initial user account on an instance the SUPER privilege. While the user account is still valid for pretty much any task on the DB instance, it can not use the ALL shorthand when granting privileges to new users. By supplying a specific set of privileges, we work around this limitation without sacrificing functionality. Closes #16139 Signed-off-by: Oliver Salzburg <oliver.salzburg@gmail.com>
* Cleanup some PHPDoc leftovers and unused variablesMorris Jobke2019-03-061-6/+1
| | | | Signed-off-by: Morris Jobke <hey@morrisjobke.de>
* Use empty instead ?? because dbname is '' sometimesDaniel Kesselberg2018-09-231-2/+7
| | | | Signed-off-by: Daniel Kesselberg <mail@danielkesselberg.de>
* Use const for dbname and dbtableprefix defaultsDaniel Kesselberg2018-09-231-6/+33
| | | | Signed-off-by: Daniel Kesselberg <mail@danielkesselberg.de>
* --database-name or --database-table-prefix are ignored for sqliteDaniel Kesselberg2018-09-231-4/+2
| | | | | | | | | | The default implementation of initialize in AbstractDatabase writes database information to config.php. The method is overwritten in Sqlite but parent is never called. Database-Name and Database-Table-Prefix are never written to config.php. But from this point setup use values from config. Signed-off-by: Daniel Kesselberg <mail@danielkesselberg.de>
* move log constants to ILoggerArthur Schiwon2018-04-261-4/+5
| | | | Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
* Remove unneeded semicolon and parenthesesMorris Jobke2018-01-262-2/+2
| | | | Signed-off-by: Morris Jobke <hey@morrisjobke.de>
* Properly log the full exception instead of only the messageMorris Jobke2018-01-231-10/+14
| | | | Signed-off-by: Morris Jobke <hey@morrisjobke.de>
* Update license headersMorris Jobke2017-11-064-6/+8
| | | | Signed-off-by: Morris Jobke <hey@morrisjobke.de>
* cleanup oci setup codeRobin Appelman2017-09-061-173/+22
| | | | Signed-off-by: Robin Appelman <robin@icewind.nl>
* Install from migrationsJoas Schilling2017-07-255-23/+3
| | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* Add Phan plugin to check for SQL injectionsLukas Reschke2017-07-201-0/+5
| | | | | | | | | | This adds a phan plugin which checks for SQL injections on code using our QueryBuilder, while it isn't perfect it should already catch most potential issues. As always, static analysis will sometimes have false positives and this is also here the case. So in some cases the analyzer just doesn't know if something is potential user input or not, thus I had to add some `@suppress SqlInjectionChecker` in front of those potential injections. The Phan plugin hasn't the most awesome code but it works and I also added a file with test cases. Signed-off-by: Lukas Reschke <lukas@statuscode.ch>
* Start migrationsJoas Schilling2017-07-051-0/+9
| | | | | | | | | | Fixme: - Install and update of apps - No revert on live systems (debug only) - Service adjustment to our interface - Loading via autoloader Signed-off-by: Joas Schilling <coding@schilljs.com>
* fix install on mb4 enabled mariadb/mysqlArthur Schiwon2017-06-011-1/+1
| | | | Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
* MySQL 4 byte is now detected during setup in any case.Thomas Müller2017-04-281-6/+4
| | | | config.sample.php was updated to explicitly state that there detection in place to set mysql.utf8mb4
* Add console command to migrate the charsetThomas Müller2017-04-281-23/+7
|
* During setup of a mysql database we try to detect if charset 'utf8mb4' can ↵Thomas Müller2017-04-281-0/+26
| | | | be used
* Remove unused use statementsMorris Jobke2017-04-221-1/+0
| | | | Signed-off-by: Morris Jobke <hey@morrisjobke.de>
* Fix translationsJoas Schilling2017-04-182-2/+2
| | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* use the same oci connectstring in all code pathsRobin Appelman2017-04-101-1/+1
| | | | Signed-off-by: Robin Appelman <robin@icewind.nl>
* Use SystemConfig instead of AllConfig for DB stuffMorris Jobke2017-03-195-18/+17
| | | | | | * preparation for followup PRs to clean up the DB bootstrapping Signed-off-by: Morris Jobke <hey@morrisjobke.de>
* Namespace and array syntax fixesMorris Jobke2017-03-191-1/+0
| | | | | | * minor fixes in preparation of a bigger DB and config PR Signed-off-by: Morris Jobke <hey@morrisjobke.de>
* Add proper default value for datadirMorris Jobke2017-01-191-1/+1
| | | | | | | * better safe than sorry * fixes #3091 Signed-off-by: Morris Jobke <hey@morrisjobke.de>
* Merge pull request #2535 from ↵Joas Schilling2017-01-051-7/+9
|\ | | | | | | | | nextcloud/allow-to-reuse-admin-as-install-name-like-on-mysql Allow to reuse the same name when installing a new instance on postgres
| * Allow to reuse the same name when installing a new instanceJoas Schilling2016-12-121-7/+9
| | | | | | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* | Merge pull request #2670 from ↵Roeland Jago Douma2016-12-141-1/+1
|\ \ | | | | | | | | | | | | nextcloud/issue-2646-dont-connet-to-database-before-creating-it Do not connect to database before creating it