Skip to content

Commit 316e29b

Browse files
committed
Merge remote-tracking branch 'origin/main' into cache-bust-dynamic-configuration_contribute-main
2 parents 2e1a30f + b1c4aa4 commit 316e29b

File tree

201 files changed

+6119
-1387
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

201 files changed

+6119
-1387
lines changed

.github/dependabot.yml

Lines changed: 47 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -96,6 +96,17 @@ updates:
9696
# Ignore all major version updates for all dependencies. We'll only automate minor/patch updates.
9797
- dependency-name: "*"
9898
update-types: ["version-update:semver-major"]
99+
# Also automatically update all our GitHub actions on the main branch
100+
- package-ecosystem: "github-actions"
101+
directory: "/"
102+
# Monthly dependency updates
103+
schedule:
104+
interval: "monthly"
105+
time: "05:00"
106+
# Allow updates to be delayed for a configurable number of days to mitigate
107+
# some classes of supply chain attacks
108+
cooldown:
109+
default-days: 7
99110
#####################
100111
## dspace-9_x branch
101112
#####################
@@ -187,6 +198,18 @@ updates:
187198
# Ignore all major version updates for all dependencies. We'll only automate minor/patch updates.
188199
- dependency-name: "*"
189200
update-types: ["version-update:semver-major"]
201+
# Also automatically update all our GitHub actions on the dspace-9_x branch
202+
- package-ecosystem: "github-actions"
203+
directory: "/"
204+
target-branch: dspace-9_x
205+
# Monthly dependency updates
206+
schedule:
207+
interval: "monthly"
208+
time: "05:00"
209+
# Allow updates to be delayed for a configurable number of days to mitigate
210+
# some classes of supply chain attacks
211+
cooldown:
212+
default-days: 7
190213
#####################
191214
## dspace-8_x branch
192215
#####################
@@ -277,6 +300,18 @@ updates:
277300
# Ignore all major version updates for all dependencies. We'll only automate minor/patch updates.
278301
- dependency-name: "*"
279302
update-types: ["version-update:semver-major"]
303+
# Also automatically update all our GitHub actions on the dspace-8_x branch
304+
- package-ecosystem: "github-actions"
305+
directory: "/"
306+
target-branch: dspace-8_x
307+
# Monthly dependency updates
308+
schedule:
309+
interval: "monthly"
310+
time: "05:00"
311+
# Allow updates to be delayed for a configurable number of days to mitigate
312+
# some classes of supply chain attacks
313+
cooldown:
314+
default-days: 7
280315
#####################
281316
## dspace-7_x branch
282317
#####################
@@ -362,3 +397,15 @@ updates:
362397
# Ignore all major version updates for all dependencies. We'll only automate minor/patch updates.
363398
- dependency-name: "*"
364399
update-types: ["version-update:semver-major"]
400+
# Also automatically update all our GitHub actions on the dspace-7_x branch
401+
- package-ecosystem: "github-actions"
402+
directory: "/"
403+
target-branch: dspace-7_x
404+
# Monthly dependency updates
405+
schedule:
406+
interval: "monthly"
407+
time: "05:00"
408+
# Allow updates to be delayed for a configurable number of days to mitigate
409+
# some classes of supply chain attacks
410+
cooldown:
411+
default-days: 7

.github/workflows/build.yml

Lines changed: 10 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@ jobs:
2424
# Spin up UI on 127.0.0.1 to avoid host resolution issues in e2e tests with Node 20+
2525
DSPACE_UI_HOST: 127.0.0.1
2626
DSPACE_UI_PORT: 4000
27+
DSPACE_UI_BASEURL: http://127.0.0.1:4000
2728
# Ensure all SSR caching is disabled in test environment
2829
DSPACE_CACHE_SERVERSIDE_BOTCACHE_MAX: 0
2930
DSPACE_CACHE_SERVERSIDE_ANONYMOUSCACHE_MAX: 0
@@ -51,11 +52,11 @@ jobs:
5152
steps:
5253
# https://github.com/actions/checkout
5354
- name: Checkout codebase
54-
uses: actions/checkout@v4
55+
uses: actions/checkout@v6
5556

