minetest.conf remote_media
- BrandonReese
- Member
- Posts: 839
- Joined: Wed Sep 12, 2012 00:44
- GitHub: bremaweb
- IRC: BrandonReese
- In-game: BrandonReese
- Location: USA
minetest.conf remote_media
How does this new remote media feature work? I assume I can defer the downloading of textures, sounds and such to a server separate from my game server, but I'm not sure what all that requires.
My Twitch Channel - https://www.twitch.tv/brandonreese81/profile
I've been curious of this new config entry as well. However I don't think it does what I wish.
"Before you speak, ask yourself: Is it kind, is it true, is it necessary, does it improve upon the silence?"
My mods: http://goo.gl/n4kpn
(Currently Various, Industrial, Fakeblocks, Jail, MoarCraft, Christmas, Replicator, minetest dev installer for linux, bash mod installer, windows mod installer)
My mods: http://goo.gl/n4kpn
(Currently Various, Industrial, Fakeblocks, Jail, MoarCraft, Christmas, Replicator, minetest dev installer for linux, bash mod installer, windows mod installer)
So for clarification, what is put into that webserver? The media folder (cache)? All the mods on the server (including default)? What structure is expected by the server?thexyz wrote:iqualfragile: set up some http server, make it accessible from the web, put its url (like http://minetest.ru/data/) in minetest.conf's remote_media
If I can figure out how this is used I will attempt to write up some documentation for it (I'm no document writer but I'll try lol).
"Before you speak, ask yourself: Is it kind, is it true, is it necessary, does it improve upon the silence?"
My mods: http://goo.gl/n4kpn
(Currently Various, Industrial, Fakeblocks, Jail, MoarCraft, Christmas, Replicator, minetest dev installer for linux, bash mod installer, windows mod installer)
My mods: http://goo.gl/n4kpn
(Currently Various, Industrial, Fakeblocks, Jail, MoarCraft, Christmas, Replicator, minetest dev installer for linux, bash mod installer, windows mod installer)
- PilzAdam
- Member
- Posts: 4026
- Joined: Fri Jul 20, 2012 16:19
- GitHub: PilzAdam
- IRC: PilzAdam
- Location: Germany
https://github.com/celeron55/minetest/b ... ample#L242RAPHAEL wrote:So for clarification, what is put into that webserver? The media folder (cache)? All the mods on the server (including default)? What structure is expected by the server?thexyz wrote:iqualfragile: set up some http server, make it accessible from the web, put its url (like http://minetest.ru/data/) in minetest.conf's remote_media
If I can figure out how this is used I will attempt to write up some documentation for it (I'm no document writer but I'll try lol).
That still doesn't answer the question I had. WHAT is to be put on the remote server? Mods? Cache? Other? (I presume cache but would like verification).PilzAdam wrote:https://github.com/celeron55/minetest/b ... ample#L242RAPHAEL wrote:So for clarification, what is put into that webserver? The media folder (cache)? All the mods on the server (including default)? What structure is expected by the server?thexyz wrote:iqualfragile: set up some http server, make it accessible from the web, put its url (like http://minetest.ru/data/) in minetest.conf's remote_media
If I can figure out how this is used I will attempt to write up some documentation for it (I'm no document writer but I'll try lol).
"Before you speak, ask yourself: Is it kind, is it true, is it necessary, does it improve upon the silence?"
My mods: http://goo.gl/n4kpn
(Currently Various, Industrial, Fakeblocks, Jail, MoarCraft, Christmas, Replicator, minetest dev installer for linux, bash mod installer, windows mod installer)
My mods: http://goo.gl/n4kpn
(Currently Various, Industrial, Fakeblocks, Jail, MoarCraft, Christmas, Replicator, minetest dev installer for linux, bash mod installer, windows mod installer)
- rubenwardy
- Moderator
- Posts: 6978
- Joined: Tue Jun 12, 2012 18:11
- GitHub: rubenwardy
- IRC: rubenwardy
- In-game: rubenwardy
- Location: Bristol, United Kingdom
- Contact:
"Media" so cache, i would assumeRAPHAEL wrote:That still doesn't answer the question I had. WHAT is to be put on the remote server? Mods? Cache? Other? (I presume cache but would like verification).PilzAdam wrote:https://github.com/celeron55/minetest/b ... ample#L242RAPHAEL wrote:
So for clarification, what is put into that webserver? The media folder (cache)? All the mods on the server (including default)? What structure is expected by the server?
If I can figure out how this is used I will attempt to write up some documentation for it (I'm no document writer but I'll try lol).
- PilzAdam
- Member
- Posts: 4026
- Joined: Fri Jul 20, 2012 16:19
- GitHub: PilzAdam
- IRC: PilzAdam
- Location: Germany
The textures and sound files.RAPHAEL wrote:That still doesn't answer the question I had. WHAT is to be put on the remote server? Mods? Cache? Other? (I presume cache but would like verification).PilzAdam wrote:https://github.com/celeron55/minetest/b ... ample#L242RAPHAEL wrote:
So for clarification, what is put into that webserver? The media folder (cache)? All the mods on the server (including default)? What structure is expected by the server?
If I can figure out how this is used I will attempt to write up some documentation for it (I'm no document writer but I'll try lol).
Last edited by PilzAdam on Fri Feb 08, 2013 16:22, edited 1 time in total.
- BrandonReese
- Member
- Posts: 839
- Joined: Wed Sep 12, 2012 00:44
- GitHub: bremaweb
- IRC: BrandonReese
- In-game: BrandonReese
- Location: USA
Find all of the .png, .x, .xcf, .blend, and .ogg files in your mods folder, as well as your games folder and upload them to a single folder, like this http://www.bremaweb.com/minetest/media
My Twitch Channel - https://www.twitch.tv/brandonreese81/profile
Linux bash script to copy all media files to a single folder:
* Server owner compresses cache into say tar tar.gz tar.bz2 tar.7z zip file and upload somewhere
* Have in minetest.conf a line of maybe: media_archive = http:/url/media.zip
* On user connect if they need the cache, server sends the url to their client
* Client downloads cache archive and decompresses where needed
* Client fetches any media not in archive from server then connects
Benefits of above is that there are plenty of places to host single archives with hotlinking for free. Almost none that can/will host hundreds or thousands of tiny images with hotlinking for free.
EDIT: I still think it would be more useful to have a feature as follows:#!/bin/bash
# Edit to your liking
MODS="/some/path/minetest/mods/minetest"
DEFMODS="/some/path/minetest/games/minetest_game/mods"
DEST="/some/path/minetest/media"
# Uncomment next two lines if you want to clean out media folder first
#rm -Rf "$DEST"
#mkdir "$DEST"
# Copy files over
find "$MODS" -type f -name '*.png' -exec cp {} "$DEST" \;
find "$MODS" -type f -name '*.ogg' -exec cp {} "$DEST" \;
find "$MODS" -type f -name '*.xcf' -exec cp {} "$DEST" \;
find "$MODS" -type f -name '*.blend' -exec cp {} "$DEST" \;
find "$MODS" -type f -name '*.x' -exec cp {} "$DEST" \;
find "$DEFMODS" -type f -name '*.png' -exec cp {} "$DEST" \;
find "$DEFMODS" -type f -name '*.ogg' -exec cp {} "$DEST" \;
find "$DEFMODS" -type f -name '*.xcf' -exec cp {} "$DEST" \;
find "$DEFMODS" -type f -name '*.blend' -exec cp {} "$DEST" \;
find "$DEFMODS" -type f -name '*.x' -exec cp {} "$DEST" \;
* Server owner compresses cache into say tar tar.gz tar.bz2 tar.7z zip file and upload somewhere
* Have in minetest.conf a line of maybe: media_archive = http:/url/media.zip
* On user connect if they need the cache, server sends the url to their client
* Client downloads cache archive and decompresses where needed
* Client fetches any media not in archive from server then connects
Benefits of above is that there are plenty of places to host single archives with hotlinking for free. Almost none that can/will host hundreds or thousands of tiny images with hotlinking for free.
Last edited by RAPHAEL on Fri Feb 08, 2013 20:40, edited 1 time in total.
"Before you speak, ask yourself: Is it kind, is it true, is it necessary, does it improve upon the silence?"
My mods: http://goo.gl/n4kpn
(Currently Various, Industrial, Fakeblocks, Jail, MoarCraft, Christmas, Replicator, minetest dev installer for linux, bash mod installer, windows mod installer)
My mods: http://goo.gl/n4kpn
(Currently Various, Industrial, Fakeblocks, Jail, MoarCraft, Christmas, Replicator, minetest dev installer for linux, bash mod installer, windows mod installer)
That's how the HLDS servers did it with the sv_downloadurl cvar. You'd setup your webserver with matching bzip files and the client decompressed after download. Back in the day when broadband was precious this was a huge help in getting custom maps & files out to clients connecting to your server.
Someone should take a look at the download routine doing the function, it can't be much more to include an unzip module (gz, bz2, etc) and pass the file through it if it matches the file type ending for decompression. Considering a lot of people are running their servers off home connections where upload is usually less than download, this would be a good feature.
Someone should take a look at the download routine doing the function, it can't be much more to include an unzip module (gz, bz2, etc) and pass the file through it if it matches the file type ending for decompression. Considering a lot of people are running their servers off home connections where upload is usually less than download, this would be a good feature.
- afflatus
- Member
- Posts: 362
- Joined: Tue Apr 01, 2014 19:47
- GitHub: 0-afflatus
- IRC: afflatus
- In-game: afflatus
- Location: Avalonia
- Contact:
Re: minetest.conf remote_media
RAPHAEL check out kaeza's bash script, which appears to do the same thing in about 7 lines.
viewtopic.php?id=5969
However, your script is more comprehensive.
viewtopic.php?id=5969
However, your script is more comprehensive.
Grailtest is stirring ...
Who is online
Users browsing this forum: No registered users and 24 guests