This commit is contained in:
2019-04-17 17:27:19 +02:00
parent 4e345a7d4c
commit 5b87cf2715
1165 changed files with 442 additions and 377 deletions

View File

@ -1 +0,0 @@
* * * * * root /var/www/html/cadolesuser/scripts/cadolesuser-cron.sh &>/dev/null

View File

@ -1,6 +1,6 @@
Alias /cadolesuser /var/www/html/cadolesuser/web
Alias /ninegate /var/www/html/ninegate/web
<Directory "/var/www/html/cadolesuser/web" >
<Directory "/var/www/html/ninegate/web" >
AllowOverride All
Order Allow,Deny
Allow from All

View File

@ -1,5 +1,5 @@
---
%set dmode = %%getVar('cadolesuser_db_mode','non')
%set dmode = %%getVar('ninegate_db_mode','non')
%if %%dmode == "default"
%set dmode = %%getVar('edb_local','non')
%end if
@ -10,18 +10,18 @@ dbmode: %%dmode
grantall: true
%if %%dmode == "externe"
dbhost: %%cadolesuser_dbserver
dbport: %%cadolesuser_dbport
dbroot: %%cadolesuser_dbuser
dbrootpwd: %%cadolesuser_dbpass
dbhost: %%ninegate_dbserver
dbport: %%ninegate_dbport
dbroot: %%ninegate_dbuser
dbrootpwd: %%ninegate_dbpass
%else if %%dmode == "local"
dbhost: 127.0.0.1
%end if
dbtype: mysql
dbname: cadolesuser
dbuser: cadolesuser
dbname: ninegate
dbuser: ninegate
dbpass: "changeme"
%set allow_hosts = %%getVar('cadolesuser_allow_hosts', '')
%set allow_hosts = %%getVar('ninegate_allow_hosts', '')
%if %%dmode == "local"
client_hosts: ["127.0.0.1", "localhost" %slurp
%else if %%dmode == "externe"
@ -37,11 +37,11 @@ client_hosts: ["%%adresse_ip_eth0" %slurp
]
%end if
%end if
createscript: "/usr/share/eole/db/cadolesuser/gen/cadolesuser-create-0.sql"
createscript: "/usr/share/eole/db/ninegate/gen/ninegate-create-0.sql"
%set cnt_prefix = %%getVar('container_path_reseau', '')
pwd_files:
- {file: '%%cnt_prefix/var/www/html/cadolesuser/app/config/parameters.yml',
- {file: '%%cnt_prefix/var/www/html/ninegate/app/config/parameters.yml',
pattern: ' database_password: "',
end_pattern: '',
owner: 'root:www-data',

View File

@ -6,15 +6,15 @@ SET foreign_key_checks = 0;
SET sql_mode = 'NO_AUTO_VALUE_ON_ZERO';
INSERT IGNORE INTO `niveau01` (`id`, `label`, `siren`) VALUES
%if %%is_defined("cadolesuser_niveau01name")
(-100, '%%cadolesuser_niveau01name', '%%cadolesuser_niveau01siren');
%if %%is_defined("ninegate_niveau01name")
(-100, '%%ninegate_niveau01name', '%%ninegate_niveau01siren');
%else
(-100, '%%libelle_etab', '%%numero_etab');
%end if
%if %%getVar("cadolesuser_syncldap", 'non') == "oui"
%if %%getVar("ninegate_syncldap", 'non') == "oui"
INSERT IGNORE INTO `user` (`id`, `niveau01_id`, `username`, `firstname`, `lastname`, `password`, `email`, `avatar`, `role`,`siren`,`authlevel`) VALUES
(-100, -100, 'admin', 'Administrateur', '%%cadolesuser_organization', '%%pyeole.ssha.ssha_encode(%%cadolesuser_pwdadmin)', '%%system_mail_to', 'admin.jpg', 'ROLE_ADMIN', '%%cadolesuser_niveau01siren', 'simple');
(-100, -100, 'admin', 'Administrateur', '%%ninegate_organization', '%%pyeole.ssha.ssha_encode(%%ninegate_pwdadmin)', '%%system_mail_to', 'admin.jpg', 'ROLE_ADMIN', '%%ninegate_niveau01siren', 'simple');
%else
INSERT IGNORE INTO `user` (`id`, `niveau01_id`, `username`, `firstname`, `lastname`, `password`, `email`, `avatar`, `role`,`siren`,`authlevel`) VALUES
(-100, -100, 'admin', 'Administrateur', '%%libelle_etab', 'PWD_CAS', '%%system_mail_to', 'admin.jpg', 'ROLE_ADMIN', '%%numero_etab', 'simple');
@ -30,7 +30,7 @@ INSERT IGNORE INTO `sidebar` (`id`, `parent_id`, `roworder`, `label`, `path`, `f
(1200, NULL, 1200, 'ORGANISATION', NULL, 'fa-sitemap', 'ROLE_ADMIN,ROLE_MODO', ''),
(1210, 1200, 1210, 'Listes Blanche', 'cadoles_core_config_whitelist', 'fa-tasks', 'ROLE_ADMIN', ''),
(1220, 1200, 1220, 'Niveau 01', 'cadoles_core_config_niveau01', 'fa-building', 'ROLE_ADMIN', ''),
%if %%getVar("cadolesuser_niveau02view", 'non') == "oui"
%if %%getVar("ninegate_niveau02view", 'non') == "oui"
(1230, 1200, 1230, 'Niveau 02', 'cadoles_core_config_niveau02', 'fa-sitemap', 'ROLE_ADMIN,ROLE_MODO', ''),
%end if
(1240, 1200, 1240, 'Groupes', 'cadoles_core_config_group', 'fa-users', 'ROLE_ADMIN,ROLE_MODO', ''),

View File

@ -1,13 +1,13 @@
# This file is auto-generated during the composer install
parameters:
%if %%getVar("cadolesuser_db_mode", 'non') == "externe"
database_host: %%cadolesuser_dbserver
%if %%getVar('cadolesuser_dbport', 'non') != "non"
database_port: %%cadolesuser_dbport
%if %%getVar("ninegate_db_mode", 'non') == "externe"
database_host: %%ninegate_dbserver
%if %%getVar('ninegate_dbport', 'non') != "non"
database_port: %%ninegate_dbport
%else
database_port: null
%end if
%else if %%getVar("cadolesuser_db_mode", 'non') == "default"
%else if %%getVar("ninegate_db_mode", 'non') == "default"
%set dbhost = %%getVar('edb_host', 'non')
%if %%dbhost == 'non' and %%mode_conteneur_actif == 'oui':
database_host: %%adresse_ip_mysql
@ -27,14 +27,14 @@ parameters:
database_host: %%adresse_ip_mysql
database_port: null
%end if
database_name: cadolesuser
database_user: cadolesuser
database_name: ninegate
database_user: ninegate
database_password: "changeme"
mailer_transport: smtp
%if %%is_defined("cadolesuser_smtphost")
mailer_host: '%%cadolesuser_smtphost'
mailer_user: '%%cadolesuser_smtpuser'
mailer_password: '%%pwdreader("",%%cadolesuser_smtppwd)'
%if %%is_defined("ninegate_smtphost")
mailer_host: '%%ninegate_smtphost'
mailer_user: '%%ninegate_smtpuser'
mailer_password: '%%pwdreader("",%%ninegate_smtppwd)'
%else
mailer_host: 'localhost'
mailer_user: ''

View File

@ -5,6 +5,6 @@ export HTTP_PROXY="%%proxy_client_adresse:%%proxy_client_port"
export HTTPS_PROXY="%%proxy_client_adresse:%%proxy_client_port"
%end if
cd /var/www/html/cadolesuser
cd /var/www/html/ninegate
scripts/cadolesuser-postservice-01.sh
scripts/ninegate-postservice-01.sh

View File

@ -5,20 +5,20 @@ parameters:
# Sinon la source est externe soit via un annuaire soit via des attributs venant d'un SSO
# Si la source est externe de fait pas de module d'inscription ni de reset de password
# Et pas de synchronisation vers un annuaire ou vers ePortail
masteridentity: %%cadolesuser_masteridentity
masteridentity: %%ninegate_masteridentity
# Mode d'authentification soit SQL / LDAP / CAS / SAML
# Pour l'instant SQL - CAS - SAML Reste à faire LDAP
# Attention si le masteridentity est différent de SQL le mode d'authentification est forcement différent de SQL
# Car aucune synchronisation des password n'est possible
mode_auth: %%cadolesuser_mode_auth
mode_auth: %%ninegate_mode_auth
# Mode de registration : none / byuser / byadmin
# none = désactivation de l'inscription mais reset de password possible
# byuser = aucune validation par un administrateur, l'utilisateur valide son inscription par lui-même
# byadmin = validation de l'inscription par un administrateur, sauf si domaine de messagerie dans la liste blanche
%if %%getVar("cadolesuser_syncldap", 'non') == "oui"
moderegistration: %%cadolesuser_moderegistration
%if %%getVar("ninegate_syncldap", 'non') == "oui"
moderegistration: %%ninegate_moderegistration
%else
moderegistration: none
%end if
@ -39,37 +39,37 @@ parameters:
ldap_basedn: o=gouv,c=fr
# Mise en page
alias: cadolesuser
alias: ninegate
libelle_etab: %%libelle_etab
numero_etab: %%numero_etab
colormain: %%cadolesuser_colormain # Couleur principale
fontcolorhover: %%cadolesuser_fontcolorhover # Couleur des polices sur fond de couleur principale
keyterm: %%cadolesuser_keyterm # Taille mini du password
labelniveau01: %%cadolesuser_niveau01label # Label singulier du niveau 01 d'organisation
labelsniveau01: %%cadolesuser_niveau01labels # Label pluriel du niveau 01 d'organisation
iconniveau01: %%cadolesuser_niveau01icon # Icon du niveau 01 d'organisation
labelsirenniveau01: SIREN # Label SIREN
%if %%getVar("cadolesuser_niveau02view", 'non') == "oui"
viewniveau02: true # Gérer un niveau 02 d'organisation
labelniveau02: %%cadolesuser_niveau02label # Label singulier du niveau 02 d'organisation
labelsniveau02: %%cadolesuser_niveau02labels # Label pluriel du niveau 02 d'organisation
iconniveau02: %%cadolesuser_niveau02icon # Icon du niveau 02 d'organisation
labelsiretniveau02: SIRET # Label SIRET
colormain: %%ninegate_colormain # Couleur principale
fontcolorhover: %%ninegate_fontcolorhover # Couleur des polices sur fond de couleur principale
keyterm: %%ninegate_keyterm # Taille mini du password
labelniveau01: %%ninegate_niveau01label # Label singulier du niveau 01 d'organisation
labelsniveau01: %%ninegate_niveau01labels # Label pluriel du niveau 01 d'organisation
iconniveau01: %%ninegate_niveau01icon # Icon du niveau 01 d'organisation
labelsirenniveau01: SIREN # Label SIREN
%if %%getVar("ninegate_niveau02view", 'non') == "oui"
viewniveau02: true # Gérer un niveau 02 d'organisation
labelniveau02: %%ninegate_niveau02label # Label singulier du niveau 02 d'organisation
labelsniveau02: %%ninegate_niveau02labels # Label pluriel du niveau 02 d'organisation
iconniveau02: %%ninegate_niveau02icon # Icon du niveau 02 d'organisation
labelsiretniveau02: SIRET # Label SIRET
%else
viewniveau02: false # Gérer un niveau 02 d'organisation
labelniveau02: niveau02 # Label singulier du niveau 02 d'organisation
labelsniveau02: niveaus02 # Label pluriel du niveau 02 d'organisation
iconniveau02: fa-sitemap # Icon du niveau 02 d'organisation
labelsiretniveau02: SIRET # Label SIRET
viewniveau02: false # Gérer un niveau 02 d'organisation
labelniveau02: niveau02 # Label singulier du niveau 02 d'organisation
labelsniveau02: niveaus02 # Label pluriel du niveau 02 d'organisation
iconniveau02: fa-sitemap # Icon du niveau 02 d'organisation
labelsiretniveau02: SIRET # Label SIRET
%end if
# Si masteridentity est à SQL = où sont synchronisées les datas dans l'annuaire
%if %%getVar("cadolesuser_syncldap", 'non') == "oui"
%if %%getVar("ninegate_syncldap", 'non') == "oui"
ldap_sync: true
ldap_baseuser: ou=users,ou=%%cadolesuser_organization,o=gouv,c=fr
ldap_baseniveau01: ou=%%cadolesuser_niveau01branche,ou=%%cadolesuser_organization,o=gouv,c=fr
ldap_baseniveau02: ou=%%cadolesuser_niveau02branche,ou=%%cadolesuser_organization,o=gouv,c=fr
ldap_basegroup: ou=groups,ou=%%cadolesuser_organization,o=gouv,c=fr
ldap_baseuser: ou=users,ou=%%ninegate_organization,o=gouv,c=fr
ldap_baseniveau01: ou=%%ninegate_niveau01branche,ou=%%ninegate_organization,o=gouv,c=fr
ldap_baseniveau02: ou=%%ninegate_niveau02branche,ou=%%ninegate_organization,o=gouv,c=fr
ldap_basegroup: ou=groups,ou=%%ninegate_organization,o=gouv,c=fr
%else
ldap_sync: false
ldap_baseuser:
@ -81,7 +81,11 @@ parameters:
# Si masteridentity est à LDAP = quel est le modele d'organisation
# Si open = rien de particulier
# Si scribe = on génére des groupes correspondant au profil / classe / niveau / option
ldap_template: scribe
%if %%getVar("ninegate_masteridentity", 'non') == "LDAP"
ldap_template: %%ninegate_ldaptemplate
%else
ldap_template: open
%end if
# Si masteridentity est à LDAP = quel champs sont à récupérer
ldap_username: uid
@ -90,7 +94,7 @@ parameters:
ldap_email: mail
ldap_usersadmin: [admin,prof.6a]
%if %%getVar("cadolesuser_synceportail", 'non') == "oui"
%if %%getVar("ninegate_synceportail", 'non') == "oui"
eportail_sync: true
eportail_url: /eportail
eportail_login: /eportail/login.php
@ -131,11 +135,11 @@ parameters:
user_attr_saml_lastname: sn
user_attr_saml_firstname: givenName
%if %%is_defined("cadolesuser_smtpport")
mailer_port: '%%cadolesuser_smtpport'
mailer_encryption: %%cadolesuser_smtpencryption
mailer_authmode: %%cadolesuser_smtpauthmode
noreply: %%cadolesuser_noreply
%if %%is_defined("ninegate_smtpport")
mailer_port: '%%ninegate_smtpport'
mailer_encryption: %%ninegate_smtpencryption
mailer_authmode: %%ninegate_smtpauthmode
noreply: %%ninegate_noreply
%else
mailer_port: '2525'
mailer_encryption: null
@ -156,7 +160,7 @@ doctrine:
user: '%database_user%'
password: '%database_password%'
charset: UTF8
%if %%getVar("cadolesuser_synceportail", 'non') == "oui"
%if %%getVar("ninegate_synceportail", 'non') == "oui"
eportail:
driver: pdo_mysql
host: '%eportail_database_host%'
@ -175,7 +179,7 @@ doctrine:
CadolesCoreBundle: ~
CadolesCronBundle: ~
CadolesPortalBundle: ~
%if %%getVar("cadolesuser_synceportail", 'non') == "oui"
%if %%getVar("ninegate_synceportail", 'non') == "oui"
eportail:
connection: eportail
mappings:

1
tmpl/ninegate.cron Normal file
View File

@ -0,0 +1 @@
* * * * * root /var/www/html/ninegate/scripts/ninegate-cron.sh &>/dev/null