fix(dev): update webpack proxy config syntax for Orthanc dev mode (#5531)
* fix(dev): update webpack proxy config syntax for Orthanc dev mode * Add datasources and rename dicomweb to orthancProxy datasource --------- Co-authored-by: Nilesh Gautam <nilesh.gautam@radpretation.ai> Co-authored-by: Bill Wallace <wayfarer3130@gmail.com>
This commit is contained in:
parent
bb45cb24b5
commit
58aa0d1eaa
@ -183,15 +183,16 @@ module.exports = (env, argv) => {
|
|||||||
|
|
||||||
if (hasProxy) {
|
if (hasProxy) {
|
||||||
mergedConfig.devServer.proxy = mergedConfig.devServer.proxy || {};
|
mergedConfig.devServer.proxy = mergedConfig.devServer.proxy || {};
|
||||||
mergedConfig.devServer.proxy = {
|
mergedConfig.devServer.proxy = [
|
||||||
[PROXY_TARGET]: {
|
{
|
||||||
|
context: [PROXY_PATH_REWRITE_FROM || '/dicomweb'],
|
||||||
target: PROXY_DOMAIN,
|
target: PROXY_DOMAIN,
|
||||||
changeOrigin: true,
|
changeOrigin: true,
|
||||||
pathRewrite: {
|
pathRewrite: {
|
||||||
[`^${PROXY_PATH_REWRITE_FROM}`]: PROXY_PATH_REWRITE_TO,
|
[`^${PROXY_PATH_REWRITE_FROM}`]: PROXY_PATH_REWRITE_TO,
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
};
|
];
|
||||||
}
|
}
|
||||||
|
|
||||||
if (isProdBuild) {
|
if (isProdBuild) {
|
||||||
|
|||||||
@ -16,11 +16,11 @@ window.config = {
|
|||||||
maxNumPrefetchRequests: 10,
|
maxNumPrefetchRequests: 10,
|
||||||
order: 'closest',
|
order: 'closest',
|
||||||
},
|
},
|
||||||
defaultDataSourceName: 'dicomweb',
|
defaultDataSourceName: 'orthancProxy',
|
||||||
dataSources: [
|
dataSources: [
|
||||||
{
|
{
|
||||||
namespace: '@ohif/extension-default.dataSourcesModule.dicomweb',
|
namespace: '@ohif/extension-default.dataSourcesModule.dicomweb',
|
||||||
sourceName: 'dicomweb',
|
sourceName: 'orthancProxy',
|
||||||
configuration: {
|
configuration: {
|
||||||
friendlyName: 'Orthanc Server',
|
friendlyName: 'Orthanc Server',
|
||||||
name: 'Orthanc',
|
name: 'Orthanc',
|
||||||
@ -34,6 +34,59 @@ window.config = {
|
|||||||
omitQuotationForMultipartRequest: true,
|
omitQuotationForMultipartRequest: true,
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
namespace: '@ohif/extension-default.dataSourcesModule.dicomweb',
|
||||||
|
sourceName: 'ohif',
|
||||||
|
configuration: {
|
||||||
|
friendlyName: 'AWS S3 Static wado server',
|
||||||
|
name: 'aws',
|
||||||
|
wadoUriRoot: 'https://d14fa38qiwhyfd.cloudfront.net/dicomweb',
|
||||||
|
qidoRoot: 'https://d14fa38qiwhyfd.cloudfront.net/dicomweb',
|
||||||
|
wadoRoot: 'https://d14fa38qiwhyfd.cloudfront.net/dicomweb',
|
||||||
|
qidoSupportsIncludeField: false,
|
||||||
|
imageRendering: 'wadors',
|
||||||
|
thumbnailRendering: 'wadors',
|
||||||
|
enableStudyLazyLoad: true,
|
||||||
|
supportsFuzzyMatching: true,
|
||||||
|
supportsWildcard: false,
|
||||||
|
staticWado: true,
|
||||||
|
singlepart: 'bulkdata,video',
|
||||||
|
// whether the data source should use retrieveBulkData to grab metadata,
|
||||||
|
// and in case of relative path, what would it be relative to, options
|
||||||
|
// are in the series level or study level (some servers like series some study)
|
||||||
|
bulkDataURI: {
|
||||||
|
enabled: true,
|
||||||
|
relativeResolution: 'studies',
|
||||||
|
transform: url => url.replace('/pixeldata.mp4', '/rendered'),
|
||||||
|
},
|
||||||
|
omitQuotationForMultipartRequest: true,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
{
|
||||||
|
namespace: '@ohif/extension-default.dataSourcesModule.dicomweb',
|
||||||
|
sourceName: 'local5000',
|
||||||
|
configuration: {
|
||||||
|
friendlyName: 'Static WADO Local Data',
|
||||||
|
name: 'DCM4CHEE',
|
||||||
|
qidoRoot: 'http://localhost:5000/dicomweb',
|
||||||
|
wadoRoot: 'http://localhost:5000/dicomweb',
|
||||||
|
qidoSupportsIncludeField: false,
|
||||||
|
supportsReject: true,
|
||||||
|
supportsStow: true,
|
||||||
|
imageRendering: 'wadors',
|
||||||
|
thumbnailRendering: 'wadors',
|
||||||
|
enableStudyLazyLoad: true,
|
||||||
|
supportsFuzzyMatching: false,
|
||||||
|
supportsWildcard: true,
|
||||||
|
staticWado: true,
|
||||||
|
singlepart: 'video',
|
||||||
|
bulkDataURI: {
|
||||||
|
enabled: true,
|
||||||
|
relativeResolution: 'studies',
|
||||||
|
},
|
||||||
|
},
|
||||||
|
},
|
||||||
|
|
||||||
{
|
{
|
||||||
namespace: '@ohif/extension-default.dataSourcesModule.dicomjson',
|
namespace: '@ohif/extension-default.dataSourcesModule.dicomjson',
|
||||||
sourceName: 'dicomjson',
|
sourceName: 'dicomjson',
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user