Jump to content

Anthony P

Members
  • Posts

    5
  • Joined

  • Last visited

Everything posted by Anthony P

  1. Last update for a bit, should be pretty stable right now. This one fixes an issue parsing player data after they have logged off and also keeps the server details view open on updates.
  2. Added some relevant pictures. If you have any issues with the mod not loading, double check your server log for any error messages. Most likely you need to double check that you've moved all the files from /Lib into the game /Lib folder. You may also need to remove the /Lib file from the zip archive. If this is a consistent issue, I'll split the files so you can just drop them where they need to go.
  3. RC2 fixes some issues with distributing via zip.
  4. Also, the hosted server admin site is built using another repo. You can use this to customize the look of your site if you know how to build sites using Vue.js. https://github.com/tharin2002/vswebadmin
  5. HTTPGateway Latest release: HTTPGateway Release Page What is it? This is a server only mod for the game Vintage Story. You must have purchased the game to use this mod. While this mod is server only, it will still work for single player games since the game runs a server locally. This mod creates a webserver using the EmbedIO library, enabling you to host webpages, images, or other static files. A basic API has been implemented as well, allowing you to fetch data from the game server to your site. Additionally, a websocket endpoint has been created, allowing you to connect and stream the game logs to your site. Included is basic server monitoring site built with Gridsome, a Vue static site generator. You can choose to replace all files in the Web directory if you would like to host your own site. How do I install it? Until the game supports automatic importing of external references for mods, you will have to manually copy a few files as part of installation. Extract your mod zip file, the extra files we need are located inside. Copy the contents of the /Lib/ folder to the /Lib/ folder in your game directory, alongside the game executable. Copy the /Web/ directory to your data folder. This will be a new directory, and will be where you can add files to be hosted by the webserver. WARNING! This mod relies on 3rd party software and opens up HTTP access to the server hosting your game. There are always security risks involved. This mod may also cause performance issues with your game under heavy load, please use caution and consider using a reverse proxy such as NGINX if you plan on allowing public access to the site. Customization The default port the server runs on is 80, enabling you to directly visit your server address in a web browser to open the hosted site. If you cannot bind to port 80, you can edit the file httpgateway-port.txt located in your vintage story game directory. You must load the mod at least once for this file to appear. The file should contain one line with the desired port. After changing the file, restart your server for the changes to apply. How do I use it? Once the mod is installed and hosting, you can visit the default site by visiting the bound address in your web browser. If you would like to develop your own site, there is a built in authentication supplying a jwt token, and several endpoints providing useful information once you are authorized. The authorization is based on a 6-character code challenge that you can generate in game with the command /httpgateway code. POST/api/login?code=<6-character-code> returns { "_auth": "<jwt>" } GET/api/server with header: _auth=<jwt> returns <JSON of IServerAPI> IServerAPI ws:///ws/<jwt> opens websocket connection which streams server logs in format: { "type": <logType>, "data": <logMessage> } Todo Fetch existing logs on ServerLogs connect Better realtime updates, probably over websocket More endpoints for more stuff Interact with server chat over websocket Roadmap Ideas Add DB for more flexible persistance Full server management (over websocket and endpoint) Role based permissions (only admin for now) Reverse proxy support HTTPGateway-1.0.0-rc.3.zip
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.