Commit Graph

103 Commits

Author SHA1 Message Date
jf-cbd
5811dc06e3 Merge remote-tracking branch 'origin/support/3.2' into develop 2025-05-15 09:48:22 +02:00
jf-cbd
f5ddbbbe0e Rollback typing parameter 2025-05-13 16:59:43 +02:00
jf-cbd
6811a82e1a Merge remote-tracking branch 'origin/support/2.7' into support/3.2
# Conflicts:
#	datamodels/2.x/itop-backup/status.php
#	setup/setuputils.class.inc.php
2025-05-13 16:40:11 +02:00
jf-cbd
544c4ae888 N°8379 - fix backup issue 2025-05-13 16:05:39 +02:00
Molkobain
7ee1af3cc8 Merge remote-tracking branch 'origin/support/3.2' into develop 2024-07-24 10:58:05 +02:00
Romain Quetiez
baf85e7a80 N°7629 Deprecate utils::GetClassesForInterface in favor of InterfaceDiscovery::FindItopClasses
Improve caching strategy and robustness
2024-07-16 10:13:13 +02:00
Romain Quetiez
68ee3231f4 Merge branch 'support/3.2' into develop
# Conflicts:
#	tests/php-unit-tests/src/Hook/TestsRunStartHook.php
2024-05-16 20:24:38 +02:00
Molkobain
ad36066126 📝 Copyright year bump 2024-05-06 18:35:31 +02:00
Molkobain
f930533d8b Merge remote-tracking branch 'origin/support/3.2' into develop 2024-04-12 11:08:59 +02:00
Molkobain
dad406d208 N°6964 - Improve PHPDoc and method name to explicit that paths are relative 2024-04-12 10:50:59 +02:00
Lars Kaltefleiter
93e1f6ae03 N°6964 - Add API to allow modules to register files to include in the backup (#547)
* Allow to include backup extra file via interface

* Update application/applicationextension.inc.php

Co-authored-by: Thomas Casteleyn <thomas.casteleyn@me.com>

* Add iBackupExtraFilesExtension to plugin list

* decouple extra_files via config and interface

* Add unit tests for iBackupExtraFilesExtension

* Enable recursive creation of destination directories

* Update application/applicationextension.inc.php

Co-authored-by: Molkobain <lajarige.guillaume@free.fr>

* Update setup/backup.class.inc.php

Co-authored-by: Molkobain <lajarige.guillaume@free.fr>

* Update tests/php-unit-tests/unitary-tests/application/applicationextension/ApplicationExtensionTest.php

Co-authored-by: Molkobain <lajarige.guillaume@free.fr>

* Update application/applicationextension.inc.php

Co-authored-by: Molkobain <lajarige.guillaume@free.fr>

* Update core/metamodel.class.php

Co-authored-by: Molkobain <lajarige.guillaume@free.fr>

* Update setup/backup.class.inc.php

Co-authored-by: Molkobain <lajarige.guillaume@free.fr>

---------

Co-authored-by: Thomas Casteleyn <thomas.casteleyn@me.com>
Co-authored-by: Molkobain <lajarige.guillaume@free.fr>
2024-04-12 09:17:17 +02:00
Molkobain
e18ea88735 N°6648 - Use \utils::GetDataPath() instead of hard-coded paths (#555)
* N°6648 - Use \utils::GetDataPath() instead of hard-coded paths

* Update setup/applicationinstaller.class.inc.php

Co-authored-by: Thomas Casteleyn <thomas.casteleyn@super-visions.com>

---------

Co-authored-by: Thomas Casteleyn <thomas.casteleyn@super-visions.com>
2024-01-22 21:06:08 +01:00
Pierre Goiffon
379062f1f7 Merge remote-tracking branch 'origin/support/3.0' into support/3.1
Most of the conflicts are caused by HU translations (N°7077 / #584)

# Conflicts:
#	css/setup.css
#	datamodels/2.x/authent-cas/dictionaries/hu.dict.authent-cas.php
#	datamodels/2.x/authent-ldap/dictionaries/hu.dict.authent-ldap.php
#	datamodels/2.x/authent-local/dictionaries/hu.dict.authent-local.php
#	datamodels/2.x/combodo-backoffice-darkmoon-theme/dictionaries/hu.dict.combodo-backoffice-darkmoon-theme.php
#	datamodels/2.x/combodo-db-tools/dictionaries/hu.dict.combodo-db-tools.php
#	datamodels/2.x/itop-attachments/dictionaries/hu.dict.itop-attachments.php
#	datamodels/2.x/itop-backup/dictionaries/hu.dict.itop-backup.php
#	datamodels/2.x/itop-bridge-cmdb-ticket/dictionaries/hu.dict.itop-bridge-cmdb-ticket.php
#	datamodels/2.x/itop-change-mgmt-itil/dictionaries/hu.dict.itop-change-mgmt-itil.php
#	datamodels/2.x/itop-change-mgmt/dictionaries/hu.dict.itop-change-mgmt.php
#	datamodels/2.x/itop-config-mgmt/dictionaries/hu.dict.itop-config-mgmt.php
#	datamodels/2.x/itop-config/dictionaries/hu.dict.itop-config.php
#	datamodels/2.x/itop-core-update/dictionaries/hu.dict.itop-core-update.php
#	datamodels/2.x/itop-faq-light/dictionaries/hu.dict.itop-faq-light.php
#	datamodels/2.x/itop-hub-connector/dictionaries/hu.dict.itop-hub-connector.php
#	datamodels/2.x/itop-incident-mgmt-itil/dictionaries/hu.dict.itop-incident-mgmt-itil.php
#	datamodels/2.x/itop-knownerror-mgmt/dictionaries/hu.dict.itop-knownerror-mgmt.php
#	datamodels/2.x/itop-oauth-client/hu.dict.itop-oauth-client.php
#	datamodels/2.x/itop-portal-base/dictionaries/hu.dict.itop-portal-base.php
#	datamodels/2.x/itop-portal/dictionaries/hu.dict.itop-portal.php
#	datamodels/2.x/itop-problem-mgmt/dictionaries/hu.dict.itop-problem-mgmt.php
#	datamodels/2.x/itop-request-mgmt-itil/dictionaries/hu.dict.itop-request-mgmt-itil.php
#	datamodels/2.x/itop-request-mgmt/dictionaries/hu.dict.itop-request-mgmt.php
#	datamodels/2.x/itop-service-mgmt-provider/dictionaries/hu.dict.itop-service-mgmt-provider.php
#	datamodels/2.x/itop-service-mgmt/dictionaries/hu.dict.itop-service-mgmt.php
#	datamodels/2.x/itop-structure/dictionaries/hu.dict.itop-structure.php
#	datamodels/2.x/itop-tickets/dictionaries/hu.dict.itop-tickets.php
#	dictionaries/hu.dictionary.itop.core.php
#	dictionaries/hu.dictionary.itop.ui.php
#	dictionaries/ui/components/breadcrumbs/hu.dictionary.itop.breadcrumbs.php
#	dictionaries/ui/components/datatable/hu.dictionary.itop.datatable.php
#	dictionaries/ui/components/field/hu.dictionary.itop.field.php
#	dictionaries/ui/components/global-search/hu.dictionary.itop.global-search.php
#	dictionaries/ui/components/input/hu.dictionary.itop.input.php
#	dictionaries/ui/components/quick-create/hu.dictionary.itop.quick-create.php
#	dictionaries/ui/layouts/activity-panel/hu.dictionary.itop.activity-panel.php
#	dictionaries/ui/layouts/navigation-menu/hu.dictionary.itop.navigation-menu.php
#	dictionaries/ui/layouts/object-details/hu.dictionary.itop.object-details.php
#	dictionaries/ui/layouts/page-content/hu.dictionary.itop.page-content.php
#	dictionaries/ui/layouts/tab-container/hu.dictionary.itop.tab-container.php
#	dictionaries/ui/pages/errorpage/hu.dictionary.itop.errorpage.php
#	dictionaries/ui/pages/preferences/hu.dictionary.itop.preferences.php
#	tests/php-unit-tests/unitary-tests/setup/DBBackupTest.php
2024-01-03 17:30:57 +01:00
Pierre Goiffon
6042e7f74d Merge remote-tracking branch 'origin/support/2.7' into support/3.0
# Conflicts:
#	tests/php-unit-tests/post-build-integration-tests/SetupCssIntegrityChecklistTest.php
#	tests/php-unit-tests/unitary-tests/core/CMDBSource/CMDBSourceTest.php
2024-01-03 10:43:41 +01:00
Pierre Goiffon
6995a3c641 N°6889 backup mysqldump call : restore possibility to connect using socket protocol (#591)
With previous fix (N°6123) we forced to use the tcp protocol each time. This was blocking for users wanting to connect using the socket protocol on localhost.

Now for localhost we will : 
- send both port and protocol arguments if the `db_host` config parameter does contain a port
- don't send any of the port or protocol arguments if `db_host` doesn't contain a port
2023-12-20 15:19:50 +01:00
Eric Espie
9c37d5c23e Merge remote-tracking branch 'origin/support/3.0' into support/3.1
# Conflicts:
#	application/applicationextension.inc.php
#	application/cmdbabstract.class.inc.php
#	core/dbobject.class.php
#	core/kpi.class.inc.php
#	core/metamodel.class.php
#	lib/composer/autoload_classmap.php
#	lib/composer/autoload_static.php
#	tests/php-unit-tests/unitary-tests/setup/DBBackupTest.php
2023-07-19 09:26:46 +02:00
Eric Espie
6432678de9 Merge remote-tracking branch 'origin/support/2.7' into support/3.0
# Conflicts:
#	application/cmdbabstract.class.inc.php
#	application/utils.inc.php
#	bootstrap.inc.php
#	composer.json
#	core/MyHelpers.class.inc.php
#	core/cmdbsource.class.inc.php
#	core/config.class.inc.php
#	core/dbobject.class.php
#	core/kpi.class.inc.php
#	core/metamodel.class.php
#	lib/composer/autoload_classmap.php
#	lib/composer/autoload_real.php
#	lib/composer/autoload_static.php
2023-07-18 14:36:58 +02:00
Eric Espie
78396d8e4a 6548 - [ER] Hide DBHost and DBUser in log 2023-07-10 17:37:27 +02:00
Stephen Abello
9afc22bd8f N°6123 - Add tests and comments 2023-07-07 09:29:15 +02:00
Pierre Goiffon
ef0b0f88c9 Merge remote-tracking branch 'origin/support/3.0' into develop
# Conflicts:
#	sources/Core/Email/EmailSwiftMailer.php
#	tests/php-unit-tests/integration-tests/DictionariesConsistencyTest.php
#	tests/php-unit-tests/postbuild_integration.xml.dist
2023-07-06 17:11:10 +02:00
Pierre Goiffon
a010239efb Merge remote-tracking branch 'origin/support/2.7' into support/3.0 2023-07-06 15:48:42 +02:00
Stephen Abello
246e4a9f50 N°6123 - Fix warnings when launching a backup on MariaDB > v10.6.1 with localhost dbhost 2023-07-06 09:28:01 +02:00
Molkobain
3e73038709 N°6380 - Fix exception "Failed to parse time string" with check_backup.php script 2023-06-22 13:51:01 +02:00
denis.flaven@combodo.com
7fe565c4fb Merge branch 'feature/6133-add-extra-files-to-backup-and-restore' into develop 2023-05-11 14:41:02 +02:00
denis.flaven@combodo.com
08ebac1b5c Fix PR remarks 2023-05-10 17:42:50 +02:00
denis.flaven@combodo.com
001194835f Config file may not exist during unattended setup/backup 2023-04-06 10:50:47 +02:00
denis.flaven@combodo.com
955aefc05b Ignore non-existing files. 2023-04-04 14:26:31 +02:00
denis.flaven@combodo.com
034ca26d01 Do NOT backup unsafe files. 2023-04-03 11:54:01 +02:00
denis.flaven@combodo.com
d03bd706e2 Support of extra files (configurable) in the backup. 2023-03-29 16:53:38 +02:00
Molkobain
c767ebe989 📝 Copyright year bump 2023-03-17 18:28:47 +01:00
Molkobain
f7ee21f1d7 N°5279 - PHP 8.1: Migrate usages of deprecated strftime() function
In the end we made an adapter to keep using the strftime() format (https://www.php.net/manual/fr/function.strftime.php); not to ease migration but because we couldn't use \DateTime::format().
We can't use \DateTime::format() directly on the whole filename as it would also format characters that are not supposed to be. eg. "__DB__-Y-m-d-production" would become "itopdb-2023-02-09-+01:00Thu, 09 Feb 2023 11:34:01 +0100202309", mind the "production" part being converted.
2023-02-10 22:15:18 +01:00
Lars Kaltefleiter
b354058eb5 N°5622 Fix backup cannot be done if TLS enabled with no CA (#354) 2023-01-10 12:13:33 +01:00
Pierre Goiffon
135ddbf37d Merge remote-tracking branch 'origin/support/2.7' into support/3.0
# Conflicts:
#	test/phpunit.xml.dist
2022-01-13 13:36:09 +01:00
Pierre Goiffon
426f275c03 💡 Add additional phpdoc to \DBBackup::GetMysqlCliTlsOptions 2022-01-12 11:21:21 +01:00
Pierre Goiffon
b55ba2ac7f Merge remote-tracking branch 'origin/support/2.7' into support/3.0
# Conflicts:
#	core/cmdbsource.class.inc.php
#	core/log.class.inc.php
#	test/setup/iTopDesignFormat/iTopDesignFormatTest.php
2022-01-12 09:56:16 +01:00
Pierre Goiffon
0ee6c60e94 Fix DBBackupTest (again :/)
Was working on Windows but not on Linux...
2022-01-12 09:12:04 +01:00
Pierre Goiffon
a663e9fded Fix DBBackupTest
DB connection dependency was added in a222ead4 (N°2336) in \DBBackup::GetMysqlCliTlsOptions but test wasn't updated accordingly :/^

The test wasn't ran on Jenkins until b11bf308, so we saw the regression only yesterday :(

This is now fixed ! 🥳
2022-01-12 09:00:26 +01:00
Pierre Goiffon
b3bf516b20 💡 Fix PHPDoc for \DBBackup::GetMysqlCliTlsOptions 2022-01-12 08:24:28 +01:00
Eric Espie
a4e43d3f17 N°4225 - Remove Read-only mode for backup 2021-09-09 14:25:19 +02:00
Eric Espie
8e0ae67803 N°4227 / N°4225 - Enhance SetupUtils interface 2021-09-06 17:53:46 +02:00
odain
9e1e5a8a47 N°4227 - Manual iTop restore - protect any restore from cron or db updates and release readonly mode afterward only if restore set it itself 2021-08-12 16:25:50 +02:00
odain
2c026fa891 N°4225 - Protect manual backups from cron (and vice versa) - protect any backup from cron/db updates and release readonly mode only when backup set it itself 2021-08-12 16:25:50 +02:00
Molkobain
8dd96ea636 Copyright year bump 2021-03-15 09:29:45 +01:00
Pierre Goiffon
04fc58b55c 📝 Some @since annotations were missing complete version (ex 2.5 instead of 2.5.0) 2020-02-21 18:05:30 +01:00
Stephen Abello
130734bec7 Merge branch 'master' into develop
# Conflicts:
#	setup/backup.class.inc.php
2019-07-25 17:18:49 +02:00
Stephen Abello
d7fad4b646 Merge branch 'support/2.6.2' 2019-07-25 17:07:49 +02:00
Stephen Abello
f4d538ef6c N°2410 Fix regression in mysqldump call introduced in 2.6.2 2019-07-24 16:02:20 +02:00
Pierre Goiffon
dc868b16ab N°2366 remove DBBackup::CreateZip
* remove method and its dependencies
* create \utils::GetFileMimeType
* in \DBBackup::DownloadBackup mime type isn't hardcoded anymore
2019-07-19 15:51:05 +02:00
Pierre Goiffon
073b1cd303 N°2018 Backup : fix version check for MySQL8
Now uses \CMDBSource::GetDBVersion instead of mysqldump -V
2019-07-16 18:05:31 +02:00
Pierre Goiffon
e712791f43 Merge remote-tracking branch 'origin/master' into develop 2019-07-16 17:45:24 +02:00