Skip to content
This repository has been archived by the owner on Sep 15, 2024. It is now read-only.

Commit

Permalink
Merge branch 'Vaadasch-master'
Browse files Browse the repository at this point in the history
  • Loading branch information
tuxgasy committed Mar 28, 2024
2 parents 47b4504 + edc6e87 commit 00c9b5a
Show file tree
Hide file tree
Showing 16 changed files with 184 additions and 21 deletions.
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -103,6 +103,7 @@ When setup this way, to upgrade version the use of the web interface is mandator
| **DOLI_ADMIN_LOGIN** | *admin* | Admin's login create on the first boot
| **DOLI_ADMIN_PASSWORD** | *admin* | Admin'password
| **DOLI_URL_ROOT** | *http://localhost* | Url root of the Dolibarr installation
| **DOLI_ENABLE_MODULES** | | Comma-separated list of modules to be activated at install. modUser will always be activated. (Ex: `Societe,Facture,Stock`)
| **PHP_INI_DATE_TIMEZONE** | *UTC* | Default timezone on PHP
| **PHP_INI_MEMORY_LIMIT** | *256M* | PHP Memory limit
| **PHP_INI_UPLOAD_MAX_FILESIZE** | *2M* | PHP Maximum allowed size for uploaded files
Expand Down
1 change: 1 addition & 0 deletions README.template
Original file line number Diff line number Diff line change
Expand Up @@ -97,6 +97,7 @@ When setup this way, to upgrade version the use of the web interface is mandator
| **DOLI_ADMIN_LOGIN** | *admin* | Admin's login create on the first boot
| **DOLI_ADMIN_PASSWORD** | *admin* | Admin'password
| **DOLI_URL_ROOT** | *http://localhost* | Url root of the Dolibarr installation
| **DOLI_ENABLE_MODULES** | | Comma-separated list of modules to be activated at install. modUser will always be activated. (Ex: `Societe,Facture,Stock`)
| **PHP_INI_DATE_TIMEZONE** | *UTC* | Default timezone on PHP
| **PHP_INI_MEMORY_LIMIT** | *256M* | PHP Memory limit
| **PHP_INI_UPLOAD_MAX_FILESIZE** | *2M* | PHP Maximum allowed size for uploaded files
Expand Down
26 changes: 23 additions & 3 deletions docker-init.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,26 @@
#!/usr/bin/env php
<?php
require_once '../htdocs/master.inc.php';
require_once DOL_DOCUMENT_ROOT . '/core/modules/modUser.class.php';
$mod = new modUser($db);
$mod->init();
require_once DOL_DOCUMENT_ROOT.'/core/lib/admin.lib.php';

printf("Activating module User... ");
activateModule('modUser');
printf("OK\n");

if (!empty(getenv('DOLI_ENABLE_MODULES'))) {
$dirMods = array_keys(dolGetModulesDirs())[0];

$mods = explode(',', getenv('DOLI_ENABLE_MODULES'));
foreach ($mods as $mod) {
$modName = 'mod'.$mod;
$modFile = $modName.'.class.php';
if (file_exists($dirMods.$modFile) ) {
printf("Activating module ".$mod." ...");
activateModule('mod' . $mod);
printf(" OK\n");
}
else {
printf("Unable to find module : ".$modName."\n");
}
}
}
3 changes: 3 additions & 0 deletions docker-run.sh
Original file line number Diff line number Diff line change
Expand Up @@ -171,6 +171,9 @@ function initializeDatabase()

echo "Enable user module ..."
php /var/www/scripts/docker-init.php

# Update ownership after initialisation of modules
chown -R www-data:www-data /var/www/documents
}

function migrateDatabase()
Expand Down
26 changes: 23 additions & 3 deletions images/15.0.3-php7.4/docker-init.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,26 @@
#!/usr/bin/env php
<?php
require_once '../htdocs/master.inc.php';
require_once DOL_DOCUMENT_ROOT . '/core/modules/modUser.class.php';
$mod = new modUser($db);
$mod->init();
require_once DOL_DOCUMENT_ROOT.'/core/lib/admin.lib.php';

printf("Activating module User... ");
activateModule('modUser');
printf("OK\n");

