Skip to content

Commit

Permalink
O3-2753: Separate spa-build-config from spa-assemble-config (#779)
Browse files Browse the repository at this point in the history
  • Loading branch information
ibacher authored Jan 23, 2024
1 parent 8fabc52 commit 158db61
Show file tree
Hide file tree
Showing 3 changed files with 42 additions and 38 deletions.
3 changes: 2 additions & 1 deletion frontend/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,11 @@ ARG APP_SHELL_VERSION=next
RUN mkdir -p /app
WORKDIR /app

COPY spa-assemble-config.json .
COPY spa-build-config.json .

ARG CACHE_BUST
RUN npx --legacy-peer-deps openmrs@${APP_SHELL_VERSION:-next} assemble --manifest --mode config --config spa-build-config.json --target ./spa
RUN npx --legacy-peer-deps openmrs@${APP_SHELL_VERSION:-next} assemble --manifest --mode config --config spa-assemble-config.json --target ./spa
RUN npx --legacy-peer-deps openmrs@${APP_SHELL_VERSION:-next} build --build-config spa-build-config.json --target ./spa
RUN if [ ! -f ./spa/index.html ]; then echo 'Build failed. Please check the logs above for details. This may have happened because of an update to a library that OpenMRS depends on.'; exit 1; fi

Expand Down
40 changes: 40 additions & 0 deletions frontend/spa-assemble-config.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
{
"frontendModules": {
"@openmrs/esm-devtools-app": "next",
"@openmrs/esm-implementer-tools-app": "next",
"@openmrs/esm-login-app": "next",
"@openmrs/esm-primary-navigation-app": "next",
"@openmrs/esm-home-app": "next",
"@openmrs/esm-form-entry-app": "next",
"@openmrs/esm-generic-patient-widgets-app": "next",
"@openmrs/esm-patient-allergies-app": "next",
"@openmrs/esm-patient-appointments-app": "next",
"@openmrs/esm-patient-attachments-app": "next",
"@openmrs/esm-patient-banner-app": "next",
"@openmrs/esm-patient-chart-app": "next",
"@openmrs/esm-patient-conditions-app": "next",
"@openmrs/esm-patient-forms-app": "next",
"@openmrs/esm-patient-flags-app": "next",
"@openmrs/esm-patient-immunizations-app": "next",
"@openmrs/esm-patient-labs-app": "next",
"@openmrs/esm-patient-lists-app": "next",
"@openmrs/esm-patient-medications-app": "next",
"@openmrs/esm-patient-notes-app": "next",
"@openmrs/esm-patient-orders-app": "next",
"@openmrs/esm-patient-programs-app": "next",
"@openmrs/esm-patient-vitals-app": "next",
"@openmrs/esm-active-visits-app": "next",
"@openmrs/esm-appointments-app": "next",
"@openmrs/esm-service-queues-app": "next",
"@openmrs/esm-patient-list-management-app": "next",
"@openmrs/esm-patient-registration-app": "next",
"@openmrs/esm-patient-search-app": "next",
"@openmrs/esm-openconceptlab-app": "next",
"@openmrs/esm-system-admin-app": "next",
"@openmrs/esm-dispensing-app": "next",
"@openmrs/esm-fast-data-entry-app": "next",
"@openmrs/esm-cohort-builder-app": "next",
"@openmrs/esm-form-builder-app": "next"
},
"excludedFrontendModules": []
}
37 changes: 0 additions & 37 deletions frontend/spa-build-config.json
Original file line number Diff line number Diff line change
@@ -1,41 +1,4 @@
{
"frontendModules": {
"@openmrs/esm-devtools-app": "next",
"@openmrs/esm-implementer-tools-app": "next",
"@openmrs/esm-login-app": "next",
"@openmrs/esm-primary-navigation-app": "next",
"@openmrs/esm-home-app": "next",
"@openmrs/esm-form-entry-app": "next",
"@openmrs/esm-generic-patient-widgets-app": "next",
"@openmrs/esm-patient-allergies-app": "next",
"@openmrs/esm-patient-appointments-app": "next",
"@openmrs/esm-patient-attachments-app": "next",
"@openmrs/esm-patient-banner-app": "next",
"@openmrs/esm-patient-chart-app": "next",
"@openmrs/esm-patient-conditions-app": "next",
"@openmrs/esm-patient-forms-app": "next",
"@openmrs/esm-patient-flags-app": "next",
"@openmrs/esm-patient-immunizations-app": "next",
"@openmrs/esm-patient-labs-app": "next",
"@openmrs/esm-patient-lists-app": "next",
"@openmrs/esm-patient-medications-app": "next",
"@openmrs/esm-patient-notes-app": "next",
"@openmrs/esm-patient-orders-app": "next",
"@openmrs/esm-patient-programs-app": "next",
"@openmrs/esm-patient-vitals-app": "next",
"@openmrs/esm-active-visits-app": "next",
"@openmrs/esm-appointments-app": "next",
"@openmrs/esm-service-queues-app": "next",
"@openmrs/esm-patient-list-management-app": "next",
"@openmrs/esm-patient-registration-app": "next",
"@openmrs/esm-patient-search-app": "next",
"@openmrs/esm-openconceptlab-app": "next",
"@openmrs/esm-system-admin-app": "next",
"@openmrs/esm-dispensing-app": "next",
"@openmrs/esm-fast-data-entry-app": "next",
"@openmrs/esm-cohort-builder-app": "next",
"@openmrs/esm-form-builder-app": "next"
},
"spaPath": "$SPA_PATH",
"apiUrl": "$API_URL",
"configUrls": ["$SPA_CONFIG_URLS"],
Expand Down

0 comments on commit 158db61

Please sign in to comment.