cosim-demo-app icon indicating copy to clipboard operation
cosim-demo-app copied to clipboard

Server port as command line argument

Open THEvang opened this issue 6 years ago • 2 comments

Feature Pass the server port as a command line argument

Example

./cse-server-go -p 8080

Use Cases

  • Running the server on a different port than 8000

  • Running multiple server instances on the same computer

Implementation Suggestion The Golang standard library has support for command line parsing using the flag package.

THEvang avatar Jul 10 '19 10:07 THEvang

Is the idea is to also use cse-client when running the server on a different port? If so, some changes will also be required in cse-client, as its websocket connection URL is currently hardcoded to be ws://localhost:8000/ws.

eidekrist avatar Jul 18 '19 11:07 eidekrist

Not neccessarily, but I guess it would be nice to have. The main reason I need this is to test a network FMU by running two instances of the CSE server on the same machine. I would only need a web interface for one of them to verify communication.

THEvang avatar Jul 22 '19 12:07 THEvang