if (!empty(getenv('DOLI_ENABLE_MODULES'))) {
$dirMods = array_keys(dolGetModulesDirs())[0];

$mods = explode(',', getenv('DOLI_ENABLE_MODULES'));
foreach ($mods as $mod) {
$modName = 'mod'.$mod;
$modFile = $modName.'.class.php';
if (file_exists($dirMods.$modFile) ) {
printf("Activating module ".$mod." ...");
activateModule('mod' . $mod);
printf(" OK\n");
}
else {
printf("Unable to find module : ".$modName."\n");
}
}
}
3 changes: 3 additions & 0 deletions images/15.0.3-php7.4/docker-run.sh
Original file line number Diff line number Diff line change
Expand Up @@ -171,6 +171,9 @@ function initializeDatabase()

echo "Enable user module ..."
php /var/www/scripts/docker-init.php

# Update ownership after initialisation of modules
chown -R www-data:www-data /var/www/documents
}

function migrateDatabase()
Expand Down
26 changes: 23 additions & 3 deletions images/16.0.5-php8.1/docker-init.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,26 @@
#!/usr/bin/env php
<?php
require_once '../htdocs/master.inc.php';
require_once DOL_DOCUMENT_ROOT . '/core/modules/modUser.class.php';
$mod = new modUser($db);
$mod->init();
require_once DOL_DOCUMENT_ROOT.'/core/lib/admin.lib.php';

printf("Activating module User... ");
activateModule('modUser');
printf("OK\n");

if (!empty(getenv('DOLI_ENABLE_MODULES'))) {
$dirMods = array_keys(dolGetModulesDirs())[0];

$mods = explode(',', getenv('DOLI_ENABLE_MODULES'));
foreach ($mods as $mod) {
$modName = 'mod'.$mod;
$modFile = $modName.'.class.php';
if (file_exists($dirMods.$modFile) ) {
printf("Activating module ".$mod." ...");
activateModule('mod' . $mod);
printf(" OK\n");
}
else {
printf("Unable to find module : ".$modName."\n");
}
}
}
3 changes: 3 additions & 0 deletions images/16.0.5-php8.1/docker-run.sh
Original file line number Diff line number Diff line change
Expand Up @@ -171,6 +171,9 @@ function initializeDatabase()

echo "Enable user module ..."
php /var/www/scripts/docker-init.php

# Update ownership after initialisation of modules
chown -R www-data:www-data /var/www/documents
}

function migrateDatabase()
Expand Down
26 changes: 23 additions & 3 deletions images/17.0.4-php8.1/docker-init.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,26 @@
#!/usr/bin/env php
<?php
require_once '../htdocs/master.inc.php';
require_once DOL_DOCUMENT_ROOT . '/core/modules/modUser.class.php';
$mod = new modUser($db);
$mod->init();
require_once DOL_DOCUMENT_ROOT.'/core/lib/admin.lib.php';

printf("Activating module User... ");
activateModule('modUser');
printf("OK\n");

if (!empty(getenv('DOLI_ENABLE_MODULES'))) {
$dirMods = array_keys(dolGetModulesDirs())[0];

$mods = explode(',', getenv('DOLI_ENABLE_MODULES'));
foreach ($mods as $mod) {
$modName = 'mod'.$mod;
$modFile = $modName.'.class.php';
if (file_exists($dirMods.$modFile) ) {
printf("Activating module ".$mod." ...");
activateModule('mod' . $mod);
printf(" OK\n");
}
else {
printf("Unable to find module : ".$modName."\n");
}
}
}
3 changes: 3 additions & 0 deletions images/17.0.4-php8.1/docker-run.sh
Original file line number Diff line number Diff line change
Expand Up @@ -171,6 +171,9 @@ function initializeDatabase()

echo "Enable user module ..."
php /var/www/scripts/docker-init.php

# Update ownership after initialisation of modules
chown -R www-data:www-data /var/www/documents
}

function migrateDatabase()
Expand Down
26 changes: 23 additions & 3 deletions images/18.0.5-php8.1/docker-init.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,26 @@
#!/usr/bin/env php
<?php
require_once '../htdocs/master.inc.php';
require_once DOL_DOCUMENT_ROOT . '/core/modules/modUser.class.php';
$mod = new modUser($db);
$mod->init();
require_once DOL_DOCUMENT_ROOT.'/core/lib/admin.lib.php';