5657
# https://github.com/actions/setup-node
5758
- name: Install Node.js ${{ matrix.node-version }}
58-
uses: actions/setup-node@v4
59+
uses: actions/setup-node@v6
5960
with:
6061
node-version: ${{ matrix.node-version }}
6162

@@ -80,7 +81,7 @@ jobs:
8081
id: npm-cache-dir
8182
run: echo "dir=$(npm config get cache)" >> $GITHUB_OUTPUT
8283
- name: Cache NPM dependencies
83-
uses: actions/cache@v4
84+
uses: actions/cache@v5
8485
with:
8586
# Cache entire NPM cache directory (see previous step)
8687
path: ${{ steps.npm-cache-dir.outputs.dir }}
@@ -113,7 +114,7 @@ jobs:
113114
# so that it can be shared with the 'codecov' job (see below)
114115
# NOTE: Angular CLI only supports code coverage for specs. See https://github.com/angular/angular-cli/issues/6286
115116
- name: Upload code coverage report to Artifact
116-
uses: actions/upload-artifact@v4
117+
uses: actions/upload-artifact@v7
117118
if: matrix.node-version == '20.x'
118119
with:
119120
name: coverage-report-${{ matrix.node-version }}
@@ -155,7 +156,7 @@ jobs:
155156
# Cypress always creates a video of all e2e tests (whether they succeeded or failed)
156157
# Save those in an Artifact
157158
- name: Upload e2e test videos to Artifacts
158-
uses: actions/upload-artifact@v4
159+
uses: actions/upload-artifact@v7
159160
if: always()
160161
with:
161162
name: e2e-test-videos-${{ matrix.node-version }}
@@ -164,7 +165,7 @@ jobs:
164165
# If e2e tests fail, Cypress creates a screenshot of what happened
165166
# Save those in an Artifact
166167
- name: Upload e2e test failure screenshots to Artifacts
167-
uses: actions/upload-artifact@v4
168+
uses: actions/upload-artifact@v7
168169
if: failure()
169170
with:
170171
name: e2e-test-screenshots-${{ matrix.node-version }}
@@ -316,19 +317,19 @@ jobs:
316317
runs-on: ubuntu-latest
317318
steps:
318319
- name: Checkout
319-
uses: actions/checkout@v4
320+
uses: actions/checkout@v6
320321

321322
# Download artifacts from previous 'tests' job
322323
- name: Download coverage artifacts
323-
uses: actions/download-artifact@v4
324+
uses: actions/download-artifact@v8
324325

325326
# Now attempt upload to Codecov using its action.
326327
# NOTE: We use a retry action to retry the Codecov upload if it fails the first time.
327328
#
328329
# Retry action: https://github.com/marketplace/actions/retry-action
329330
# Codecov action: https://github.com/codecov/codecov-action
330331
- name: Upload coverage to Codecov.io
331-
uses: Wandalen/wretry.action@v1.3.0
332+
uses: Wandalen/wretry.action@v3.8.0
332333
with:
333334
action: codecov/codecov-action@v4
334335
# Ensure codecov-action throws an error when it fails to upload

.github/workflows/codescan.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -35,19 +35,19 @@ jobs:
3535
steps:
3636
# https://github.com/actions/checkout
3737
- name: Checkout repository
38-
uses: actions/checkout@v4
38+
uses: actions/checkout@v6
3939

4040
# Initializes the CodeQL tools for scanning.
4141
# https://github.com/github/codeql-action
4242
- name: Initialize CodeQL
43-
uses: github/codeql-action/init@v3
43+
uses: github/codeql-action/init@v4
4444
with:
4545
languages: javascript
4646

4747
# Autobuild attempts to build any compiled languages
4848
- name: Autobuild
49-
uses: github/codeql-action/autobuild@v3
49+
uses: github/codeql-action/autobuild@v4
5050

5151
# Perform GitHub Code Scanning.
5252
- name: Perform CodeQL Analysis
53-
uses: github/codeql-action/analyze@v3
53+
uses: github/codeql-action/analyze@v4

