SystemLink Forum

cancel
Showing results for 
Search instead for 
Did you mean: 

Using Skyline Tags and Web VIs with NI Web Server vs other web servers

During the tutorials, it is mentioned that WebVI's created with NXG can be hosted by the NI Web Server or by any other web server. I assume that is true if the WebVI's do not include Skyline APIs. E.g. if we want to use Skyline Tags, then I am guessing that we need to install the NI Web Server. Is that correct? I just did such an install, and I did not see any way to install JUST Skyline support. E.g. if we are going to use a different web server, can we install something such that the Skyline API works? Or can we host the html code on the other web server, and have the NI Web Server installed on the same machine just to handle the Skyline API?

Thanks,

       DaveT

-------------------------------------------------------------
David Thomson Original Code Consulting
www.originalcode.com
National Instruments Alliance Program Member
Certified LabVIEW Architect
Certified Embedded Systems Developer
-------------------------------------------------------------
There are 10 kinds of people: those who understand binary, and those who don't.
0 Kudos
Message 1 of 5
(3,744 Views)

@Dave_Thomson
I assume that is true if the WebVI's do not include Skyline APIs. E.g. if we want to use Skyline Tags, then I am guessing that we need to install the NI Web Server.

This is correct. The Skyline Data Services are applications running on the NI Web Server and we don't have a way of installing that support on another web server.

-----------------------------------------------
Brandon Grey
Certified LabVIEW Architect

0 Kudos
Message 2 of 5
(3,708 Views)

Thanks, Brandon.
Just to clarify, though: If you do use Skyline, then you need the NI Web Server installed on the server machine. Does that mean that your htlm also MUST be hosted by NI Web Server? I imagine you could point your browser to another web server (Apache?) on port 80, then point your Skyline tags to NI Web Server at some other port. Not sure you would ever want to do that, but I'm just trying to understand where the lines are.


DaveT

-------------------------------------------------------------
David Thomson Original Code Consulting
www.originalcode.com
National Instruments Alliance Program Member
Certified LabVIEW Architect
Certified Embedded Systems Developer
-------------------------------------------------------------
There are 10 kinds of people: those who understand binary, and those who don't.
Message 3 of 5
(3,696 Views)

If you are writing your own web service/application, you should be able to create your application, and then use the Web Service APIs to call into the NI Web Server like you mentioned. 

 

Also, as a side note, NI Web Server is an Apache-based server. I'm not sure if you'd run into issues using two separate Apache servers side-by-side but if you could get that working, or if you used another server, you should be able to use the Web Service APIs like I described above.

-----------------------------------------------
Brandon Grey
Certified LabVIEW Architect

Message 4 of 5
(3,677 Views)

In general if you are creating a WebVI or custom web application that uses any of the Skyline APIs, I would highly recommend hosting it from the same NI Web Server that is providing the data.

 

You technically, can host the web application on a different web server on the same machine or completely different machine, but you will have to enable different CORS options depending on which one you choose.  In addition, it can be very difficult to get the authentication and authorization support working if you are hosting the web application on a different server.  

 

Also, here is an example on how you can add a custom web application or WebVI to the main SystemLink group of applications.

 

https://github.com/joshuaprewitt/swif-template

0 Kudos
Message 5 of 5
(3,672 Views)