I’ve tried running a fairly bare-bones Apollo-server on Galaxy, everything works on local development. Turns out, that GraphIQL no longer works with the --production flag. Does anyone know why and how to resolve the issue?
GraphIQL gives me:
The script has an unsupported MIME type ('text/html').
The error msg above was due to a serviceworker, remove the sw and doesn’t appear anymore.
GraphiQL still shows nothing, with no error messages at all though. Just a blank page (dependencies are being loaded though)
/edit
what I noticed is that Meteor doesn’t load the react js and css in production
I don’t have a client folder and there’s basically nothing aside from the server import to initialize apollo server.
/edit
// default server configuration object // 14
var defaultServerConfig = { // 15
// graphql endpoint // 16
path: '/graphql', // 17
// additional Express server configuration (enable CORS there for instance) // 18
configServer: function (graphQLServer) {}, // 19
// enable GraphiQL only in development mode // 20
graphiql: Meteor.isDevelopment, // 21
// GraphiQL endpoint // 22
graphiqlPath: '/graphiql', // 23
// GraphiQL options (default: log the current user in your request) // 24
graphiqlOptions: { // 25
passHeader: "'meteor-login-token': localStorage['Meteor.loginToken']" // 26
} // 25
}; // default graphql options to enhance the graphQLExpress server // 15
I guess this is the intended behavior. Probably since as you said, securing GraphiQL might be challenging.