[Request] Monolithic Rock-On

I’m no coder and I would really like if someone has the time to make a .json profile for Monolithic. All documentary is available in Docker hub. And Rock-on profile structure can be found from Rock-on JSON structure.

@nasrocket
it shouldn’t be too difficult, copy the below into a blank text file, save with the json extension and and place it in the /opt/rockstor/rockons-metastore folder (if it doesn’t exist you need to create it).

Then after refreshing the Rock-ons directory it should show up as an installation option. I have seen the port 80 and 443 as the default setting, you will have to pick different ones for the mapping, since those might already be used on Rockstor (the 443 for sure for the Rockstor UI).
Not sure whether you need any of the cache/memory items exposed to change the default values or not. But you should be able to easily add those into the json file. Other than a successful installation I couldn’t test it, since I am not doing much gaming these days.

I take it, you know how to reroute the http/https traffic for the gaming providers already.

lancache_monolithic.json
{
	"Lancache: Monolithic": {
		"description": "LAN Party game caching made easy.<p>Download your games once and serve them out to many people at your LAN. A monolithic lancache service capable of caching all cdn's in a single instance.</p><p>Based on the official docker image: <a href='https://hub.docker.com/r/lancachenet/monolithic' target='_blank'>https://hub.docker.com/r/lancachenet/monolithic</a>, currently available on x86_64/amd64 only.</p>",
		"icon": "https://avatars.githubusercontent.com/u/16938914?s=200&v=4",
		"more_info": "See <a href='https://lancache.net/docs/containers/monolithic/' target='_blank'>https://lancache.net/docs/containers/monolithic/</a> for more info.",
		"website": "https://lancache.net/",
		"version": "1.0",
		"containers": {
			"lancache_monolithic": {
				"image": "lancachenet/monolithic",
				"tag": "latest",
				"launch_order": 1,
				"ports": {
					"80": {
						"description": "Port for managing http requests. Default: 80",
						"label": "http Port",
						"host_default": 80,
						"label": "http Port"
					},
					"443": {
						"description": "Port for managing https requests. Default: 443",
						"host_default": 443,
						"label": "https Port"
					}
				},
				"volumes": {
					"/data/cache": {
						"description": "Choose a Share for monolithic's data cache. E.g.: create a Share called mono-cache which should be large in size (e.g. 1TB) as it stores the cached request entries",
						"label": "Cache Space"
					},
					"/data/logs": {
						"description": "Choose a Share for the logs. E.g.: create a Share called for this purpose alone.",
						"label": "Log Files"
					}
				}
			}
		}
	}
}

Good luck. If this works, we can submit it to the Rock-on repository.

2 Likes

No dice, I could not get caching working. However I installed a lancache-dns rockon and saw network acttivity relayed through my Rockstor machine. I had configured my client PC manually IPv4 DNS to Rockstor. I think I need extra enviriomental variables, atleast
USE_GENERIC_CACHE=true is required on a single Monoliothic instance. Sorry for extra delayed reply, I finally managed find the time outside of my chaos for testing this. I will continue further testing.

Ah, so if I read this correctly,

you always need both the monolithic docker to manage the cache and proxy-requests as well as the Lancache-DNS docker to manage the DNS requests (reroute to cached vs. “normal” requests):

and on the DNS docker you would need at least those 2 parameters:

If you are using a single Monoliothic instance, you should make sure you set USE_GENERIC_CACHE=true and set LANCACHE_IP to the IP address of the caching server

And to have non-cache related DNS calls go through a specific DNS server the UPSTREAM_DNS variable, correct?

3 Likes

You are correct, you need them both (depot+relay) and upstream DNS. And optionally if you want cache more than 1 service, you have to spool up multiple instances (IP addresses).

I think for the purpose of the Rock-on architecture, it will only be possible to do one instance each (at least for now), as it would require different names for the underlying containers, and with the current approach that won’t be possible. Of course, one can use the underlying docker functionality to spin up additional containers.
In that context, do you think, one would always spin up both at the same time (i.e. one Monolith and one DNS)?
I’m asking, because we could possibly create a Rock-on that spins up 2 containers, and since they don’t need to be connected via the Docker networks (at least appears to me that way), and no net=host option is required this could be a one-shot installation. Albeit with the limited scope that one can only have one depot to start with (and would require to use the command line to spin up additional cache storages).

2 Likes