.github/workflows/docker.yml

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -74,13 +74,15 @@ jobs:
7474
DSPACE_REST_HOST: 127.0.0.1
7575
# Override default dspace.ui.url to also use 127.0.0.1.
7676
dspace__P__ui__P__url: http://127.0.0.1:4000
77+
# Override default ui.baseUrl to also use 127.0.0.1. This must match 'dspace.ui.url' for SSR to be enabled.
78+
DSPACE_UI_BASEURL: http://127.0.0.1:4000
7779
steps:
7880
# Checkout our codebase (to get access to Docker Compose scripts)
7981
- name: Checkout codebase
80-
uses: actions/checkout@v4
82+
uses: actions/checkout@v6
8183
# Download Docker image artifacts (which were just built by reusable-docker-build.yml)
8284
- name: Download Docker image artifacts
83-
uses: actions/download-artifact@v4
85+
uses: actions/download-artifact@v8
8486
with:
8587
# Download all amd64 Docker images (TAR files) into the /tmp/docker directory
8688
pattern: docker-image-*-linux-amd64

.github/workflows/issue_opened.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ jobs:
1616
# Only add to project board if issue is flagged as "needs triage" or has no labels
1717
# NOTE: By default we flag new issues as "needs triage" in our issue template
1818
if: (contains(github.event.issue.labels.*.name, 'needs triage') || join(github.event.issue.labels.*.name) == '')
19-
uses: actions/add-to-project@v1.0.0
19+
uses: actions/add-to-project@v1.0.2
2020
# Note, the authentication token below is an ORG level Secret.
2121
# It must be created/recreated manually via a personal access token with admin:org, project, public_repo permissions
2222
# See: https://docs.github.com/en/actions/configuring-and-managing-workflows/authenticating-with-the-github_token#permissions-for-the-github_token

.github/workflows/port_merged_pull_request.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ jobs:
2323
if: github.event.pull_request.merged
2424
steps:
2525
# Checkout code
26-
- uses: actions/checkout@v4
26+
- uses: actions/checkout@v6
2727
# Port PR to other branch (ONLY if labeled with "port to")
2828
# See https://github.com/korthout/backport-action
2929
- name: Create backport pull requests

.github/workflows/pull_request_opened.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,4 +21,4 @@ jobs:
2121
# Assign the PR to whomever created it. This is useful for visualizing assignments on project boards
2222
# See https://github.com/toshimaru/auto-author-assign
2323
- name: Assign PR to creator
24-
uses: toshimaru/auto-author-assign@v2.1.0
24+
uses: toshimaru/auto-author-assign@v3.0.1

config/config.example.yml

Lines changed: 92 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,9 @@ ui:
88
ssl: false
99
host: localhost
1010
port: 4000
11+
# Specify the public URL that this user interface responds to. This corresponds to the "dspace.ui.url" property in your backend's local.cfg.
12+
# SSR is only enabled when the client's "Host" HTTP header matches this baseUrl. The baseUrl is also used for redirects and SEO links (in robots.txt).
13+
baseUrl: http://localhost:4000
1114
# NOTE: Space is capitalized because 'namespace' is a reserved string in TypeScript
1215
nameSpace: /
1316
# The rateLimiter settings limit each IP to a 'limit' of 500 requests per 'windowMs' (1 minute).
@@ -240,7 +243,12 @@ submission:
240243
- value: default
241244
style: text-muted
242245
icon: fa-circle-xmark
243-
246+
# Icons to be displayed next to an authority controlled value, to give indication of the source.
247+
sourceIcons:
248+
# Example of configuration for authority logo based on sources.
249+
# The configured icon will be displayed next to the authority value in submission and on item page or search results.
250+
- source: orcid
251+
- path: assets/images/orcid.logo.icon.svg
244252
# Fallback language in which the UI will be rendered if the user's browser language is not an active language
245253
fallbackLanguage: en
246254

