Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Is it possible to change the base URL for /ngapimock/* calls? #74

Open
galanovnick opened this issue May 29, 2019 · 1 comment
Open

Comments

@galanovnick
Copy link

Is it possible to change the base URL for /ngapimock/* calls without using any proxy?
In most of the examples, we use proxy to redirect all these calls to our actual API server.

"/ngapimock/*": {
    "target": "http://localhost:9090",
    "secure": false,
    "logLevel": "debug"
  }

But such approach forces us to push all other API calls through the same proxy because otherwise, as far as I understand, the cookie (or session id?) will differ so selectScenario won't have any effect.

So if for example, we have our UI hosted on the port 4200 and API server on 9090 we can't change any scenario because the cookie is set to 4200 and not to 9090. Does it mean that our UI is limited to http://localhost:4200/* for API calls? And what if UI is already using http://localhost:9090/* and requires no proxy?

@galanovnick galanovnick changed the title Can we change the base URL for /ngapimock/* calls Is it possible to change the base URL for /ngapimock/* calls? May 30, 2019
@mdasberg
Copy link
Owner

mdasberg commented Mar 3, 2020

I have a task on the backlog to make this configurable in the new version.

ng-apimock/base-client#5

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants