1 | CLARIN Virtual Collection Registry |
---|
2 | ---------------------------------- |
---|
3 | |
---|
4 | * DATABASE CONNECTION * |
---|
5 | |
---|
6 | The connection to the database is configured using JNDI using the |
---|
7 | name "jdbc/VirtualCollectionStore". |
---|
8 | When using Apache Tomcat add the following to the context configuration |
---|
9 | of the web application (by either modifying "server.xml" or providing an |
---|
10 | appropiate context configuration, e.g. like |
---|
11 | "$CATALINA_HOME/conf/Catalina/localhost/VirtualCollectionRegistry.xml"; |
---|
12 | if in doubt, please check the Apache Tomcat documentation): |
---|
13 | |
---|
14 | <Resource name="jdbc/VirtualCollectionStore" auth="Container" |
---|
15 | type="javax.sql.DataSource" |
---|
16 | maxActive="8" maxIdle="4" maxWait="10000" |
---|
17 | removeAbandoned="true" |
---|
18 | defaultAutoCommit="false" |
---|
19 | driverClassName="com.mysql.jdbc.Driver" |
---|
20 | validationQuery="SELECT 1" |
---|
21 | username="$dbuser" |
---|
22 | password="$dbpass" |
---|
23 | url="jdbc:mysql://127.0.0.1:3306/$dbname" /> |
---|
24 | |
---|
25 | This will configure a DBCP data source for the virtual collection registry. |
---|
26 | Customize $dbuser, $dbpass and $dbname to match your local settings. |
---|
27 | NOTE: currently only MySQL is supported. |
---|
28 | |
---|
29 | * CONTEXT PARAMETERS * |
---|
30 | |
---|
31 | PUBLIC APPLICATION URL: |
---|
32 | |
---|
33 | Add the following context parameter (typically to the global context.xml file) |
---|
34 | and substitute the value with the correct *public* base location of the VCR: |
---|
35 | |
---|
36 | <Parameter name="eu.clarin.cmdi.virtualcollectionregistry.base_uri" |
---|
37 | value="http://my/server/VirtualCollectionRegistry" |
---|
38 | override="false"/> |
---|
39 | |
---|
40 | Add no trailing slash. You can verify this by checking the service links in the |
---|
41 | help page of the running application. |
---|
42 | |
---|
43 | ADMINISTRATOR USERS: |
---|
44 | |
---|
45 | Add the following context parameter: |
---|
46 | |
---|
47 | <Parameter |
---|
48 | name="eu.clarin.cmdi.virtualcollectionregistry.admindb" |
---|
49 | value="/path/to/vcr-admin.conf" /> |
---|
50 | |
---|
51 | Add the username of each user that should get administrator rights to the |
---|
52 | referenced file, one username per line. |
---|
53 | |
---|
54 | * PID PROVIDER * |
---|
55 | |
---|
56 | You need to choose, which persistent identifier provider you want to use. |
---|
57 | You can either use a dummy provider or the GWDG handle provider. |
---|
58 | a) For using the dummy provider add the following: |
---|
59 | <Parameter name="spring.profiles.active" |
---|
60 | value="vcr.pid.dummy" |
---|
61 | override="false"/> |
---|
62 | |
---|
63 | b) For using the GWDG handle provider add following and customize the |
---|
64 | values for $gwdg_user and $gwdg_password: |
---|
65 | |
---|
66 | <Parameter name="spring.profiles.active" |
---|
67 | value="vcr.pid.gwdg" |
---|
68 | override="false"/> |
---|
69 | <Parameter name="pid_provider.username" value="$gwdg_user" override="false"/> |
---|
70 | <Parameter name="pid_provider.password" value="$gwdg_password" override="false"/> |
---|
71 | |
---|
72 | c) For using the EPIC API v2 handle provider add following and customize the |
---|
73 | values for $epic_user and $epic_password: |
---|
74 | |
---|
75 | <Parameter name="spring.profiles.active" |
---|
76 | value="vcr.pid.epicâ |
---|
77 | override="false"/> |
---|
78 | |
---|
79 | <Parameter name="pid_provider.epic.service_base_url" |
---|
80 | value="http://pid-vm04.gwdg.de:8080/handles/" |
---|
81 | override="false"/> |
---|
82 | <Parameter name="pid_provider.epic.handle_prefix" |
---|
83 | value="11148" |
---|
84 | override="false"/> |
---|
85 | <Parameter name="pid_provider.epic.user" |
---|
86 | value="$epic_user" |
---|
87 | override="false"/> |
---|
88 | <Parameter name="pid_provider.epic.password" |
---|
89 | value="$epic_password" |
---|
90 | override="false"/> |
---|
91 | |
---|
92 | Add the following parameter to configure a custom PID 'infix'. The example below |
---|
93 | configures the default behaviour, i.e. '{prefix}/VCR-{id}'. |
---|
94 | |
---|
95 | <Parameter name="pid_provider.epic.infix" |
---|
96 | value="VCR-"/> |
---|
97 | |
---|
98 | * AUTHENTICATION * |
---|
99 | |
---|
100 | The application has two alternative authentication configuration represented by two |
---|
101 | versions of the web.xml file. The default web.xml assumes Tomcat UserDatabaseRealm, |
---|
102 | which is useful for testing purposes. |
---|
103 | |
---|
104 | To shibbolize this application, the following steps are required: |
---|
105 | |
---|
106 | 1. Use the shibboleth version of web.xml called 'web-shib.xml' instead of |
---|
107 | the default one by renaming it to and overwriting web.xml (you can make a |
---|
108 | backup of the original web.xml). If the package was built for a production |
---|
109 | environment, it should already have the right web.xml in place. |
---|
110 | |
---|
111 | 2. Add the following to the relevant Apache configuration: |
---|
112 | |
---|
113 | <Location /vcr> |
---|
114 | ProxyPass ajp://localhost:8009/vcr |
---|
115 | AuthType shibboleth |
---|
116 | ShibRequireSession Off |
---|
117 | ShibUseHeaders On |
---|
118 | Satisfy All |
---|
119 | Require shibboleth |
---|
120 | </Location> |
---|
121 | |
---|
122 | <Location /vcr/service/submit> |
---|
123 | ShibRequireSession On |
---|
124 | </Location> |
---|
125 | |
---|
126 | Adjust locations to the desired and relevant local alternatives. The second |
---|
127 | block is required to make the virtual collection form submit service work |
---|
128 | with POSTs (current versions of SHHAA do not support this). |
---|
129 | |
---|
130 | 3. Configure the right SSO and SLO locations in WEB-INF/shhaa.xml: |
---|
131 | |
---|
132 | <authentication> |
---|
133 | ... |
---|
134 | <sso action="lI">https://shib-host/Shibboleth.sso/Login</sso> |
---|
135 | <slo action="lO">https://shib-host/Shibboleth.sso/Logout</slo> |
---|
136 | </authentication> |
---|
137 | |
---|
138 | * OAI PROVIDER * |
---|
139 | |
---|
140 | Collection display name: |
---|
141 | |
---|
142 | Add the following to the Tomcat context.xml file to set a custom collection display name |
---|
143 | (MdCollectionDisplayName header element) for the CMDI representations provided by the |
---|
144 | built-in OAI provider: |
---|
145 | |
---|
146 | <Parameter name="eu.clarin.cmdi.virtualcollectionregistry.collectiondisplayname |
---|
147 | value="CLARIN Virtual Collection Registry" /> |
---|
148 | |
---|
149 | Change the value of the 'value' attribute if desired. If this parameter is not set, |
---|
150 | the default value "CLARIN Virtual Collection Registry" will be used as a collection name. |
---|