Commit 4ba8486d7cb0747b4993e12f58a6d3e82b9f4a52

Authored by Etienne Pallier
1 parent f0410428

regroupement de tous les db-update irap en un seul pour le latmos

database/update/db-update-2017-05-19.sh deleted
... ... @@ -1,32 +0,0 @@
1   -#!/bin/bash
2   -
3   -# Pour Mac OS recent (10.10, Yosemite), la syntaxe du SED est differente
4   -# Il faut donc executer ce script comme ceci :
5   -# ./macos-db-update.sh ce_script.sh
6   -
7   -if [ ! -f ../../config/app.php ] ; then
8   -echo "Vous devez executer ce script depuis le dossier database/update/"
9   -exit 1
10   -fi
11   -
12   -
13   -# Get login, pass, dbname, and hostname
14   -username=$(grep "/\*d\*/'username'" ../../config/app.php | cut -d"'" -f4)
15   -password=$(grep "/\*d\*/'password'" ../../config/app.php | cut -d"'" -f4)
16   -database=$(grep "/\*d\*/'database'" ../../config/app.php | cut -d"'" -f4)
17   -host=$(grep "/\*d\*/'host'" ../../config/app.php | cut -d"'" -f4)
18   -
19   -
20   -cp -p ./script_sql/db-update-2017-05-19.sql ./script_sql/db-update-2017-05-19-build.sql
21   -
22   -# Execute sql update script
23   -sed -e "s/database/$database/" -i ./script_sql/db-update-2017-05-19-build.sql
24   -mysql --user=$username --password=$password -h $host < ./script_sql/db-update-2017-05-19-build.sql
25   -
26   -# Delete cakephp cache
27   -sudo rm ../../tmp/cache/models/*
28   -sudo rm ../../tmp/cache/persistent/*
29   -
30   -sudo chmod -R 777 ../../tmp
31   -sudo chmod -R 777 ../../vendor
32   -sudo chmod -R 777 ../../webroot
database/update/db-update-2017-05-22.sh deleted
... ... @@ -1,32 +0,0 @@
1   -#!/bin/bash
2   -
3   -# Pour Mac OS recent (10.10, Yosemite), la syntaxe du SED est differente
4   -# Il faut donc executer ce script comme ceci :
5   -# ./macos-db-update.sh ce_script.sh
6   -
7   -if [ ! -f ../../config/app.php ] ; then
8   -echo "Vous devez executer ce script depuis le dossier database/update/"
9   -exit 1
10   -fi
11   -
12   -
13   -# Get login, pass, dbname, and hostname
14   -username=$(grep "/\*d\*/'username'" ../../config/app.php | cut -d"'" -f4)
15   -password=$(grep "/\*d\*/'password'" ../../config/app.php | cut -d"'" -f4)
16   -database=$(grep "/\*d\*/'database'" ../../config/app.php | cut -d"'" -f4)
17   -host=$(grep "/\*d\*/'host'" ../../config/app.php | cut -d"'" -f4)
18   -
19   -
20   -cp -p ./script_sql/db-update-2017-05-22.sql ./script_sql/db-update-2017-05-22-build.sql
21   -
22   -# Execute sql update script
23   -sed -e "s/database/$database/" -i ./script_sql/db-update-2017-05-22-build.sql
24   -mysql --user=$username --password=$password -h $host < ./script_sql/db-update-2017-05-22-build.sql
25   -
26   -# Delete cakephp cache
27   -sudo rm ../../tmp/cache/models/*
28   -sudo rm ../../tmp/cache/persistent/*
29   -
30   -sudo chmod -R 777 ../../tmp
31   -sudo chmod -R 777 ../../vendor
32   -sudo chmod -R 777 ../../webroot
database/update/db-update-2017-06-09.sh renamed to database/update/db-update-2017-06-10.sh
... ... @@ -17,7 +17,7 @@ database=$(grep &quot;/\*d\*/&#39;database&#39;&quot; ../../config/app.php | cut -d&quot;&#39;&quot; -f4)
17 17 host=$(grep "/\*d\*/'host'" ../../config/app.php | cut -d"'" -f4)
18 18  
19 19  
20   -cp -p ./script_sql/db-update-2017-06-09.sql ./script_sql/db-update-2017-06-09-build.sql
  20 +cp -p ./script_sql/db-update-2017-06-10.sql ./script_sql/db-update-2017-06-10-build.sql
21 21  
22 22 # Execute sql update script
23 23 sed -e "s/database/$database/" -i ./script_sql/db-update-2017-06-09-build.sql
... ...
database/update/db-update-pb-irap.sh renamed to database/update/old/db-update-pb-irap.sh
database/update/script_sql/db-update-pb-irap.sql renamed to database/update/old/db-update-pb-irap.sql
database/update/script_sql/update_Donnees_IAS_Labinvent2.sql renamed to database/update/old/update_Donnees_IAS_Labinvent2.sql
database/update/script_sql/update_Donnees_IRAP_Labinvent2.sql renamed to database/update/old/update_Donnees_IRAP_Labinvent2.sql
database/update/script_sql/db-update-2017-05-19.sql deleted
... ... @@ -1,3 +0,0 @@
1   -use database;
2   -
3   -ALTER TABLE `configurations` ADD `envoi_mail_guests` TINYINT( 1 ) NOT NULL DEFAULT '0' AFTER `envoi_mail` ;
database/update/script_sql/db-update-2017-05-22.sql deleted
... ... @@ -1,3 +0,0 @@
1   -use database;
2   -
3   -ALTER TABLE `materiels` CHANGE `nom_gestionnaire` `gestionnaire_id` INT( 11 ) NULL ;
4 0 \ No newline at end of file
database/update/script_sql/db-update-2017-06-09.sql deleted
... ... @@ -1,3 +0,0 @@
1   -use database;
2   -
3   -ALTER TABLE `configurations` ADD `procedure_sur_accueil` TINYINT( 1 ) NOT NULL DEFAULT '1';
4 0 \ No newline at end of file
database/update/script_sql/db-update-2017-06-10.sql 0 → 100644
... ... @@ -0,0 +1,8 @@
  1 +use database;
  2 +
  3 +
  4 +ALTER TABLE `configurations` ADD `envoi_mail_guests` TINYINT( 1 ) NOT NULL DEFAULT '0' AFTER `envoi_mail` ;
  5 +
  6 +ALTER TABLE `materiels` CHANGE `nom_gestionnaire` `gestionnaire_id` INT( 11 ) NULL ;
  7 +
  8 +ALTER TABLE `configurations` ADD `procedure_sur_accueil` TINYINT( 1 ) NOT NULL DEFAULT '1';
0 9 \ No newline at end of file
... ...