Projet Socle ENT
Pages enfant
  • Installer uP4 rapidement

Comparaison des versions

Légende

  • Ces lignes ont été ajoutées. Ce mot a été ajouté.
  • Ces lignes ont été supprimées. Ce mot a été supprimé.
  • La mise en forme a été modifiée.
Commentaire: Migrated to Confluence 5.3

...

Mysql

/pom.xml (drivers mysql)  (cf. https://wiki.jasig.org/display/UPM40/MySQL )

Bloc de code
languagediff
diff --git a/pom.xml b/pom.xml
index 1fa6d03..c86e320 100755
--- a/pom.xml
+++ b/pom.xml
@@ -84,9 +84,9 @@
         <project-site-path>/uportal/${project.version}</project-site-path>
         
         <!-- The JDBC Driver used by uPortal -->
-        <jdbc.groupId>org.hsqldb</jdbc.groupId>
-        <jdbc.artifactId>hsqldb</jdbc.artifactId>
-        <jdbc.version>${hsqldb.version}</jdbc.version>
+        <jdbc.groupId>mysql</jdbc.groupId>
+        <jdbc.artifactId>mysql-connector-java</jdbc.artifactId>
+        <jdbc.version>5.1.6</jdbc.version>
     
         <!--
          | Environment name and filters file for environment-specific build
@@ -337,6 +337,11 @@
                 <version>${hsqldb.version}</version>
             </dependency>
             <dependency>
+                <groupId>mysql</groupId>
+                <artifactId>mysql-connector-java</artifactId>
+                <version>5.1.6</version>
+            </dependency>
+            <dependency>
                 <groupId>org.hsqldb</groupId>
                 <artifactId>sqltool</artifactId>
                 <version>${hsqldb.version}</version>

Langues et Nombre de Threads Mysql

/uportal-war/src/main/resources/properties/portal.properties (passage en français par défaut et pb au chargement de la base)

( Pour Mysql; cf. https://wiki.jasig.org/display/UPM40/MySQL )

Bloc de code
languagediff
diff --git a/uportal-war/src/main/resources/properties/portal.properties b/uportal-war/src/main/resources/properties/portal.properties
index 8392f38..b610113 100644
--- a/uportal-war/src/main/resources/properties/portal.properties
+++ b/uportal-war/src/main/resources/properties/portal.properties
@@ -206,7 +206,7 @@ org.jasig.portal.UserPreferencesManager.save_UserPreferences_at_logout=false
 # underscore character.
 #
 org.jasig.portal.i18n.LocaleManager.locale_aware=true
-org.jasig.portal.i18n.LocaleManager.portal_locales=en_US,fr_FR,es_ES,ja_JP,sv_SE,de_DE,mk_MK,lv_LV
+org.jasig.portal.i18n.LocaleManager.portal_locales=fr_FR,en_US,es_ES,ja_JP,sv_SE,de_DE,mk_MK,lv_LV
 
 
 # The number of recent PortalExceptions ProblemsTable should cache
@@ -274,7 +274,7 @@ org.jasig.portal.version=${project.version}
 # Import/Export Thread Pool Configuration
 #
 org.jasig.portal.io.threadPool.initialThreads=0
-org.jasig.portal.io.threadPool.maxThreads=20
+org.jasig.portal.io.threadPool.maxThreads=1
 org.jasig.portal.io.threadPool.queueSize=500
 org.jasig.portal.io.threadPool.threadPriority=5
 org.jasig.portal.io.threadPool.keepAliveSeconds=30

...

on utilise des variable d'environnement pour le ldap (esup.ldap.url, esup.ldap.baseDN, ...)
uportal-war/src/main/resources/properties/contexts/ldapContext.xml

Bloc de code
languagediff
diff --git a/uportal-war/src/main/resources/properties/contexts/ldapContext.xml b/uportal-war/src/main/resources/properties/contexts/ldapContext.xml
index 5e7d32a..ceedd74 100644
--- a/uportal-war/src/main/resources/properties/contexts/ldapContext.xml
+++ b/uportal-war/src/main/resources/properties/contexts/ldapContext.xml
@@ -68,4 +68,11 @@
         <property name="pooled" value="false"/>
     </bean>
     -->
+    <bean id="defaultLdapContext">
+        <property name="url" value="${esup.ldap.url}"/>
+        <property name="base" value="${esup.ldap.baseDN}"/>
+        <property name="userName" value="${esup.ldap.bindDN}"/>
+        <property name="password" value="${esup.ldap.bindPasswd}"/>
+        <property name="pooled" value="${esup.ldap.pooled}"/>
+    </bean>
 </beans>

uportal-war/src/main/resources/properties/contexts/personDirectoryContext.xml

Bloc de code
languagediff
diff --git a/uportal-war/src/main/resources/properties/contexts/personDirectoryContext.xml b/uportal-war/src/main/resources/properties/contexts/personDirectoryContext.xml
index 6e69675..1832d85 100644
--- a/uportal-war/src/main/resources/properties/contexts/personDirectoryContext.xml
+++ b/uportal-war/src/main/resources/properties/contexts/personDirectoryContext.xml
@@ -137,10 +137,51 @@
                 -->
                 <ref bean="uPortalAccountUserSource" />
                 <ref bean="uPortalJdbcUserSource" />
+                <ref bean="uPortalLdapAttributeSource"/>
             </list>
         </property>
     </bean>
 
+    <bean id="uPortalLdapAttributeSource">
+        <property name="contextSource" ref="defaultLdapContext" />
+                <property name="baseDN" value="${esup.ldap.baseDN}" />
+                <property name="queryAttributeMapping">
+                    <map>
+                        <entry key="username" value="uid"/>
+                    </map>
+                </property>
+
+                <property name="resultAttributeMapping">
+                    <map>
+                        <entry key="eduPersonPrimaryAffiliation">    <value>eduPersonPrimaryAffiliation</value></entry>                
+                        <entry key="eduPersonAffiliation">            <value>eduPersonAffiliation</value></entry>                
+                        <entry key="cn">                            <value>cn</value></entry>
+                        <entry key="description">                   <value>description</value></entry>
+                        <entry key="displayName">                   <value>displayName</value></entry>
+                        <entry key="facsimileTelephoneNumber">      <value>facsimileTelephoneNumber</value></entry>
+                        <entry key="givenName">                     <value>givenName</value></entry>
+                        <entry key="mail">                          <value>mail</value></entry>
+                        <entry key="postalAddress">                 <value>postalAddress</value></entry>
+                        <entry key="sn">                            <value>sn</value></entry>
+                        <entry key="telephoneNumber">               <value>telephoneNumber</value></entry>
+                        <entry key="uid">                              
+                            <set>
+                                <value>uid</value>
+                                <value>username</value>
+                                <value>user.login.id</value>
+                            </set>
+                        </entry>
+                        <entry key="supannCodeINE">                 <value>supannCodeINE</value></entry>
+                        <entry key="supannEtuId">                   <value>supannEtuId</value></entry>
+                        <entry key="supannEmpId">                   <value>supannEmpId</value></entry>
+                        <entry key="eduPersonAffiliation">          <value>eduPersonAffiliation</value></entry>
+                        <entry key="supannaffectation">             <value>supannaffectation</value></entry>
+                        <entry key="objectclass">                   <value>objectclass</value></entry>
+                        <entry key="supannorganisme">               <value>supannorganisme</value></entry>
+                    </map>
+                </property>
+    </bean>
+    
     <bean id="uPortalAccountUserSource">
         <property name="localAccountDao" ref="localAccountDao"/>
         <property name="usernameAttributeProvider" ref="usernameAttributeProvider" />

...

Bloc de code
call E:/esup4/env.cmd

DEL /Q "%TOMCAT_HOME%\logs\*.*"
DEL /Q "%TOMCAT_HOME%\work\*.*"
%TOMCAT_HOME%\bin\catalina start
@rem %CATALINA_HOME%\bin\catalina start -security
@rem %CATALINA_HOME%\bin\catalina jpda start

*_+stop.cmd ?:+_* script d'arrêt de tomcat

...