Select to view content in your preferred language

WAB application created on Windows fails to open on a Mac

1716
4
Jump to solution
09-25-2016 06:45 PM
StephenLead
Honored Contributor

Should it be possible to run a Web AppBuilder application on a Mac?

  1. I'm using the Developer edition of WAB on Windows 7 to create a simple WAB application
  2. I Download the application from WAB and put it in the Windows machine's /inetpub/wwwroot/xyz folder
  3. the application works as expected when accessed via http://localhost/xyz  on the Windows machine
  4. I zip up the application and copy it across to a Mac which is running Apache, and put it in the /Library/WebServer/Documents/xyz folder
  5. the application fails to run on the Mac, with multiple 404 errors:

404 errors

eg: http://localhost/http://localhost//jsapi/jsapi/dojo/resources/dojo.css Failed to load resource: the server responded with a status of 404 (Not Found)

Why is the path referencing localhost twice (http://localhost/http://localhost//jsapi/)? Note that this doesn't occur on the Windows machine.

Is a WAB application supported on a Mac? thanks

1 Solution

Accepted Solutions
QunSun
by Esri Contributor
Esri Contributor

Hi Steve,

I guess you don't set apiUrl manually. If so, WAB will calculate apiUrl automatically.

Mostly, when you deploy the app, you should set apiUrl in env.js as the following screenshot.

Have a try.

View solution in original post

4 Replies
RobertScheitlin__GISP
MVP Emeritus

Stephen,

   Are you using a local install of the JS API in your web app?

0 Kudos
StephenLead
Honored Contributor

Hi Robert,

No, it's a vanilla WAB installation and a simple application with nothing fancy in it. The strange thing is that the identical code works on Windows, while failing on the Mac.

It's not a big deal as I can run it on the Windows VM on the Mac, so I guess I'm just curious as to why it doesn't work there.

Thanks,

Steve

0 Kudos
QunSun
by Esri Contributor
Esri Contributor

Hi Steve,

I guess you don't set apiUrl manually. If so, WAB will calculate apiUrl automatically.

Mostly, when you deploy the app, you should set apiUrl in env.js as the following screenshot.

Have a try.

LibertadChapinalC
New Contributor

Hi!

This error has also happened to me on windows!

QunSun's solution worked for me but I've seen that code is commented only if you copy the app from the server/apps folder. However, if you download the app of the WAB itself, everything comes without comment and is ready to deploy.

0 Kudos