Code Monkey home page Code Monkey logo

Comments (4)

spetruzza avatar spetruzza commented on August 17, 2024

I've been thinking about this problem. I guess the solution would be to have a config file for the viewer (e.g. a config.js file) that sets the right "things" for the specific deployment.
So that you can place the code everywhere you want but change the configuration on each machine. For example, if the deployment of this viewer is done through docker it should point to localhost (to the local server) by default, this is not true for other deployments.
What do you think? (@cchriste @scrgiorgio)

from openvisusjs.

cchriste avatar cchriste commented on August 17, 2024

It's not even so nice for Docker deployments: if you run a docker on one machine but try to access its web viewer from another machine, "localhost" in this case will still refer to the client machine, not the server.

from openvisusjs.

spetruzza avatar spetruzza commented on August 17, 2024

from openvisusjs.

spetruzza avatar spetruzza commented on August 17, 2024

Now the viewer.html includes src/config.js that contains a variable to set the URL of the server.

This can be edited for each deployment.

from openvisusjs.

Related Issues (15)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.