Export config to develop/debug locally ?

29 views
Skip to first unread message

Charles Moulliard

unread,
May 27, 2021, 1:12:19 PM5/27/21
to WTracks
Hi,

Is it possible to export the configs (Api keys, maps, ...) of what we customized on "https://opoto.github.io/" to re-use it for local development/debug on macos ?

Cheers

Charles

Charles Moulliard

unread,
May 27, 2021, 1:22:16 PM5/27/21
to WTracks
Additional question: Do we have to configure something locally when we launch a HTTP server "python3 -m http.server 8080" as I cannot use a new WMS map even if it has been imported successfully ?

Olivier POTONNIEE

unread,
May 27, 2021, 2:56:10 PM5/27/21
to WTracks
Hello.
Yes, you can export/import settings in the Settings tab.
Note that maps are exported separately in the maps editor page.
I don't get your question on server config. Maybe related to some CORS issues?
Regards

Charles Moulliard

unread,
May 28, 2021, 1:51:06 AM5/28/21
to WTracks
Cool, I will test the import/export setting option :-)

Here is the problem that I observe to use another map when server runs locally
- Git clone the project and in a terminal move to the path of  the project
- Launch a http server (e.g. python3 -m http.serverr 8080)
- Open your browser at the address : http://localhost:8080
- Check that map exist at the address "http://localhost:8080/maps.html"
- "BE CartoWeb" entry exists
- Go back - "<< Back to WTracks editor"
- Move your mouse over the layers icon

Olivier POTONNIEE

unread,
May 28, 2021, 2:59:21 AM5/28/21
to WTracks
I can't test before next week, but I believe this is because your server is http instead of expected https.
So either:
- setup https on your local environment
- change line 2007 of js/wtracks.js:
if (protocol.length == 0 || protocol == location.protocol) {
to
if (true) {

Hope this helps.
--
Olivier

Charles Moulliard

unread,
May 28, 2021, 1:05:29 PM5/28/21
to WTracks

Many thanks. The trick works :-)
Reply all
Reply to author
Forward
0 new messages