Update absolute url config variables.

This commit is contained in:
softsimon 2020-11-23 14:50:28 +07:00
parent aaf9d9be9f
commit e5959f14bc
No known key found for this signature in database
GPG Key ID: 488D7DCFB5A430D7
2 changed files with 3 additions and 2 deletions

View File

@ -67,7 +67,8 @@ export function app(): express.Express {
}));
server.get('/api/v1/**', createProxyMiddleware({
target: 'http://localhost:8999',
// @ts-ignore
target: win.__env.BACKEND_ABSOLUTE_URL,
changeOrigin: true,
},
));

View File

@ -18,7 +18,7 @@ export class AssetsService {
) {
let baseApiUrl = '';
if (!this.stateService.isBrowser) {
baseApiUrl = this.stateService.env.ELECTRS_ABSOLUTE_URL;
baseApiUrl = this.stateService.env.BACKEND_ABSOLUTE_URL;
}
this.getAssetsJson$ = this.httpClient.get(baseApiUrl + '/resources/assets.json').pipe(shareReplay());