@@ -400,6 +408,30 @@ item:
400408
pageSize: 5
401409
# Show the bitstream access status label on the item page
402410
showAccessStatuses: false
411+
# Configuration of metadata to be displayed in the item metadata link view popover
412+
metadataLinkViewPopoverData:
413+
# Metdadata list to be displayed for entities without a specific configuration
414+
fallbackMetdataList:
415+
- dc.description.abstract
416+
- dc.description.note
417+
# Configuration for each entity type
418+
entityDataConfig:
419+
- entityType: Person
420+
# Descriptive metadata (popover body)
421+
metadataList:
422+
- person.affiliation.name
423+
- person.email
424+
# Title metadata (popover header)
425+
titleMetadataList:
426+
- person.givenName
427+
- person.familyName
428+
# Configuration for identifier subtypes, based on metadata like dc.identifier.ror where ror is the subtype.
429+
# This is used to map the layout of the identifier in the popover and the icon displayed next to the metadata value.
430+
identifierSubtypes:
431+
- name: ror
432+
icon: assets/images/ror.logo.icon.svg
433+
iconPosition: IdentifierSubtypesIconPositionEnum.LEFT
434+
link: https://ror.org
403435

404436
# Community Page Config
405437
community:
@@ -649,3 +681,62 @@ geospatialMapViewer:
649681
accessibility:
650682
# The duration in days after which the accessibility settings cookie expires
651683
cookieExpirationDuration: 7
684+
685+
# Configuration for layout customization of metadata rendering in Item page
686+
# Currently only the authority reference config is available, more will follow with the integration of the so called CRIS layout.
687+
layout:
688+
# Configuration of icons and styles to be used for each authority controlled link
689+
authorityRef:
690+
- entityType: DEFAULT
691+
entityStyle:
692+
default:
693+
icon: fa fa-user
694+
style: text-info
695+
- entityType: PERSON
696+
entityStyle:
697+
person:
698+
icon: fa fa-user
699+
style: text-success
700+
default:
701+
icon: fa fa-user
702+
style: text-info
703+
- entityType: ORGUNIT
704+
entityStyle:
705+
default:
706+
icon: fa fa-university
707+
style: text-success
708+
- entityType: PROJECT
709+
entityStyle:
710+
default:
711+
icon: fas fa-project-diagram
712+
style: text-success
713+
714+
# Configuration for customization of search results
715+
searchResults:
716+
# Metadata fields to be displayed in the search results under the standard ones
717+
additionalMetadataFields:
718+
- dc.contributor.author
719+
- dc.date.issued
720+
- dc.type
721+
# Metadata fields to be displayed in the search results for the author section
722+
authorMetadata:
723+
- dc.contributor.author
724+
- dc.creator
725+
- dc.contributor.*
726+
# When the search results are retrieved, for each item type the metadata with a valid authority value are inspected.
727+
# Referenced items will be fetched with a find all by id strategy to avoid individual rest requests
728+
# to efficiently display the search results.
729+
followAuthorityMetadata:
730+
- type: Publication
731+
metadata: dc.contributor.author
732+
- type: Product
733+
metadata: dc.contributor.author
734+
735+
# The maximum number of item to process when following authority metadata values.
736+
followAuthorityMaxItemLimit: 100
737+
738+
# The maximum number of metadata values to process for each metadata key
739+
# when following authority metadata values.
740+
followAuthorityMetadataValuesLimit: 5
741+
742+
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
describe('Limit public config properties', () => {
2+
it('Should not include cache.serverSide properties in the html source code',
3+
() => {
4+
cy.request('/').its('body').then((text: string) => {
5+
expect(text).to.not.contain('"serverSide":');
6+
});
7+
},
8+
);
9+
it('Should not include cache.serverSide properties in the config.json',
10+
() => {
11+
cy.request('/assets/config.json').its('body').then((obj: any) => {
12+
expect(obj.cache).to.not.haveOwnProperty('serverSide');
13+
});
14+
},
15+
);
16+
});

docker/cli.assetstore.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ services:
1616
dspace-cli:
1717
environment:
1818
# This assetstore zip is available from https://github.com/DSpace-Labs/AIP-Files/releases/tag/demo-entities-data
19-
- LOADASSETS=https://github.com/DSpace-Labs/AIP-Files/releases/download/demo-entities-data/assetstore.tar.gz
19+
- LOADASSETS=${LOADASSETS:-https://github.com/DSpace-Labs/AIP-Files/releases/download/demo-entities-data/assetstore.tar.gz}
2020
entrypoint:
2121
- /bin/bash
2222
- '-c'

0 commit comments

Comments
 (0)