Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
63 commits
Select commit Hold shift + click to select a range
d07b8e5
CAS_API_TOKEN
NishaSharma14 Oct 9, 2025
3043071
run formatting
NishaSharma14 Oct 9, 2025
ebaee12
fix: create seperate service for CAS APi integration
NishaSharma14 Oct 9, 2025
a1ec532
copilot review changes
NishaSharma14 Oct 9, 2025
a512f25
fix review comments
NishaSharma14 Oct 12, 2025
d534190
fix: controller and service function naming updates and other minor …
vcnainala Oct 27, 2025
acdc622
fix: enabled env based cas provider configuration
vcnainala Oct 27, 2025
62d5c57
chore: pint changes
vcnainala Oct 27, 2025
ac6f7aa
Merge pull request #1274 from NFDI4Chem/implement-CAS-import-issue#578
vcnainala Oct 27, 2025
29db366
feat: refactor support bubble to block spamming. (#1281)
NishaSharma14 Oct 27, 2025
c8321ad
fix: removed recaptcha from env example
NishaSharma14 Oct 28, 2025
a7a84c2
chore: configure laravel CSP (#1272)
NishaSharma14 Oct 28, 2025
0037bcc
fix: update Nmrxiv policy and routes fro csp
NishaSharma14 Oct 29, 2025
9c66cd2
fix: add additional CSP sources via environment variables
NishaSharma14 Oct 29, 2025
036d81b
pint formatting
NishaSharma14 Oct 29, 2025
40ffa98
Merge branch 'main' into development
NishaSharma14 Oct 30, 2025
de54c76
revert csp tags in dev images
NishaSharma14 Oct 30, 2025
52390b9
feat: enable search,filtering & pagination, unify badge logic project…
NishaSharma14 Nov 24, 2025
f36df77
feat: csp fixes and add missing endpoints in the policy (#1284)
NishaSharma14 Nov 24, 2025
ef86ddf
feat: add test and coverage workflow (#1286)
NishaSharma14 Nov 24, 2025
0ca6a6c
feat: add tests for models (#1288)
NishaSharma14 Dec 2, 2025
039e405
feat: project test (#1289)
NishaSharma14 Dec 2, 2025
95ddd5e
chore: csp optimization (#1299)
NishaSharma14 Dec 2, 2025
8079434
feat: add tests for study features (#1291)
NishaSharma14 Dec 2, 2025
562fb7e
feat:add test for draft feature and draft actions (#1293)
NishaSharma14 Dec 2, 2025
a96d955
test: add test for FileSystemController
NishaSharma14 Dec 3, 2025
9bfd014
rename FileSystemControllerTest.php to FileSystemTest.php
NishaSharma14 Dec 3, 2025
d667cd5
Merge remote-tracking branch 'origin/main' into development
NishaSharma14 Dec 3, 2025
13cf51c
fix: update composer.lock file
NishaSharma14 Dec 3, 2025
35123e2
fix:remove the test test_user_drafts_action_gets_user_drafts
NishaSharma14 Dec 3, 2025
2988cab
Merge branch 'development' into filesystem-test
vcnainala Dec 4, 2025
7d31cf9
build: upgrade PHP from 8.2 to 8.4 (#1307)
NishaSharma14 Dec 4, 2025
e27fe30
test: add announcement feature test
NishaSharma14 Dec 4, 2025
f4b3928
test: add application feature test
NishaSharma14 Dec 4, 2025
0a904db
test: add test for CAS integration
NishaSharma14 Dec 4, 2025
57ed601
test: add test for dashboard controller
NishaSharma14 Dec 4, 2025
a422076
test: add test for download controller
NishaSharma14 Dec 4, 2025
597c170
test: add test for file upload feature
NishaSharma14 Dec 4, 2025
3478f76
test: add tests for the admin controller
NishaSharma14 Dec 4, 2025
3520922
Merge remote-tracking branch 'origin/filesystem-test' into controller…
NishaSharma14 Dec 4, 2025
080fe80
fix: remove duplicate AnnouncementTest.php file
NishaSharma14 Dec 4, 2025
468ad7d
fix: rectify namespace in AnnouncementTest
NishaSharma14 Dec 4, 2025
023fc5b
fix: copilot review changes
NishaSharma14 Dec 5, 2025
2fc23ff
Merge pull request #1310 from NFDI4Chem/controller-test
vcnainala Dec 11, 2025
6637646
test: add test for dataset controller. (#1314)
NishaSharma14 Dec 11, 2025
2c3b4cf
fix: update qs to address security vulnerability
NishaSharma14 Jan 6, 2026
69edb6c
fix: update aws-sdk-php to address security vulnerability
NishaSharma14 Jan 6, 2026
b53d08d
Merge pull request #1327 from NFDI4Chem/npm-security-fix
NishaSharma14 Jan 6, 2026
9ec919e
fix: Preact security vulnerability issue (#1332)
NishaSharma14 Jan 12, 2026
381b71c
test: Add API endpoint tests (#1313)
NishaSharma14 Jan 12, 2026
1fa2b0d
feat: ROR integration for users and authors affiliation (#1316)
NishaSharma14 Jan 12, 2026
1d2d7b6
fix: CORS issue with ORCID API and refactoring ORCID integration (#1317)
NishaSharma14 Jan 12, 2026
4173d1c
test: Add missing tests for controllers (#1318)
NishaSharma14 Jan 12, 2026
b427579
test: Add test for services (#1320)
NishaSharma14 Jan 12, 2026
15c9594
fix: remove duplicate AuthorService and update ProcessDraftELNSubmiss…
NishaSharma14 Jan 12, 2026
0531d7b
chore: update docker image to php 8.4 (#1329)
NishaSharma14 Jan 12, 2026
d8140b5
test: Add tests for email notifications in services (#1322)
NishaSharma14 Jan 12, 2026
a4308ac
test: Add unit tests for job classes (#1325)
NishaSharma14 Jan 12, 2026
b885459
fix: Fix the broken recommended standards link (#1334)
NishaSharma14 Jan 12, 2026
03cf9c3
fix: API throttling condition for testing environment to fix FrankenP…
NishaSharma14 Jan 15, 2026
817f3d6
test: resturcture team tests into a dedicated directory (#1324)
NishaSharma14 Jan 16, 2026
7271b48
build: add smoke test for worker and app docker images and other impr…
NishaSharma14 Jan 16, 2026
0a1a06c
Add smoke test frankenphp (#1340)
NishaSharma14 Jan 16, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
68 changes: 60 additions & 8 deletions .env.ci.test → .env.ci
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,15 @@ APP_ENV=development
APP_KEY=
APP_DEBUG=true
APP_URL=http://localhost:80

APP_LOCALE=en
APP_FALLBACK_LOCALE=en
APP_FAKER_LOCALE=en_US
APP_MAINTENANCE_DRIVER=file
APP_MAINTENANCE_STORE=database
PHP_CLI_SERVER_WORKERS=4

BCRYPT_ROUNDS=12
APP_DESCRIPTION='nmrXiv is currently developed as the FAIR, consensus-driven NMR data repository and computational platform. The ultimate goal is to accelerate broader coordination and data sharing among natural product (NP) researchers by enabling the storage, management, sharing and analysis of NMR data.'
COOL_OFF_PERIOD=10
SCHEMA_VERSION=beta
Expand All @@ -11,26 +20,32 @@ SHOW_BANNER=true

GITHUB_LICENSE_URL=https://api.github.com/licenses
EUROPEMC_WS_API=https://www.ebi.ac.uk/europepmc/webservices/rest/search
ORCID_ID_SEARCH_API=https://pub.orcid.org/v2.1/search
ORCID_ID_EMPLOYMENT_API=https://pub.orcid.org/v3.0/{orcid_id}/employments
ORCID_ID_PERSON_API=https://pub.orcid.org/v3.0/{orcid_id}/person
ORCID_BASE_URL=https://pub.orcid.org/v3.0
CM_API=https://api.cheminf.studio/latest/
CROSSREF_API=https://api.crossref.org/works/
DATACITE_API=https://api.datacite.org/
DATACITE_TEST_API=https://api.test.datacite.org

LOG_CHANNEL=stack
LOG_STACK=single
LOG_LEVEL=debug

DB_CONNECTION=pgsql
DB_HOST=127.0.0.1
DB_PORT=5432
DB_DATABASE=nmrxiv
DB_DATABASE=nmrxiv_test
DB_USERNAME=postgres
DB_PASSWORD=postgres
DB_PASSWORD=password

BROADCAST_CONNECTION=log
CACHE_STORE=file
FILESYSTEM_DRIVER=local
QUEUE_CONNECTION=redis
SESSION_DRIVER=redis
SESSION_LIFETIME=120
SESSION_ENCRYPT=false
SESSION_PATH=/
SESSION_DOMAIN=null

MEMCACHED_HOST=memcached

Expand Down Expand Up @@ -58,6 +73,7 @@ AWS_BUCKET=nmrxiv
AWS_BUCKET_PUBLIC=nmrxiv-public
AWS_ENDPOINT=https://s3.uni-jena.de
AWS_URL=https://s3.uni-jena.de
AWS_USE_PATH_STYLE_ENDPOINT=false

PUSHER_APP_ID=
PUSHER_APP_KEY=
Expand All @@ -67,9 +83,9 @@ PUSHER_APP_CLUSTER=mt1
MIX_PUSHER_APP_KEY="${PUSHER_APP_KEY}"
MIX_PUSHER_APP_CLUSTER="${PUSHER_APP_CLUSTER}"

SCOUT_DRIVER=meilisearch
SCOUT_PREFIX=dev_
MEILISEARCH_HOST=https://msdev.nmrxiv.org
SCOUT_DRIVER=null
SCOUT_PREFIX=test_
MEILISEARCH_HOST=http://localhost:7700/
MEILISEARCH_KEY=
MEILISEARCH_PUBLICKEY=

Expand All @@ -81,4 +97,40 @@ TWITTER_CLIENT_ID=
TWITTER_CLIENT_SECRET=
TWITTER_REDIRECT_URL=http://localhost:80/auth/login/twitter/callback

ORCID_CLIENT_ID=
ORCID_CLIENT_SECRET=
ORCID_REDIRECT_URL=http://localhost/auth/login/orcid/callback
ORCID_ENVIRONMENT=sandbox

NFDIAAI_CLIENT_ID=
NFDIAAI_CLIENT_SECRET=
NFDIAAI_REDIRECT_URL="${APP_URL}/auth/login/regapp/callback"

TELESCOPE_ENABLED=false

#DATACITE Properties
DOI_HOST=datacite
DATACITE_USERNAME=
DATACITE_SECRET=
DATACITE_PREFIX=
DATACITE_ENDPOINT=https://api.test.datacite.org

NMRKIT_URL=https://nodejs.nmrxiv.org
PUBCHEM_URL=https://pubchem.ncbi.nlm.nih.gov
COMMON_CHEMISTRY_URL=https://commonchemistry.cas.org/api
CAS_API_TOKEN=
CHEMISTRY_STANDARDIZE_URL=https://api.cheminf.studio/latest/chem/standardize

BACKUP_KEEP_DAYS=7

# CSP Configuration
CSP_ENABLED=true
CSP_REPORT_URI="/csp-violation-report"
CSP_NONCE_ENABLED=true
CSP_ENABLED_WHILE_HOT_RELOADING=false

# Additional CSP sources (comma-separated, no spaces)
# CSP_ADDITIONAL_CONNECT_SRC="https://api.example.com,https://analytics.example.com"
# CSP_ADDITIONAL_IMG_SRC="https://cdn.example.com,https://images.example.com"
# CSP_ADDITIONAL_SCRIPT_SRC="https://cdn.example.com"
# CSP_ADDITIONAL_STYLE_SRC="https://fonts.example.com"
31 changes: 24 additions & 7 deletions .env.example
Original file line number Diff line number Diff line change
Expand Up @@ -16,16 +16,19 @@ APP_DESCRIPTION='nmrXiv is currently developed as the FAIR, consensus-driven NMR
COOL_OFF_PERIOD=10
SCHEMA_VERSION=beta

MICHI_STANDARDS_URL=https://nfdi4chem.github.io/workshops/docs/michi/tabular/nmr/v1/table

SHOW_BANNER=true

GITHUB_LICENSE_URL=https://api.github.com/licenses
EUROPEMC_WS_API=https://www.ebi.ac.uk/europepmc/webservices/rest/search
ORCID_ID_SEARCH_API=https://pub.orcid.org/v2.1/search
ORCID_ID_EMPLOYMENT_API=https://pub.orcid.org/v3.0/{orcid_id}/employments
ORCID_ID_PERSON_API=https://pub.orcid.org/v3.0/{orcid_id}/person

ORCID_BASE_URL=https://pub.orcid.org/v3.0

CM_API=https://api.cheminf.studio/latest/
CROSSREF_API=https://api.crossref.org/works/
DATACITE_API=https://api.datacite.org/
DATACITE_TEST_API=https://api.test.datacite.org


LOG_CHANNEL=stack
Expand Down Expand Up @@ -115,12 +118,26 @@ DOI_HOST=datacite
DATACITE_USERNAME=
DATACITE_SECRET=
DATACITE_PREFIX=
DATACITE_ENDPOINT=
DATACITE_ENDPOINT=https://api.test.datacite.org

NMRKIT_URL=https://nodejs.nmrxiv.org
CAS_URL=https://commonchemistry.cas.org
PUBCHEM_URL=https://pubchem.ncbi.nlm.nih.gov
COMMON_CHEMISTRY_URL=https://commonchemistry.cas.org
COMMON_CHEMISTRY_URL=https://commonchemistry.cas.org/api
CAS_API_TOKEN=
CHEMISTRY_STANDARDIZE_URL=https://api.cheminf.studio/latest/chem/standardize

BACKUP_KEEP_DAYS=7
BACKUP_KEEP_DAYS=7

# CSP Configuration
CSP_ENABLED=true
CSP_NONCE_ENABLED=false
CSP_ENABLED_WHILE_HOT_RELOADING=false

# Additional CSP sources (comma-separated, no spaces)
# CSP_ADDITIONAL_CONNECT_SRC="https://api.example.com,https://analytics.example.com"
# CSP_ADDITIONAL_IMG_SRC="https://cdn.example.com,https://images.example.com"
# CSP_ADDITIONAL_SCRIPT_SRC="https://cdn.example.com"
# CSP_ADDITIONAL_STYLE_SRC="https://fonts.example.com"

ROR_API_URL=https://api.ror.org/organizations
ROR_CLIENT_ID=
58 changes: 34 additions & 24 deletions .github/workflows/dev-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,9 @@ env:
REPOSITORY_NAMESPACE: nfdi4chem

jobs:
# Lint and Security check
lint-security:
name: Lint & Security (reusable)
name: Lint & Security
uses: ./.github/workflows/lint-security-check.yml
permissions:
contents: read
Expand All @@ -27,11 +28,33 @@ jobs:
run_js: true
run_secrets: true

# Run tests and collect coverage
test-coverage:
name: Tests & Coverage
uses: ./.github/workflows/test-coverage.yml
needs: [lint-security]
secrets: inherit

# Smoke test Docker images before pushing
smoke-test:
name: Smoke test Docker images
uses: ./.github/workflows/docker-smoke-test.yml
needs: [test-coverage]

# Build and publish Docker images for the development environment
setup-build-publish-deploy:
name: Build & deploy to development
build-and-push:
name: Build & push to Docker Hub
runs-on: ubuntu-latest
needs: [lint-security]
needs: [test-coverage, smoke-test, lint-security]
strategy:
matrix:
image:
- name: app
file: ./deployment/Dockerfile
tag: app-dev-latest
- name: worker
file: ./deployment/Dockerfile.worker
tag: worker-dev-latest

# Environment provides secrets and protection rules
environment:
Expand All @@ -52,28 +75,15 @@ jobs:
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3

# Build + push app image (tag: app-dev-latest). Uses GHA cache for speed.
- name: Build and push App Docker image
uses: docker/build-push-action@v6
with:
context: .
file: ./deployment/Dockerfile
push: true
build-args: |
RELEASE_VERSION=app-dev-latest
tags: ${{ env.REPOSITORY_NAMESPACE }}/${{ env.REPOSITORY_NAME }}:app-dev-latest
cache-from: type=gha
cache-to: type=gha,mode=max

# Build + push worker image (tag: worker-dev-latest)
- name: Build and push Worker Docker image
# Build and push image
- name: Build and push ${{ matrix.image.name }} image
uses: docker/build-push-action@v6
with:
context: .
file: ./deployment/Dockerfile.worker
file: ${{ matrix.image.file }}
push: true
build-args: |
RELEASE_VERSION=worker-dev-latest
tags: ${{ env.REPOSITORY_NAMESPACE }}/${{ env.REPOSITORY_NAME }}:worker-dev-latest
cache-from: type=gha
cache-to: type=gha,mode=max
RELEASE_VERSION=${{ matrix.image.tag }}
tags: ${{ env.REPOSITORY_NAMESPACE }}/${{ env.REPOSITORY_NAME }}:${{ matrix.image.tag }}
cache-from: type=gha,scope=${{ matrix.image.name }}
cache-to: type=gha,mode=max,scope=${{ matrix.image.name }}
62 changes: 62 additions & 0 deletions .github/workflows/docker-smoke-test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,62 @@
name: Docker Image Smoke Tests

on:
workflow_call:

env:
REPOSITORY_NAME: nmrxiv
REPOSITORY_NAMESPACE: nfdi4chem

jobs:
smoke-test:
name: Smoke test containers
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
container:
- name: app
file: ./deployment/Dockerfile
wait-time: 60
- name: worker
file: ./deployment/Dockerfile.worker
wait-time: 60
steps:
- name: Checkout
uses: actions/checkout@v4

- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3

- name: Build and export ${{ matrix.container.name }} image
uses: docker/build-push-action@v6
with:
context: .
file: ${{ matrix.container.file }}
load: true
tags: ${{ env.REPOSITORY_NAMESPACE }}/${{ env.REPOSITORY_NAME }}:${{ matrix.container.name }}-test
cache-from: type=gha,scope=${{ matrix.container.name }}
cache-to: type=gha,mode=max,scope=${{ matrix.container.name }}

- name: Start ${{ matrix.container.name }} container
run: |
docker run -d --name nmrxiv-${{ matrix.container.name }}-test \
-e APP_KEY=base64:$(openssl rand -base64 32) \
-e APP_ENV=production \
-e DB_CONNECTION=sqlite \
-e CACHE_STORE=array \
-e SESSION_DRIVER=array \
-e QUEUE_CONNECTION=sync \
${{ env.REPOSITORY_NAMESPACE }}/${{ env.REPOSITORY_NAME }}:${{ matrix.container.name }}-test

- name: Wait for ${{ matrix.container.name }} container health
uses: stringbean/docker-healthcheck-action@v3
with:
container: nmrxiv-${{ matrix.container.name }}-test
wait-time: ${{ matrix.container.wait-time }}
require-status: running
require-healthy: true

- name: Cleanup ${{ matrix.container.name }} container
if: always()
run: docker rm -f nmrxiv-${{ matrix.container.name }}-test
2 changes: 1 addition & 1 deletion .github/workflows/lint-security-check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ jobs:
- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: '8.3'
php-version: '8.4'
coverage: none
tools: composer
extensions: mbstring, intl, pdo, pdo_mysql, pdo_pgsql
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: PR Lint & Security
name: PR Lint, Security and Tests

on:
pull_request:
Expand All @@ -10,6 +10,8 @@ on:
permissions:
contents: read
security-events: write
pull-requests: write
checks: write

jobs:
lint-security:
Expand All @@ -19,3 +21,8 @@ jobs:
run_php: true
run_js: true
run_secrets: true

test-coverage:
name: Tests & Coverage (PHP 8.4)
uses: ./.github/workflows/test-coverage.yml
secrets: inherit
Loading
Loading