All Versions
DSpace Documentation
...
As of DSpace 7.2, the Configuration The configuration format is now YAML and is located at at ./config/config.*.yaml.
In DSpace 7.1 and 7.0, the Configuration format was a Typescript file and was located at ./src/environments/environment.*.ts. The structure of this file was essentially a JSON like format.
If you are upgrading from 7.0 or 7.1 to 7.2 (or later), you will either need to migrate your old configuration file (from Typescript to YAML) or start fresh. You can migrate your old (7.0 or 7.1) "environment.*.ts" configuration file to the new "config.*.yml" format (see the v7 UI configuration documentation).
The UI configuration files reside in the ./config/ folder in the Angular UI source code. The default configuration is provided in config.yml.
To change the default configuration values, you simply create (one or more) local files that override the parameters you need to modify. You can use config.example.yml as a starting point.
The UI configuration files reside in the ./config/ folder in the Angular UI source code. The default configuration is provided in config.yml.
To change the default configuration values, you simply create (one or more) local files that override the parameters you need to modify. You can use config.example.yml as a starting point.
config.dev.yml file in config/ for a development environment;config.prod.yml file in config/ config.dev.yml file in config/ for a development environment;config.prod.yml file in config/ for a production environment;...
Using Environment variables. All environment variables MUST (1) be prefixed with "DSPACE_", (2) use underscores as separators (no dots allowed), and (3) use all uppercase. Some examples are below:
| Code Block |
|---|
# "ui" settings environment variables ui.host => DSPACE_UI_HOST # The host name ui.port => DSPACE_UI_PORT # The port number ui.nameSpace => DSPACE_UI_NAMESPACE # The namespace ui.ssl => DSPACE_UI_SSL # Whether the angular application uses SSL [true/false] # "rest" settings environment variables rest.host => DSPACE_REST_HOST # The host name of the REST application rest.port => DSPACE_REST_PORT # The port number of the REST application rest.nameSpace => DSPACE_REST_NAMESPACE # The namespace of the REST application rest.ssl => DSPACE_REST_SSL # Whether the angular REST uses SSL [true/false] # Other examples defaultLanguagefallbackLanguage => DSPACE_DEFAULTLANGUAGEFALLBACKLANGUAGE mediaViewer.video => DSPACE_MEDIAVIEWER_VIDEO # Multi-valued setting examples # If a setting can have multiple values (e.g. theme names), then use an index number (starting with zero) # to specify the multiple values. # The below example is equivalent to: # themes: # - name: 'dspace' # - name: 'mytheme' # handle: '10673/123' DSPACE_THEMES_0_NAME = 'dspace' DSPACE_THEMES_1_NAME = 'mytheme' DSPACE_THEMES_1_HANDLE = '10673/123' |
.env (environment) file in the project root directory and setting the environment variables in that location....
The "ssr" section defines configurations related to Angular's Server Side Rendering (SSR). DSpace enables Angular SSR by default as required for Search Engine Optimization (SEO), as well as to support clients which cannot use Javascript. The default settings attempt to provide a balance between SEO and performance. However, you may choose to customize this behavior based on your local needs.a balance between SEO and performance. However, you may choose to customize this behavior based on your local needs.
| Code Block | ||||
|---|---|---|---|---|
| ||||
ssr:
# Whether to tell Angular to inline "critical" styles into the server-side rendered HTML.
# Determining which styles are critical is a relatively expensive operation; this option is
# disabled (false) by default to boost server performance at the expense of loading smoothness.
inlineCriticalCss: false
# Path patterns to *exclude* from SSR. By default, excludes community and collection browse, global browse,
# global search, community list, statistics and various administrative tools.
# The defined patterns will be run as regexes against the path of the page to check if SSR is allowed.
# If the path matches any of the regexes it will be served directly in CSR (client side rendering).
# NOTE: This configuration *replaces* the "paths" setting that existed in versions 7.6.3 and 8.1.
excludePathPatterns:
- pattern: "^/communities/[a-f0-9-]{36}/browse(/.*)?$"
flag: "i"
- pattern: "^/collections/[a-f0-9-]{36}/browse(/.*)?$"
flag: "i"
- pattern: "^/browse/"
- pattern: "^/search$"
- pattern: "^/community-list$"
- pattern: "^/admin/"
- pattern: "^/processes/?"
- pattern: "^/notifications/"
- pattern: "^/statistics/?"
- pattern: "^/access-control/"
- pattern: "^/health$"
# | ||||
| Code Block | ||||
| ||||
ssr: # Whether to tell Angular to inline "critical" styles into the server-side rendered HTML. # Determining which styles are critical is a relatively expensive operation; this option is # disabled (false) by default to boost server performance at the expense of loading smoothness. inlineCriticalCss: false # (8.1 and later) Path prefixes to enable SSR for. By default these are limited to paths of primary DSpace objects listed in the DSpace sitemap. # Paths are matched based on whether they "start with" a string in this configuration. Wildcards are not supported. # To disable this feature, specify [ '/' ], as that will result in all paths being enabled for SSR. paths: [ '/home', '/items/', '/entities/', '/collections/', '/communities/', '/bitstream/', '/bitstreams/', '/handle/' ] # (8.1 and later) Whether to enable rendering of Search component in SSR. # If set to true the component will be included in the HTML returned from the server side rendering. # If set to false the component will not be included in the HTML returned from the server side rendering. enableSearchComponent: false # (8.1 and later) Whether to enable rendering of Browse component on SSR. # If set to true the component will be included in the HTML returned from the server side rendering. # If set to false the component will not be included in the HTML returned from the server side rendering. enableBrowseComponent: false # (8.1 and later) Enable state transfer from the server-side application to the client-side application. (Defaults to true) # Note: When using an external application cache layer, it's recommended not to transfer the state to avoid caching it. # Disabling it ensures that dynamic state information is not inadvertently cached, which can improve security and # ensure that users always use the most up-to-date state. transferState: true # (8.1 and later) When a different REST base URL is used for the server-side application, the generated state contains references to # REST resources with the internal URL configured. By default, these internal URLs are replaced with public URLs. # Disable this setting to avoid URL replacement during SSR. In this the state is not transferred to avoid security issues. replaceRestUrl: true # Enable request performance profiling data collection and printing the results in the server console. # Defaults to false. Enabling in production is NOT recommended enablePerformanceProfiler: false |
...
| Code Block | ||||
|---|---|---|---|---|
| ||||
rest: ssl: true host: mydspace.edu port: 443 # NOTE: Space is capitalized because 'namespace' is a reserved string in TypeScript nameSpace: /server # (8.1 and later) OPTIONAL: Provide a different REST API URL to be used during SSR execution. # It must contain the whole URL including protocol, server port and server namespace ssrBaseUrl: http://localhost:8080/server |
...
| Code Block | ||||
|---|---|---|---|---|
| ||||
form: # (7.5 and above) Whether to enable "spellcheck" attribute of textareas in forms. spellCheck: true # NOTE: Map server-side validators to comparative Angular form validators validatorMap: required: required regex: pattern |
...
| Code Block | ||||
|---|---|---|---|---|
| ||||
submission:
autosave:
# NOTE: which metadata trigger an autosave
metadata: []
# NOTE: after how many time (milliseconds) submission is saved automatically
# eg. timer: 300000 # 5 minutes
timer: 0
icons:
metadata:
# NOTE: example of configuration
# # NOTE: metadata name
# - name: dc.author
# # NOTE: fontawesome (v6.x) icon classes and bootstrap utility classes can be used
# style: fas fa-user
- name: dc.author
style: fas fa-user
# default configuration
- name: default
style: ''
authority:
confidence:
# NOTE: example of configuration
# # NOTE: confidence value
# - value: 600
# # NOTE: fontawesome (v6.x) icon classes and bootstrap utility classes can be used
# style: text-success
# icon: fa-circle-check
# # NOTE: the class configured in property style is used by default, the icon property could be used in component
# configured to use a 'icon mode' display (mainly in edit-item page)
- value: 600
style: text-success
icon: fa-circle-check
- value: 500
style: text-info
icon: fa-gear
- value: 400
style: text-warning
icon: fa-circle-question
- value: 300
style: text-muted
icon: fa-thumbs-down
- value: 200
style: text-muted
icon: fa-circle-exclamation
- value: 100
style: text-muted
icon: fa-circle-stop
- value: 0
style: text-muted
icon: fa-ban
- value: -1
style: text-muted
icon: fa-circle-xmark
# default configuration
- value: default
style: text-muted
icon: fa-circle-xmark |
The "defaultLanguagefallbackLanguage" and "languages" sections allow you to customize which languages to support in your User Interface. See also Multilingual Support.
| Code Block | ||||
|---|---|---|---|---|
| ||||
# Fallback Defaultor default Language in which the UI will be rendered if the user's browser language is not an active language defaultLanguage rendered if the user's browser language is not an active language # NOTE: in DSpace 7.x-9.1 this was called "defaultLanguage". It was renamed to "fallbackLanguage" in 9.2+ fallbackLanguage: en # Languages. DSpace Angular holds a message catalog for each of the following languages. # When set to active, users will be able to switch to the use of this language in the user interface. # All out of the box language packs may be found in the ./src/assets/i18n/ directory languages: - code: en label: English active: true - code: cs label: Čeština active: true - code: de label: Deutsch active: true - ... |
...
| Code Block | ||||
|---|---|---|---|---|
| ||||
item: ... bitstream: # Number of entries in the bitstream list in the item view pageitem: ... bitstream: # Number of entries in the bitstream list in the item view page. pageSize: 5 # Show the bitstream access status label on the item page (default=false) # When enabled, embargoed bitstreams will show their embargo date in a label. pageSizeshowAccessStatuses: 5false |
NOTE: The "pageSize" configuration will always round to the closest "pageSizeOptions" value listed in "page-component-options.model.ts"
...
As of 7.5 (or later), the The Video viewer also supports WebVTT (or VTT) Captioning. Video captioning requires that a WebVTT Caption file (.vtt) be uploaded into the DSpace Item (DSpace is not able to create or generate these .vtt files). Here's an example of how to setup captioning:
...
The DSpace UI comes with basic end-user agreement and privacy policy functionality. Since release 7.4 these These features can be disabled in a configuration file. More information on what disabling on of these features results in is documented in the default app configuration (see code snippet below).
...
The "geospatialMapViewer" section allows you to enable the display of geospatial maps on item pages, search result views, and as a "browse by" page. These maps are driven by Leaflet.js with the OpenStreetMaps Mapnik tile provider (by default).
Take note of the default field used for geospatial metadata - this may need to be changed to fit your specific repository metadata usage.
| Code Block | ||||
|---|---|---|---|---|
| ||||
# Geospatial Map display options
geospatialMapViewer:
# Which fields to use for parsing as geospatial points in search maps
# (note, the item page field component allows any field(s) to be used
# and is set as an input when declaring the component)
spatialMetadataFields:
- 'dcterms.spatial'
# Which discovery configuration to use for 'geospatial search', used
# in the browse map
spatialFacetDiscoveryConfiguration: 'geospatial'
# Which filter / facet name to use for faceted geospatial search
# used in the browse map
spatialPointFilterName: 'point'
# Whether item page geospatial metadata should be displayed
# (assumes they are wrapped in a test for this config in the template as
# per the default templates supplied with DSpace for untyped-item and publication)
enableItemPageFields: false
# Whether the browse map should be enabled and included in the browse menu
enableBrowseMap: false
# Whether a 'map view' mode should be included alongside list and grid views
# in search result pages
enableSearchViewMode: false
# The tile provider(s) to use for the map tiles drawn in the leaflet maps.
# (see https://leaflet-extras.github.io/leaflet-providers/preview/) for a full list
tileProviders:
- 'OpenStreetMap.Mapnik'
# Starting centre point for the map, as lat and lng coordinates. This is useful
# to set the centre of the map when the map is first loaded and if there are no
# points, shapes or markers to display.
# Defaults to the centre of Istanbul
defaultCentrePoint:
lat: 41.015137
lng: 28.979530 |
Additional information about this feature can be found at https://github.com/kshepherd/dspace-geospatial-maps-doc/blob/main/README.md
The "debug" property allows you to turn on debugging in the Angular UI. When enabled, your environment and all Redux actions/transfers are logged to the console. This is only ever needed if you are debugging a tricky issue.
...