printf("Activating module User... ");
activateModule('modUser');
printf("OK\n");

if (!empty(getenv('DOLI_ENABLE_MODULES'))) {
$dirMods = array_keys(dolGetModulesDirs())[0];

$mods = explode(',', getenv('DOLI_ENABLE_MODULES'));
foreach ($mods as $mod) {
$modName = 'mod'.$mod;
$modFile = $modName.'.class.php';
if (file_exists($dirMods.$modFile) ) {
printf("Activating module ".$mod." ...");
activateModule('mod' . $mod);
printf(" OK\n");
}
else {
printf("Unable to find module : ".$modName."\n");
}
}
}
3 changes: 3 additions & 0 deletions images/18.0.5-php8.1/docker-run.sh
Original file line number Diff line number Diff line change
Expand Up @@ -171,6 +171,9 @@ function initializeDatabase()

echo "Enable user module ..."
php /var/www/scripts/docker-init.php

# Update ownership after initialisation of modules
chown -R www-data:www-data /var/www/documents
}

function migrateDatabase()
Expand Down
26 changes: 23 additions & 3 deletions images/19.0.1-php8.2/docker-init.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,26 @@
#!/usr/bin/env php
<?php
require_once '../htdocs/master.inc.php';
require_once DOL_DOCUMENT_ROOT . '/core/modules/modUser.class.php';
$mod = new modUser($db);
$mod->init();
require_once DOL_DOCUMENT_ROOT.'/core/lib/admin.lib.php';

printf("Activating module User... ");
activateModule('modUser');
printf("OK\n");

if (!empty(getenv('DOLI_ENABLE_MODULES'))) {
$dirMods = array_keys(dolGetModulesDirs())[0];

$mods = explode(',', getenv('DOLI_ENABLE_MODULES'));
foreach ($mods as $mod) {
$modName = 'mod'.$mod;
$modFile = $modName.'.class.php';
if (file_exists($dirMods.$modFile) ) {
printf("Activating module ".$mod." ...");
activateModule('mod' . $mod);
printf(" OK\n");
}
else {
printf("Unable to find module : ".$modName."\n");
}
}
}
3 changes: 3 additions & 0 deletions images/19.0.1-php8.2/docker-run.sh
Original file line number Diff line number Diff line change
Expand Up @@ -171,6 +171,9 @@ function initializeDatabase()

echo "Enable user module ..."
php /var/www/scripts/docker-init.php

# Update ownership after initialisation of modules
chown -R www-data:www-data /var/www/documents
}

function migrateDatabase()
Expand Down
26 changes: 23 additions & 3 deletions images/develop/docker-init.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,26 @@
#!/usr/bin/env php
<?php
require_once '../htdocs/master.inc.php';
require_once DOL_DOCUMENT_ROOT . '/core/modules/modUser.class.php';
$mod = new modUser($db);
$mod->init();
require_once DOL_DOCUMENT_ROOT.'/core/lib/admin.lib.php';

printf("Activating module User... ");
activateModule('modUser');
printf("OK\n");

if (!empty(getenv('DOLI_ENABLE_MODULES'))) {
$dirMods = array_keys(dolGetModulesDirs())[0];

$mods = explode(',', getenv('DOLI_ENABLE_MODULES'));
foreach ($mods as $mod) {
$modName = 'mod'.$mod;
$modFile = $modName.'.class.php';
if (file_exists($dirMods.$modFile) ) {
printf("Activating module ".$mod." ...");
activateModule('mod' . $mod);
printf(" OK\n");
}
else {
printf("Unable to find module : ".$modName."\n");
}
}
}
3 changes: 3 additions & 0 deletions images/develop/docker-run.sh
Original file line number Diff line number Diff line change
Expand Up @@ -171,6 +171,9 @@ function initializeDatabase()

echo "Enable user module ..."
php /var/www/scripts/docker-init.php

# Update ownership after initialisation of modules
chown -R www-data:www-data /var/www/documents
}

function migrateDatabase()
Expand Down

0 comments on commit 00c9b5a

Please sign in to comment.