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

Unable to omit admin ui in prod due to metricSummary #2261

Closed
Conor-Burns opened this issue Jul 1, 2023 · 1 comment
Closed

Unable to omit admin ui in prod due to metricSummary #2261

Conor-Burns opened this issue Jul 1, 2023 · 1 comment
Assignees
Labels
type: bug 🐛 Something isn't working

Comments

@Conor-Burns
Copy link
Contributor

Describe the bug
We build a docker image for the vendure backend and deploy the admin UI as a static app on cloudflare pages. When omitting the AdminUiPlugin from the config we get a clean docker image but no metric in the ui as the plugin isn't loaded. The graphql extensions for the metrics seem to come directly from the AdminUiPlugin, which isn't ideal for a setup like this.

To Reproduce

  1. omit AdminUiPlugin
  2. deploy static admin UI
  3. add metrics
  4. Error: Unknown type "MetricType". Cannot query field "metricSummary" on type "Query".

Expected behavior
being able to add AdminUiPlugin without any config to just load it
Environment (please complete the following information):

  • @vendure/core version: 2.0.2
  • Nodejs version 18 lts
  • Database (mysql/postgres etc): postgres

Additional context
In the mean time we bundle the UI also in the backend

@Conor-Burns Conor-Burns added the type: bug 🐛 Something isn't working label Jul 1, 2023
@michaelbromley
Copy link
Member

I'm going to make it so you can add just AdminUiPlugin without the init() call, and it will just expose the metrics query without then serving the Admin UI app.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: bug 🐛 Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants