[SOLVED] IIS self hosting not working

Just starting to try self hosting on IIS with the default project (My First Project) and only parts of it load, errors like “Invalid magic number found in glb header. Expected 0x46546C67, found 0x4f44213c” playcanvas-stable.min.js

Since I’ve made no changes to the project, does it mean there’s a problem self hosting on IIS with PlayCanvas? Sorry to ask but literally just getting started and found nothing useful from a web search. Would be good to at least prove that self hosting works.

Thanks

Not an expert but you may need to make configuration changes on how the files are served on IIS. If you bring up the network tab in your browser, you can see the mime-type of the GLB files, what does it say?

You may also need to do this with other file types too

Brilliant, you are an expert after all - I’d added wasm but not glb - would be good if PlayCanvas added required mime types to their documentation.

All working - I can test a bit more now.

Thank you

Added as an issue to the GitHub: https://github.com/playcanvas/developer.playcanvas.com/issues/357

1 Like

Hi = I’m getting this now on my netlify hosted version - but have no idea how to fix it. I’ve not had this before with any other hosted builds either :confused:

Invalid magic number found in glb header. Expected 0x46546C67, found 0x73726576
(anonymous) @ playcanvas-stable.min.js?WB_REVISION=4421419ba9d4f9e476f2c8015bae9dca:6
(anonymous) @ playcanvas-stable.min.js?WB_REVISION=4421419ba9d4f9e476f2c8015bae9dca:6
(anonymous) @ playcanvas-stable.min.js?WB_REVISION=4421419ba9d4f9e476f2c8015bae9dca:6
(anonymous) @ playcanvas-stable.min.js? etc.etc.

any help mucho apreciato !

Hi @jerryComo,

Can you try re-importing all WASM libraries used in your project? Delete Ammo, Basis, Draco folders and re-import from the project settings.

It may be the case a library got updated and fails to pass a test.

1 Like