From d5cc4529b00ae93b60549a177cc4128a3f029ca3 Mon Sep 17 00:00:00 2001 From: Andrew Date: Wed, 21 Dec 2022 21:55:21 -0500 Subject: [PATCH 01/84] Add try/except for not finding run file --- app/classes/shared/server.py | 83 +++++++++++++++++++----------------- 1 file changed, 44 insertions(+), 39 deletions(-) diff --git a/app/classes/shared/server.py b/app/classes/shared/server.py index ccc50f70..421e1568 100644 --- a/app/classes/shared/server.py +++ b/app/classes/shared/server.py @@ -587,47 +587,52 @@ class ServerInstance: # We need to grab the exact forge version number. # We know we can find it here in the run.sh/bat script. - run_file_path = "" - if self.helper.is_os_windows(): - run_file_path = os.path.join(server_obj.path, "run.bat") - else: - run_file_path = os.path.join(server_obj.path, "run.sh") + try: + run_file_path = "" + if self.helper.is_os_windows(): + run_file_path = os.path.join(server_obj.path, "run.bat") + else: + run_file_path = os.path.join(server_obj.path, "run.sh") - if Helpers.check_file_perms(run_file_path) and os.path.isfile( - run_file_path - ): - run_file = open(run_file_path, "r", encoding="utf-8") - run_file_text = run_file.read() - else: - Console.error( - "ERROR ! Forge install can't read the scripts files." - " Aborting ..." + if Helpers.check_file_perms(run_file_path) and os.path.isfile( + run_file_path + ): + run_file = open(run_file_path, "r", encoding="utf-8") + run_file_text = run_file.read() + else: + Console.error( + "ERROR ! Forge install can't read the scripts files." + " Aborting ..." + ) + return + + # We get the server command parameters from forge script + server_command = re.findall( + r"java @([a-zA-Z0-9_\.]+)" + r" @([a-z.\/\-]+)([0-9.\-]+)\/\b([a-z_0-9]+\.txt)\b( .{2,4})?", + run_file_text, + )[0] + + version = server_command[2] + executable_path = f"{server_command[1]}{server_command[2]}/" + + # Let's set the proper server executable + server_obj.executable = os.path.join( + f"{executable_path}forge-{version}-server.jar" ) - return - - # We get the server command parameters from forge script - server_command = re.findall( - r"java @([a-zA-Z0-9_\.]+)" - r" @([a-z.\/\-]+)([0-9.\-]+)\/\b([a-z_0-9]+\.txt)\b( .{2,4})?", - run_file_text, - )[0] - - version = server_command[2] - executable_path = f"{server_command[1]}{server_command[2]}/" - - # Let's set the proper server executable - server_obj.executable = os.path.join( - f"{executable_path}forge-{version}-server.jar" - ) - # Now lets set up the new run command. - # This is based off the run.sh/bat that - # Forge uses in 1.16 and < - execution_command = ( - f"java @{server_command[0]}" - f" @{executable_path}{server_command[3]} nogui {server_command[4]}" - ) - server_obj.execution_command = execution_command - Console.debug("SUCCESS! Forge install completed") + # Now lets set up the new run command. + # This is based off the run.sh/bat that + # Forge uses in 1.17 and < + execution_command = ( + f"java @{server_command[0]}" + f" @{executable_path}{server_command[3]} nogui" + " {server_command[4]}" + ) + server_obj.execution_command = execution_command + Console.debug("SUCCESS! Forge install completed") + except: + logger.debug("Could not find run file.") + # TODO Use regex to get version and rebuild simple execution # We'll update the server with the new information now. HelperServers.update_server(server_obj) From 9dac0b5d85532fa4c312fe653319fdb7dac156c7 Mon Sep 17 00:00:00 2001 From: Silversthorn Date: Thu, 22 Dec 2022 19:32:56 +0100 Subject: [PATCH 02/84] Adding Forge Installer Compaptibility with old versions --- app/classes/shared/server.py | 122 ++++++++++++++++++++++++----------- 1 file changed, 84 insertions(+), 38 deletions(-) diff --git a/app/classes/shared/server.py b/app/classes/shared/server.py index 421e1568..86afa1cf 100644 --- a/app/classes/shared/server.py +++ b/app/classes/shared/server.py @@ -10,6 +10,7 @@ import logging.config import subprocess import html import urllib.request +import glob # TZLocal is set as a hidden import on win pipeline from tzlocal import get_localzone @@ -580,7 +581,7 @@ class ServerInstance: # Process has exited. Lets do some work to setup the new # run command. # Let's grab the server object we're going to update. - server_obj = HelperServers.get_server_obj(self.server_id) + server_obj: Servers = HelperServers.get_server_obj(self.server_id) # The forge install is done so we can delete that install file. os.remove(os.path.join(server_obj.path, server_obj.executable)) @@ -588,48 +589,93 @@ class ServerInstance: # We need to grab the exact forge version number. # We know we can find it here in the run.sh/bat script. try: - run_file_path = "" - if self.helper.is_os_windows(): - run_file_path = os.path.join(server_obj.path, "run.bat") - else: - run_file_path = os.path.join(server_obj.path, "run.sh") - if Helpers.check_file_perms(run_file_path) and os.path.isfile( - run_file_path - ): - run_file = open(run_file_path, "r", encoding="utf-8") - run_file_text = run_file.read() - else: - Console.error( - "ERROR ! Forge install can't read the scripts files." - " Aborting ..." + # Getting the forge version from the executable command + version = re.findall( + r"forge-([0-9\.]+)((?:)|(?:-([0-9\.]+)-[a-zA-Z]+)).jar", + server_obj.execution_command, + ) + version_param = version[0][0].split(".") + version_major = int(version_param[0]) + version_minor = int(version_param[1]) + + # Checking which version we are with + if version_major <= 1 and version_minor < 17: + # OLD VERSION < 1.17 + + # Retrieving the executable jar filename + file_path = glob.glob( + f"{server_obj.path}/forge-{version[0][0]}*.jar" + )[0] + file_name = re.findall( + r"(forge[-0-9.]+.jar)", + file_path, + )[0] + + # Let's set the proper server executable + server_obj.executable = os.path.join(file_name) + + # Get memory values + memory_values = re.findall( + r"-Xms([A-Z0-9\.]+) -Xmx([A-Z0-9\.]+)", + server_obj.execution_command, ) - return - # We get the server command parameters from forge script - server_command = re.findall( - r"java @([a-zA-Z0-9_\.]+)" - r" @([a-z.\/\-]+)([0-9.\-]+)\/\b([a-z_0-9]+\.txt)\b( .{2,4})?", - run_file_text, - )[0] + # Now lets set up the new run command. + # This is based off the run.sh/bat that + # Forge uses in 1.17 and < + execution_command = ( + f"java -Xms{memory_values[0][0]} -Xmx{memory_values[0][1]}" + f' -jar "{file_name}" nogui' + ) + server_obj.execution_command = execution_command + Console.debug("SUCCESS! Forge install completed") - version = server_command[2] - executable_path = f"{server_command[1]}{server_command[2]}/" + else: + # NEW VERSION >= 1.17 - # Let's set the proper server executable - server_obj.executable = os.path.join( - f"{executable_path}forge-{version}-server.jar" - ) - # Now lets set up the new run command. - # This is based off the run.sh/bat that - # Forge uses in 1.17 and < - execution_command = ( - f"java @{server_command[0]}" - f" @{executable_path}{server_command[3]} nogui" - " {server_command[4]}" - ) - server_obj.execution_command = execution_command - Console.debug("SUCCESS! Forge install completed") + run_file_path = "" + if self.helper.is_os_windows(): + run_file_path = os.path.join(server_obj.path, "run.bat") + else: + run_file_path = os.path.join(server_obj.path, "run.sh") + + if Helpers.check_file_perms(run_file_path) and os.path.isfile( + run_file_path + ): + run_file = open(run_file_path, "r", encoding="utf-8") + run_file_text = run_file.read() + else: + Console.error( + "ERROR ! Forge install can't read the scripts files." + " Aborting ..." + ) + return + + # We get the server command parameters from forge script + server_command = re.findall( + r"java @([a-zA-Z0-9_\.]+)" + r" @([a-z.\/\-]+)([0-9.\-]+)\/\b([a-z_0-9]+\.txt)\b( .{2,4})?", + run_file_text, + )[0] + + version = server_command[2] + executable_path = f"{server_command[1]}{server_command[2]}/" + + # Let's set the proper server executable + server_obj.executable = os.path.join( + f"{executable_path}forge-{version}-server.jar" + ) + # Now lets set up the new run command. + # This is based off the run.sh/bat that + # Forge uses in 1.17 and < + execution_command = ( + f"java @{server_command[0]}" + f" @{executable_path}{server_command[3]} nogui" + " {server_command[4]}" + ) + server_obj.execution_command = execution_command + Console.debug("SUCCESS! Forge install completed") except: logger.debug("Could not find run file.") # TODO Use regex to get version and rebuild simple execution From 88cd991b7e4cf51c9976d5d7fd1f9b6fcd9e5767 Mon Sep 17 00:00:00 2001 From: Andrew Date: Thu, 22 Dec 2022 20:59:45 -0500 Subject: [PATCH 03/84] Fix bug where server_path variable was still used I'm dumb and I fixed a bug I created. --- app/classes/web/panel_handler.py | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/app/classes/web/panel_handler.py b/app/classes/web/panel_handler.py index 020dee12..582517db 100644 --- a/app/classes/web/panel_handler.py +++ b/app/classes/web/panel_handler.py @@ -1521,10 +1521,6 @@ class PanelHandler(BaseHandler): server_obj = self.controller.servers.get_server_obj(server_id) shutdown_timeout = self.get_argument("shutdown_timeout", 60) if superuser: - server_path = self.get_argument("server_path", None) - if Helpers.is_os_windows(): - server_path.replace(" ", "^ ") - server_path = Helpers.wtol_path(server_path) log_path = self.get_argument("log_path", "") if log_path: if Helpers.is_os_windows(): @@ -1613,7 +1609,7 @@ class PanelHandler(BaseHandler): server_obj.shutdown_timeout = shutdown_timeout if superuser: if Helpers.validate_traversal( - self.helper.get_servers_root_dir(), server_path + self.helper.get_servers_root_dir(), server_obj.path ): server_obj.log_path = log_path if Helpers.validate_traversal( From ddaac250606a1dc2a90dfaa29af8e33165c4f65e Mon Sep 17 00:00:00 2001 From: Andrew Date: Fri, 23 Dec 2022 20:14:41 -0500 Subject: [PATCH 04/84] Run forge installer for all versions of forge --- app/classes/minecraft/serverjars.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/classes/minecraft/serverjars.py b/app/classes/minecraft/serverjars.py index a656944b..3ecfdb8f 100644 --- a/app/classes/minecraft/serverjars.py +++ b/app/classes/minecraft/serverjars.py @@ -192,7 +192,7 @@ class ServerJars: with open(path, "wb") as output: shutil.copyfileobj(r.raw, output) # If this is the newer forge version we will run the installer - if server == "forge" and int(version.split(".")[1]) > 15: + if server == "forge": ServersController.finish_import(server_id, True) else: ServersController.finish_import(server_id) From 47e2635b2034958ca60327cab3016b5bb153e7be Mon Sep 17 00:00:00 2001 From: Andrew Date: Tue, 27 Dec 2022 09:45:39 -0500 Subject: [PATCH 05/84] Set a timeout on server launch to display warn --- app/frontend/templates/panel/dashboard.html | 469 +++++++++++--------- 1 file changed, 258 insertions(+), 211 deletions(-) diff --git a/app/frontend/templates/panel/dashboard.html b/app/frontend/templates/panel/dashboard.html index 171f2b8a..b328a919 100644 --- a/app/frontend/templates/panel/dashboard.html +++ b/app/frontend/templates/panel/dashboard.html @@ -282,184 +282,184 @@
- {% if server['stats']['running'] %} - {{ translate('dashboard', 'online', - data['lang']) }} - {% elif server['stats']['crashed'] %} - {{ translate('dashboard', - 'crashed', - data['lang']) }} - {% else %} - {{ translate('dashboard', 'offline', - data['lang']) }} - {% end %} -
-
+ {% if server['stats']['running'] %} + {{ translate('dashboard', 'online', + data['lang']) }} + {% elif server['stats']['crashed'] %} + {{ translate('dashboard', + 'crashed', + data['lang']) }} + {% else %} + {{ translate('dashboard', 'offline', + data['lang']) }} + {% end %} +
+
{% end %} -
-
- {% for server in data['failed_servers'] %} - -  {{server['server_name']}} - - - - - - -  Unloaded - - {% end %} - - + + {% for server in data['failed_servers'] %} + +  {{server['server_name']}} + + + + + + +  Unloaded + {% end %} - {% if len(data['servers']) > 0 %} - -
-
- {% for server in data['servers'] %} -
-
-

-
-
- {% if server['alert'] %} - - {{ server['server_data']['server_name'] }}  - + + +
+ {% end %} + {% if len(data['servers']) > 0 %} + +
+
+ {% for server in data['servers'] %} +
+
+

+
+ +
+ +
+ +
+
+ {% if server['user_command_permission'] %} + {% if server['stats']['running'] %} +
+
+ + + +
+
+ + + +
+
+ + + +
+
+ {% elif server['stats']['updating']%} + + + {% elif server['stats']['waiting_start']%} + + + {% elif server['stats']['importing']%} + + {% else %} +
+
+ + + +
+
+ + + +
+
+ + +
+
+ {% end %} {% end %}
-
- -
- -
-
- {% if server['user_command_permission'] %} - {% if server['stats']['running'] %} -
-
- - - -
-
- - - -
-
- - - -
-
- {% elif server['stats']['updating']%} - - - {% elif server['stats']['waiting_start']%} - - - {% elif server['stats']['importing']%} - - {% else %} -
-
- - - -
-
- - - -
-
- - -
-
- {% end %} - {% end %} -
-
-

-
+
+

+
-
-
-
-
-
{{ translate('dashboard', 'cpuUsage', data['lang']) }}
-
-
-
+
+
+
+
{{ translate('dashboard', 'cpuUsage', data['lang']) }}
+
+
+
-
- {{server['stats']['cpu']}}% + aria-valuemax="100">
+ {{server['stats']['cpu']}}%
-
-
{{ translate('dashboard', 'memUsage', data['lang']) }}
-
-
-
+
{{ translate('dashboard', 'memUsage', data['lang']) }}
+
+
+
-
- {{server['stats']['mem_percent']}}% - - - {% if server['stats']['mem'] == 0 %} - 0 MB - {% else %} - {{server['stats']['mem']}} - {% end %} + aria-valuemin="0" aria-valuemax="100">
+ {{server['stats']['mem_percent']}}% - + + {% if server['stats']['mem'] == 0 %} + 0 MB + {% else %} + {{server['stats']['mem']}} + {% end %}
-
-
-
-
{{ translate('dashboard', 'size', data['lang']) }}
-
- {{ server['stats']['world_size'] }} -
+
+
+
+
+
{{ translate('dashboard', 'size', data['lang']) }}
+
+ {{ server['stats']['world_size'] }}
-
-
{{ translate('dashboard', 'players', data['lang']) }}
-
- {% if server['stats']['int_ping_results'] %} - {{ server['stats']['online'] }} / {{ server['stats']['max'] }} {{ translate('dashboard', - 'max', - data['lang']) }}
+
+
+
{{ translate('dashboard', 'players', data['lang']) }}
+
+ {% if server['stats']['int_ping_results'] %} + {{ server['stats']['online'] }} / {{ server['stats']['max'] }} {{ translate('dashboard', + 'max', + data['lang']) }}
- {% if server['stats']['desc'] != 'False' %} -
- {{ server['stats']['desc'] }}

- {% end %} + {% if server['stats']['desc'] != 'False' %} +
+ {{ server['stats']['desc'] }}

+ {% end %} - {% if server['stats']['version'] != 'False' %} - {{ server['stats']['version'] }} - {% end %} - {% end %} -
+ {% if server['stats']['version'] != 'False' %} + {{ server['stats']['version'] }} + {% end %} + {% end %}
- {% end %}
+ {% end %}
- {% end %}
+ {% end %}
+
@@ -606,7 +606,9 @@ function send_command(server_id, command) { /* this getCookie function is in base.html */ const token = getCookie("_xsrf"); - + setTimeout(warn('WebSockets are required for Crafty to work. This websocket connection has been closed. Are you using a reverse proxy?', + 'https://wiki.craftycontrol.com/en/4/docs/Reverse%20Proxy%20Examples', + 'wssError'), 5); $.ajax({ type: "POST", headers: { 'X-XSRFToken': token }, @@ -623,6 +625,51 @@ }); } + + function warn(message, link = null, className = null) { + var closeEl = document.createElement('span'); + var strongEL = document.createElement('strong'); + var msgEl = document.createElement('div'); + + closeEl.innerHTML = '×'; + strongEL.textContent = 'Warning: '; + msgEl.append(strongEL, message); + + + closeEl.style.marginLeft = '15px'; + closeEl.style.fontWeight = 'bold'; + closeEl.style.float = 'right'; + closeEl.style.fontSize = '22px'; + closeEl.style.lineHeight = '20px'; + closeEl.style.cursor = 'pointer'; + + closeEl.addEventListener('click', function () { this.parentElement.style.display = 'none'; }); + + var parentEl = document.createElement('div'); + + parentEl.style.padding = '20px'; + parentEl.style.backgroundColor = '#f7970f'; + + parentEl.appendChild(closeEl); + parentEl.appendChild(msgEl); + if (link) { + let linkEl = document.createElement('a') + linkEl.href = link; + linkEl.innerHTML = "See our documentation for details."; + linkEl.style.color = 'white'; + linkEl.style.textDecoration = 'underline'; + linkEl.target = "_blank"; + + parentEl.appendChild(linkEl); + } + + if (className) { + parentEl.classList.add(className); + } + + document.querySelector('.warnings').appendChild(parentEl); + } + function send_kill(server_id) { /* this getCookie function is in base.html */ const token = getCookie("_xsrf"); From 60e393d7cfcaabf719f6680f5ea42d1d60ff208b Mon Sep 17 00:00:00 2001 From: amcmanu3 Date: Wed, 28 Dec 2022 00:20:06 -0500 Subject: [PATCH 06/84] Make qol changes to startup warning --- app/frontend/templates/panel/dashboard.html | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/app/frontend/templates/panel/dashboard.html b/app/frontend/templates/panel/dashboard.html index b328a919..07fc6b2f 100644 --- a/app/frontend/templates/panel/dashboard.html +++ b/app/frontend/templates/panel/dashboard.html @@ -606,9 +606,6 @@ function send_command(server_id, command) { /* this getCookie function is in base.html */ const token = getCookie("_xsrf"); - setTimeout(warn('WebSockets are required for Crafty to work. This websocket connection has been closed. Are you using a reverse proxy?', - 'https://wiki.craftycontrol.com/en/4/docs/Reverse%20Proxy%20Examples', - 'wssError'), 5); $.ajax({ type: "POST", headers: { 'X-XSRFToken': token }, @@ -667,7 +664,7 @@ parentEl.classList.add(className); } - document.querySelector('.warnings').appendChild(parentEl); + document.querySelector('.dynamicMsg').appendChild(parentEl); } function send_kill(server_id) { @@ -821,11 +818,16 @@ send_command(server_id, 'start_server'); bootbox.alert({ backdrop: true, - title: '{% raw translate("dashboard", "sendingCommand", data["lang"]) %}', + title: '{% raw translate("dashboard", "sendingCommand", data["lang"]) %}', message: '
  {% raw translate("dashboard", "bePatientStart", data["lang"]) %}
' }); + setTimeout(finishTimeout, 60000); }); - + function finishTimeout() { + console.log("TIMEOUT FINISHED") + warn("It seems this is taking a while...it's possible you're using UBlock or a similar ad blocker and it's causing some of our connections to not make it to the server. Try disabling your ad blocker.", + null, 'wssError'); + } $(".stop_button").click(function () { console.log("stopping server"); server_id = $(this).attr("data-id"); From 6f76ad653f449e466902f4e88f774f86cb2bf063 Mon Sep 17 00:00:00 2001 From: Makhuta Date: Wed, 28 Dec 2022 16:03:58 +0000 Subject: [PATCH 07/84] Add Czech translation --- app/translations/cs_CS.json | 606 ++++++++++++++++++++++++++++++++++++ 1 file changed, 606 insertions(+) create mode 100644 app/translations/cs_CS.json diff --git a/app/translations/cs_CS.json b/app/translations/cs_CS.json new file mode 100644 index 00000000..e7ad95d6 --- /dev/null +++ b/app/translations/cs_CS.json @@ -0,0 +1,606 @@ +{ + "404": { + "contact": "Kontaktujte podporu Crafty přes Discord", + "notFound": "Stránka nebyla nalezena", + "unableToFind": "Hledanou stránku se nám nepodařilo najít. Zkuste to prosím znovu nebo se vraťte a obnovte stránku." + }, + "accessDenied": { + "accessDenied": "Přístup odepřen", + "contact": "Kontaktujte podporu Crafty přes Discord", + "contactAdmin": "Pro přístup k tomuto prostředku se obraťte na správce serveru, nebo pokud si myslíte, že byste k němu měli mít přístup, kontaktujte podporu.", + "noAccess": "K tomuto zdroji nemáte přístup" + }, + "apiKeys": { + "apiKeys": "Klíče API", + "auth": "Autorizován? ", + "buttons": "Tlačítka", + "config": "Nastavení", + "crafty": "Crafty: ", + "created": "Vytvořen", + "createNew": "Vytvořit nový token API", + "deleteKeyConfirmation": "Chcete tento API klíč odstranit? Tuto akci nelze vrátit zpět.", + "deleteKeyConfirmationTitle": "Odstranit klíč API ${keyId}?", + "getToken": "Získat token", + "name": "Jméno", + "nameDesc": "Jak chcete nazvat tento token API? ", + "no": "Ne", + "pageTitle": "Úprava uživatelských klíčů API", + "permName": "Název oprávnění", + "perms": "Oprávnění", + "server": "Server: ", + "superUser": "Super uživatel", + "yes": "Ano" + }, + "base": { + "doesNotWorkWithoutJavascript": "Varování: Crafty nefunguje správně, pokud není povolen JavaScript!" + }, + "credits": { + "developmentTeam": "Vývojový tým", + "hugeDesc": "Neskutečně", + "pageDescription": "Bez těchto lidí bychom neměli Crafty.", + "pageTitle": "Zásluhy", + "patreonDesc": "našim příznivcům Patreonu / Ko-fi!", + "patreonOther": "Další", + "patreonSupporter": "Podpůrci Patreonu / Ko-fi", + "patreonUpdate": "Poslední aktualizace:", + "retiredStaff": "Bývalí zaměstnanci", + "subscriberName": "Jméno", + "subscriptionLevel": "Úroveň", + "supportTeam": "Tým podpory a dokumentace", + "thankYou": "DĚKUJEME", + "translationDesc": "naší komunitě, která překládá! [ Aktivní = 🟢 Neaktivní/ukončený = ⚪ ]", + "translationName": "Jazyk", + "translationTitle": "Překlad do jazyků", + "translator": "Překladatelé" + }, + "dashboard": { + "actions": "Akce", + "allServers": "Všechny servery", + "avg": "Průměr", + "backups": "Zálohy", + "bePatientClone": "Buďte prosím trpěliví, než se dokončí klonování serveru.
Tato obrazovka se za okamžik aktualizuje", + "bePatientRestart": "Buďte prosím trpěliví, než se dokončí restart serveru.
Tato obrazovka se za okamžik aktualizuje", + "bePatientStart": "Buďte prosím trpěliví, než se dokončí spuštění serveru.
Tato obrazovka se za okamžik aktualizuje", + "bePatientStop": "Buďte prosím trpěliví, než se dokončí zastavení serveru.
Tato obrazovka se za okamžik aktualizuje", + "cannotSee": "Nezobrazuje se vám vše?", + "cannotSeeOnMobile": "Nezobrazuje se vám vše na mobilu?", + "cannotSeeOnMobile2": "Zkuste posunout tabulku do strany.", + "clone": "Klon", + "cloneConfirm": "Opravdu chcete tento server naklonovat? Tento proces může chvíli trvat.", + "cpuCores": "Jádra CPU", + "cpuCurFreq": "Aktuální takt CPU", + "cpuMaxFreq": "Maximální takt CPU", + "cpuUsage": "Využití CPU", + "crashed": "Crashnuté", + "dashboard": "Ovládací panel", + "delay-explained": "Služba/agent byla nedávno spuštěna a zpožďuje spuštění instance minecraft serveru.", + "host": "Hostitel", + "kill": "Zabít proces", + "killing": "Zabíjím proces...", + "lastBackup": "Poslední:", + "max": "Max", + "memUsage": "Využití paměti", + "motd": "MOTD", + "newServer": "Vytvořit nový server", + "nextBackup": "Další:", + "no-servers": "V současné době nejsou k dispozici žádné servery. Chcete-li začít, klikněte na", + "offline": "Offline", + "online": "Online", + "players": "Hráči", + "restart": "Restartovat", + "sendingCommand": "Odeslání příkazu", + "server": "Server", + "servers": "Servery", + "size": "Velikost složky serveru", + "start": "Start", + "starting": "Zpožděný start", + "status": "Stav", + "stop": "Zastavit", + "version": "Verze", + "welcome": "Vítejte v Crafty Controlleru", + "installing": "Instalace..." + }, + "datatables": { + "i18n": { + "aria": { + "sortAscending": ": aktivace řazení sloupce vzestupně", + "sortDescending": ": aktivace seřazení sloupce sestupně" + }, + "buttons": { + "collection": "Sbírka ", + "colvis": "Viditelnost sloupců", + "colvisRestore": "Obnovit viditelnost", + "copy": "Kopírovat", + "copyKeys": "Stisknutím kláves Ctrl nebo u2318 + C zkopírujete data tabulky do systémové schránky.

Chcete-li tuto zprávu zrušit, klikněte na ni nebo stiskněte klávesu ESC.", + "copySuccess": { + "1": "Zkopírován 1 řádek do schránky", + "2": "Zkopírovány 2 řádky do schránky", + "3": "Zkopírovány 3 řádky do schránky", + "4": "Zkopírovány 4 řádky do schránky", + "_": "Zkopírováno %d řádků do schránky" + }, + "copyTitle": "Zkopírovat do schránky", + "csv": "CSV", + "excel": "Excel", + "pageLength": { + "1": "Zobrazit 1 řádek", + "2": "Zobrazit 2 řádky", + "3": "Zobrazit 3 řádky", + "4": "Zobrazit 4 řádky", + "-1": "Zobrazit všechny řádky", + "_": "Zobrazit %d řádků" + }, + "pdf": "PDF", + "print": "Tisk" + }, + "decimal": "", + "emptyTable": "V tabulce nejsou k dispozici žádné údaje", + "info": "Zobrazeno _START_ až _END_ z _TOTAL_ záznamů", + "infoEmpty": "Zobrazeno 0 až 0 z 0 záznamů", + "infoFiltered": "(filtrováno z _MAX_ celkových záznamů)", + "infoPostFix": "", + "lengthMenu": "Zobrazit položky _MENU_", + "loadingRecords": "Načítání...", + "paginate": { + "first": "První", + "last": "Poslední", + "next": "Další", + "previous": "Předchozí" + }, + "processing": "Zpracování...", + "search": "Hledat:", + "select": { + "cells": { + "0": "Kliknutím na buňku ji vyberete", + "1": "Vybraná %d buňka", + "2": "Vybrané %d buňky", + "3": "Vybrané %d buňky", + "4": "Vybrané %d buňky", + "_": "Vybráno %d buněk" + }, + "columns": { + "0": "Kliknutím na sloupec jej vyberete", + "1": "Vybraný %d sloupec", + "2": "Vybrané %d sloupce", + "3": "Vybrané %d sloupce", + "4": "Vybrané %d sloupce", + "_": "Vybráno %d sloupců" + }, + "rows": { + "0": "Kliknutím na řádek jej vyberete", + "1": "Vybraný %d řádek", + "2": "Vybrané %d řádky", + "3": "Vybrané %d řádky", + "4": "Vybrané %d řádky", + "_": "Vybráno %d řádků" + } + }, + "thousands": " ", + "zeroRecords": "Nebyly nalezeny žádné odpovídající záznamy" + } + }, + "error": { + "contact": "Kontaktujte podporu Crafty přes Discord", + "embarassing": "Ach jo, no, to je trapné.", + "error": "Chyba!", + "eulaAgree": "Souhlasíte?", + "eulaMsg": "Musíte souhlasit s ", + "privMsg": "a ", + "eulaTitle": "Souhlas s EULA", + "agree": "Souhlasím", + "cancel": "Zrušit", + "fileTooLarge": "Odeslání se nezdařilo. Příliš velký nahraný soubor. Obraťte se na správce systému.", + "hereIsTheError": "Zde je chyba", + "internet": "Zjistili jsme, že počítač se spuštěným programem Crafty není připojen k internetu. Připojení klientů k serveru může být omezeno.", + "no-file": "Zdá se, že nemůžeme najít požadovaný soubor. Překontrolujte cestu. Má Crafty správné oprávnění?", + "noJava": "Server {} se nepodařilo spustit s kódem chyby: Zjistili jsme, že Java není nainstalována. Nainstalujte prosím Javu a poté spusťte server.", + "not-downloaded": "Zdá se, že nemůžeme najít váš spustitelný soubor. Bylo jeho stahování dokončeno? Jsou oprávnění nastavena na spustitelný soubor?", + "portReminder": "Zjistili jsme, že server {} byl spuštěn poprvé. Ujistěte se, že jste přesměrovali port {} přes váš směrovač/firewall, aby byl tento port vzdáleně přístupný z internetu.", + "start-error": "Server {} se nepodařilo spustit s kódem chyby: {}", + "terribleFailure": "Jaké strašné selhání!", + "superError": "Pro dokončení této akce musíte být super uživatel.", + "fileError": "Typ souboru musí být obrázek." + }, + "footer": { + "allRightsReserved": "Všechna práva vyhrazena", + "copyright": "Autorská práva", + "version": "Verze" + }, + "login": { + "forgotPassword": "Zapomenuté heslo", + "login": "Přihlásit se", + "password": "Heslo", + "username": "Uživatelské jméno" + }, + "notify": { + "activityLog": "Záznamy o činnosti", + "backupComplete": "Zálohování serveru {} bylo úspěšně dokončeno", + "backupStarted": "Bylo spuštěno zálohování serveru {}", + "downloadLogs": "Stáhnout protokoly podpory?", + "finishedPreparing": "Dokončili jsme přípravu protokolů podpory. Klikněte na tlačítko Stáhnout pro stažení", + "logout": "Odhlásit se", + "preparingLogs": " Počkejte prosím, než připravíme vaše protokoly... Až budou připraveny, pošleme vám oznámení. U rozsáhlých zavádění to může chvíli trvat.", + "supportLogs": "Protokoly podpory" + }, + "panelConfig": { + "adminControls": "Ovládání správce", + "allowedServers": "Povolené servery", + "assignedRoles": "Přidělené role", + "cancel": "Zrušit", + "clearComms": "Vymazat nevykonané příkazy", + "delete": "Smazat", + "edit": "Upravit", + "enabled": "Zapnuto", + "match": "Hesla musí být stejná", + "newRole": "Přidat novou roli", + "newUser": "Přidat nového uživatele", + "pageTitle": "Nastavení panelu", + "role": "Role", + "roles": "Role", + "roleUsers": "Uživatelé s rolí", + "save": "Uložit", + "superConfirm": "Postupujte pouze v případě, že chcete, aby měl tento uživatel přístup ke VŠEM (ke všem uživatelským účtům, serverům, nastavení panelu atd.). Může vám dokonce odebrat práva superuživatele.", + "superConfirmTitle": "Povolit superuživatele? Jste si jisti?", + "user": "Uživatel", + "users": "Uživatelé", + "loginImage": "Nahrajte obrázek na pozadí přihlašovací obrazovky.", + "backgroundUpload": "Nahrání pozadí", + "loginBackground": "Přihlašovací obrázek na pozadí", + "select": "Vyberte", + "selectImage": "Vyberte obrázek", + "preview": "Náhled" + }, + "rolesConfig": { + "config": "Nastavení role", + "configDesc": "Zde můžete změnit nastavení své role.", + "configUpdate": "Poslední aktualizace: ", + "created": "Vytvořený: ", + "delRole": "Smazat roli", + "doesNotExist": "Nemůžete odstranit něco, co ještě neexistuje", + "pageTitle": "Upravit roli", + "pageTitleNew": "Nová role", + "permAccess": "Přístup?", + "permName": "Název oprávnění", + "permsServer": "Oprávnění, která má tato role pro tyto servery", + "roleConfigArea": "Oblast nastavení role", + "roleDesc": "Jak byste chtěl aby se tato role jmenovala?", + "roleName": "Název role: ", + "rolePerms": "Oprávnění role", + "roleServers": "Povolené servery", + "roleTitle": "Nastavení rolí", + "roleUserName": "Uživatelské jméno", + "roleUsers": "Uživatelé role: ", + "serverAccess": "Přístup?", + "serverName": "Název serveru", + "serversDesc": "servery, ke kterým má tato role přístup", + "selectManager": "Výběr manažera pro tuto roli" + }, + "serverBackups": { + "backupAtMidnight": "Automatické zálohování o půlnoci?", + "backupNow": "Zálohovat nyní!", + "backupTask": "Bylo spuštěno zálohování.", + "cancel": "Zrušit", + "clickExclude": "Kliknutím vyberete výjimku", + "compress": "Komprimovat zálohu", + "confirm": "Potvrdit", + "confirmDelete": "Chcete tuto zálohu odstranit? Tuto akci nelze vrátit zpět.", + "confirmRestore": "Jste si jisti, že chcete provést obnovu z této zálohy. Všechny aktuální soubory serveru se změní na stav zálohy a nebude možné je obnovit.", + "currentBackups": "Aktuální zálohy", + "delete": "Smazat", + "destroyBackup": "Zničit zálohu \" + file_to_del + \"?", + "download": "Stáhnout", + "excludedBackups": "Vyloučené cesty: ", + "excludedChoose": "Vyberte cesty, které chcete ze zálohování vyloučit.", + "exclusionsTitle": "Vyloučení ze zálohování", + "maxBackups": "Maximální počet záloh", + "maxBackupsDesc": "Crafty neuloží více než N záloh a odstraní nejstarší (zadejte 0 pro zachování všech).", + "options": "Nastavení", + "path": "Cesta", + "restore": "Obnovit", + "restoring": "Obnovení zálohy. To může chvíli trvat. Buďte prosím trpěliví.", + "save": "Uložit", + "shutdown": "Vypnout server po dobu zálohování", + "size": "Velikost", + "storageLocation": "Umístění úložiště", + "storageLocationDesc": "Kam chcete ukládat zálohy?" + }, + "serverConfig": { + "bePatientDelete": "Buďte prosím trpěliví, než odstraníme váš server z panelu Crafty. Tato obrazovka se za chvíli zavře.", + "bePatientDeleteFiles": "Buďte prosím trpěliví, než odstraníme váš server z panelu Crafty a všechny jeho soubory. Tato obrazovka se za chvíli zavře.", + "bePatientUpdate": "Prosím, buďte trpěliví, dokud server neaktualizujeme. Doba stahování se může lišit v závislosti na rychlosti vašeho internetu.
Tato obrazovka se za chvíli aktualizuje", + "cancel": "Zrušit", + "crashTime": "Časový limit havárie", + "crashTimeDesc": "Jak dlouho bychom měli čekat, než budeme váš server považovat za havarovaný?", + "deleteFilesQuestion": "Odstranit soubory serveru z přístroje?", + "deleteFilesQuestionMessage": "Chcete, aby Crafty odstranil všechny soubory serveru z hostitelského počítače?

To se týká i zálohování serverů.", + "deleteServer": "Odstranit server", + "deleteServerQuestion": "Odstranit server?", + "deleteServerQuestionMessage": "Opravdu chcete tento server odstranit? Po tomto kroku již není cesty zpět...", + "exeUpdateURL": "Adresa URL pro aktualizaci spustitelných souborů serveru", + "exeUpdateURLDesc": "Adresa URL pro přímé stahování aktualizací.", + "javaNoChange": "Nepřepisujte", + "javaVersion": "Přepsat aktuální verzi Javy", + "javaVersionDesc": "Pokud se chystáte přepsat Javu, ujistěte se, že je aktuální cesta k Javě v příkazu 'execution command' zabalena do uvozovek (výchozí proměnná 'java' je vyloučena).", + "noDelete": "Ne, vrať se zpět", + "noDeleteFiles": "Ne, stačí jen vyjmout z panelu", + "removeOldLogsAfter": "Odstranit staré protokoly po", + "removeOldLogsAfterDesc": "Kolik dní musí být soubor protokolu starý, aby byl smazán (0 je vypnuto)", + "save": "Uložit", + "sendingDelete": "Odstraňování serveru", + "sendingRequest": "Odeslání žádosti...", + "serverAutoStart": "Automatické spuštění serveru", + "serverAutostartDelay": "Zpoždění automatického spuštění serveru", + "serverAutostartDelayDesc": "Zpoždění před automatickým spuštěním (je-li povoleno níže)", + "serverCrashDetection": "Detekce pádu serveru", + "serverExecutable": "Spustitelný soubor serveru", + "serverExecutableDesc": "Spustitelný soubor pro server", + "serverExecutionCommand": "Příkaz pro spuštění serveru", + "serverExecutionCommandDesc": "Co se spustí ve skrytém terminálu", + "serverIP": "Adresa serveru", + "serverIPDesc": "IP adresa, ke které by se měl Crafty připojit pro statistiky (pokud máte problémy, zkuste místo 127.0.0.1 zadat skutečnou IP adresu).", + "serverLogLocation": "Umístění protokolu serveru", + "serverLogLocationDesc": "Cesta k souboru protokolu", + "serverName": "Název serveru", + "serverNameDesc": "Jak chcete aby se tento server jmenoval", + "serverPath": "Pracovní adresář serveru", + "serverPathDesc": "Absolutní úplná cesta (bez spustitelného souboru)", + "serverPort": "Port serveru", + "serverPortDesc": "Port Crafty should connect to for stats", + "serverStopCommand": "Příkaz pro zastavení serveru", + "serverStopCommandDesc": "Příkaz k odeslání programu pro jeho zastavení", + "showStatus": "Zobrazit na veřejné stavové stránce", + "stopBeforeDeleting": "Před odstraněním serveru jej prosím zastavte", + "update": "Aktualizovat spustitelný soubor", + "yesDelete": "Ano, smazat", + "yesDeleteFiles": "Ano, smazat soubory", + "shutdownTimeout": "Časový limit pro vypnutí", + "timeoutExplain1": "Jak dlouho bude Crafty čekat na vypnutí serveru po provedení příkazu", + "timeoutExplain2": "než proces ukončí." + }, + "serverConfigHelp": { + "desc": "Zde můžete změnit konfiguraci serveru.", + "perms": [ + "Doporučujeme NEMĚNIT cesty serveru spravované Craftym.", + "Změna cest MŮŽE něco rozbít, zejména v operačních systémech typu Linux, kde jsou práva k souborům více uzamčena.", + "

", + "Pokud máte pocit, že musíte změnit místo, kde je server umístěn, můžete tak učinit, pokud dáte uživateli \"crafty\" oprávnění ke čtení / zápisu k cestě k serveru.", + "
", + "
", + "V systému Linux to nejlépe provedete následujícím příkazem:
", + "", + " sudo chown crafty:crafty /cesta/k/vašemu/serveru -R
", + " sudo chmod 2775 /cesta/k/vašemu/serveru -R
", + "
" + ], + "title": "Oblast nastavení serveru" + }, + "serverDetails": { + "backup": "Záloha", + "config": "Nastavení", + "files": "Soubory", + "logs": "Protokoly", + "playerControls": "Správa hráčů", + "schedule": "Harmonogram", + "serverDetails": "Podrobnosti o serveru", + "terminal": "Terminál", + "metrics": "Metrika", + "reset": "Obnovit posuvník", + "filter": "Filtrovat protokoly", + "filterList": "Filtrovaná slova" + }, + "serverFiles": { + "clickUpload": "Klikněte sem a vyberte své soubory", + "close": "Zavřít", + "createDir": "Vytvořit složku", + "createDirQuestion": "Jaký chcete pojmenovat novou složku?", + "createFile": "Vytvořit soubor", + "createFileQuestion": "Jaké jméno chcete zvolit pro nový soubor?", + "default": "Výchozí", + "delete": "Smazat", + "deleteItemQuestion": "Jste si jisti, že chcete odstranit \" + name + \"?", + "deleteItemQuestionMessage": "Odstraňujete \\\"\" + path + \"\\\"!

Tato akce bude nevratná a navždy ztracená!", + "download": "Stáhnout", + "editingFile": "Upravit soubor", + "error": "Chyba při získání souborů", + "fileReadError": "Chyba při čtení souboru", + "files": "Soubory", + "keybindings": "Klávesové zkratky", + "loadingRecords": "Načítání souborů...", + "noDelete": "Ne", + "noscript": "Správce souborů nefunguje bez JavaScriptu", + "rename": "Přejmenovat", + "renameItemQuestion": "Jaký by měl být nový název?", + "save": "Uložit", + "size": "Přepnout velikost editoru", + "stayHere": "NEOPOUŠTĚJTE TUTO STRÁNKU!", + "unsupportedLanguage": "Varování: Tento typ souboru není podporovaný", + "unzip": "Rozbalit", + "upload": "Nahrát", + "uploadTitle": "Nahrát soubory do: ", + "waitUpload": "Počkejte prosím, než se vaše soubory nahrají... To může chvíli trvat.", + "yesDelete": "Ano, chápu následky" + }, + "serverPlayerManagement": { + "bannedPlayers": "Zabanovaní hráči", + "loadingBannedPlayers": "Načítání zabanovaných hráčů", + "players": "Hráči" + }, + "serverScheduleConfig": { + "backup": "Zálohovat server", + "select": "Základní / Cron / Řetězová reakce", + "basic": "Základní", + "children": "Propojené dětské úlohy:", + "command": "Příkaz", + "command-explain": "Jaký příkaz máme provést? Neuvádějte znak '/'", + "cron": "Cron", + "cron-explain": "Zadejte řetězec cronu -- POZNÁMKA: 0 = Pondělí v poslední možnosti.", + "custom": "Vlastní příkaz", + "days": "Dny", + "enabled": "Zapnuto", + "hours": "Hodiny", + "interval": "Interval", + "interval-explain": "Jak často chcete, aby se tento plán prováděl?", + "minutes": "Minuty", + "offset": "Posunutí prodlevy", + "offset-explain": "Jak dlouho bychom měli čekat na spuštění této úlohy po spuštění první úlohy? (sekund)", + "one-time": "Odstranit po provedení", + "parent": "Výběr plánu rodiče", + "parent-explain": "Který plán by měl spustit tento?", + "reaction": "Reakce", + "restart": "Restartovat server", + "start": "Spustit server", + "stop": "Vypnout server", + "time": "Čas", + "time-explain": "V kolik hodin chcete, aby byl váš plán spuštěn?" + }, + "serverSchedules": { + "scheduledTasks": "Naplánované úlohy", + "create": "Vytvořit nový plán", + "name": "Název", + "action": "Akce", + "command": "Příkaz", + "interval": "Interval", + "nextRun": "Příští spuštění", + "enabled": "Zapnuto", + "edit": "Upravit", + "every": "Každý", + "yes": "Ano", + "no": "Ne", + "cron": "Řetězec Crong", + "details": "Podrobnosti o plánu", + "child": "Dítě plánu s ID", + "areYouSure": "Odstranění naplánované úlohy?", + "close": "Zavřít", + "delete": "Odstranit", + "cancel": "Zrušit", + "cannotSee": "Nevidíte všechno?", + "cannotSeeOnMobile": "Kliknutím na naplánovanou úlohu získáte podrobné informace.", + "confirm": "Potvrdit", + "confirmDelete": "Chcete tuto naplánovanou úlohu odstranit? Tuto akci nelze vrátit zpět." + }, + "serverStats": { + "cpuUsage": "Využití CPU", + "description": "Popis", + "errorCalculatingUptime": "Chyba při výpočtu doby provozu", + "memUsage": "Využití paměti", + "offline": "Offline", + "online": "Online", + "players": "Hráči", + "serverStarted": "Server spuštěn", + "serverStatus": "Stav serveru", + "serverTime": "UTC čas", + "serverTimeZone": "Časové pásmo serveru", + "serverUptime": "Doba provozu serveru", + "starting": "Zpožděný start", + "unableToConnect": "Nelze se připojit", + "version": "Verze" + }, + "serverTerm": { + "commandInput": "Zadejte příkaz", + "delay-explained": "Služba/agent byla nedávno spuštěna a zpožďuje spuštění instance minecraft serveru.", + "importing": "Importování...", + "restart": "Restartovat", + "sendCommand": "Odeslat příkaz", + "start": "Spustit", + "starting": "Zpožděný start", + "stop": "Zastavit", + "stopScroll": "Zastavit automatické posouvání", + "updating": "Aktualizace...", + "installing": "Instalace..." + }, + "serverMetrics": { + "resetZoom": "Reset Zoom", + "zoomHint1": "Chcete-li graf přiblížit, podržte klávesu Shift a poté použijte kolečko myši.", + "zoomHint2": "Případně můžete podržet klávesu Shift a kliknout a přetáhnout oblast, kterou chcete přiblížit." + }, + "serverWizard": { + "absoluteServerPath": "Absolutní cesta k serveru", + "absoluteZipPath": "Absolutní cesta k serveru", + "addRole": "Přidání serveru k existujícím rolím", + "autoCreate": "Pokud nebude vybrána žádná, Crafty ji vyrobí!", + "bePatient": "Buďte prosím trpěliví, protože musíme ' + (importing ? 'importovat' : 'stáhnout') + ' server", + "buildServer": "Sestavit server!", + "clickRoot": "Klikněte zde pro výběr kořenového adresáře", + "close": "Zavřít", + "defaultPort": "25565 výchozí hodnota", + "downloading": "Stahování serveru...", + "explainRoot": "Klikněte na tlačítko níže a vyberte kořenový adresář vašeho serveru z archivu.", + "importing": "Importování serveru...", + "importServer": "Importování existujícího serveru", + "importServerButton": "Importovat server!", + "importZip": "Imporovat ze souboru Zip", + "uploadZip": "Nahrání souboru Zip pro importování serveru", + "maxMem": "Maximální paměť", + "minMem": "Minimální paměť", + "myNewServer": "Nový server", + "newServer": "Vytvořit nový server", + "quickSettings": "Rychlé nastavení", + "quickSettingsDescription": "Nebojte se, můžete je změnit později.", + "resetForm": "Obnovit nastavení formuláře", + "save": "Uložit", + "selectRole": "Vyberte roli(e)", + "selectRoot": "Vyberte kořenový adresář archivu", + "selectType": "Typ serveru (Vanilla, Servery, Modované atd.)", + "selectServer": "Vyberte server", + "selectVersion": "Vyberte verzi", + "selectZipDir": "Vyberte adresář v archivu, ze kterého mají být soubory rozbaleny.", + "serverJar": "Soubor spustitelný serverem", + "serverName": "Název serveru", + "serverPath": "Cesta k serveru", + "serverPort": "Port serveru", + "serverType": "Typ serveru", + "serverSelect": "Výběr serveru", + "serverVersion": "Verze serveru", + "sizeInGB": "Velikost v GB", + "zipPath": "Cesta k serveru" + }, + "sidebar": { + "contribute": "Přispět", + "credits": "Zásluhy", + "dashboard": "Ovládací panel", + "documentation": "Dokumentace", + "navigation": "Navigace", + "newServer": "Vytvořit nový server", + "servers": "Servery" + }, + "userConfig": { + "apiKey": "Klíče API", + "auth": "Autorizovaný? ", + "config": "Nastavení", + "configArea": "Uživatelská nastavení", + "configAreaDesc": "Zde můžete změnit všechna nastavení uživatele.", + "confirmDelete": "Jste si jisti, že chcete tohoto uživatele odstranit? Tato akce je nevratná.", + "craftyPermDesc": "Oprávnění tohoto uživatele ", + "craftyPerms": "Oprávnění: ", + "created": "Vytvořeno: ", + "deleteUser": "Smazat uživatele: ", + "deleteUserB": "Smazat uživatele", + "delSuper": "Super uživatele nelze odstranit", + "enabled": "Povolen", + "gravDesc": "Tento e-mail je určen výhradně pro použití se službou Gravatar™. Crafty nebude v žádném případě používat tento e-mail k ničemu jinému než k vyhledávání vašeho Gravataru™.", + "gravEmail": "Gravatar™ E-mail", + "lastIP": "Poslední IP: ", + "lastLogin": "Poslední přihlášení: ", + "lastUpdate": "Poslední aktualizace: ", + "leaveBlank": "Chcete-li upravit uživatele beze změny hesla, ponechte pole prázdné.", + "member": "Člen?", + "notExist": "Nemůžete odstranit něco, co neexistuje!", + "pageTitle": "Upravit uživatele", + "pageTitleNew": "Vytvořit uživatele", + "password": "Nové heslo", + "permName": "Název povolení", + "repeat": "Zopakujte heslo", + "roleName": "Název role", + "super": "Super uživatel", + "userLang": "Jazyk uživatele", + "userTheme": "Motiv UI", + "userName": "Uživatelské jméno", + "userNameDesc": "Jak chcete aby se tento uživatel jmenoval?", + "userRoles": "Role uživatele", + "userRolesDesc": "Role, jejichž je tento uživatel členem.", + "userSettings": "Nastavení uživatele", + "uses": "Počet povolených použití (-1==bez omezení)", + "manager": "Správce", + "selectManager": "Vyberte Správce pro uživatele" + } +} \ No newline at end of file From 1daaecc790a18e2c32607e621e1f6b98a4886258 Mon Sep 17 00:00:00 2001 From: Andrew Date: Thu, 29 Dec 2022 19:05:55 -0500 Subject: [PATCH 08/84] Remove un-needed log messages --- app/frontend/templates/panel/dashboard.html | 1 - 1 file changed, 1 deletion(-) diff --git a/app/frontend/templates/panel/dashboard.html b/app/frontend/templates/panel/dashboard.html index 07fc6b2f..adfe7645 100644 --- a/app/frontend/templates/panel/dashboard.html +++ b/app/frontend/templates/panel/dashboard.html @@ -824,7 +824,6 @@ setTimeout(finishTimeout, 60000); }); function finishTimeout() { - console.log("TIMEOUT FINISHED") warn("It seems this is taking a while...it's possible you're using UBlock or a similar ad blocker and it's causing some of our connections to not make it to the server. Try disabling your ad blocker.", null, 'wssError'); } From 050f4efa54c6cacb5ebd97f14671bd64a49064c1 Mon Sep 17 00:00:00 2001 From: Freddy 0 Date: Fri, 30 Dec 2022 10:59:59 +0000 Subject: [PATCH 09/84] Update file unraid.xml --- docker/unraid.xml | 23 ++++++++++++++--------- 1 file changed, 14 insertions(+), 9 deletions(-) diff --git a/docker/unraid.xml b/docker/unraid.xml index 8784ea8f..a39a9e8a 100644 --- a/docker/unraid.xml +++ b/docker/unraid.xml @@ -1,15 +1,26 @@ - True + False Crafty-4 - registry.gitlab.com/crafty-controller/crafty-4:latest - registry.gitlab.com/crafty-controller/crafty-4 + https://registry.gitlab.com/crafty-controller/ + crafty-controller/crafty-4:latest bridge sh false https://discord.gg/9VJPhCE https://craftycontrol.com/ + GNU GLP V3 + + latest + Latest version of Crafty, which should be used for production purposes as it is the most stable + + + dev + Development version of Crafty, only generally used for testing purposes, because of its less stable nature + +https://wiki.craftycontrol.com/uploads/en/crafty%204%20dashboard%20with%20one%20server.jpeg +https://wiki.craftycontrol.com/uploads/en/crafty%204%20server%20setup%20details.png Crafty 4 is the next iteration of our Minecraft Server Wrapper / Controller / Launcher. Boasting a clean new look, rebuilt from the ground up. Crafty 4 brings a whole host of new features such as Bedrock support. With SteamCMD support on the way! Default login Credentrails are username: "admin" password: "crafty" Crafty 4 is the successor of Crafty Controller, the Docker image is no longer maintained on DockerHub. (now on GitLab) @@ -26,12 +37,6 @@ For migration from 3.x please refer to the documentation: https://wiki.craftycon Help to support Crafty on Kofi https://ko-fi.com/arcadiatech - Crafty 4 is the next iteration of our Minecraft Server Wrapper / Controller / Launcher. Boasting a clean new look, rebuilt from the ground up. Crafty 4 brings a whole host of new features such as Bedrock support. With SteamCMD support on the way! -Default login Credentrails are username: "admin" password: "crafty" -Crafty 4 is the successor of Crafty Controller, the Docker image is no longer maintained on DockerHub. (now on GitLab) -For official support join the Discord: https://discord.gg/9VJPhCE -For migration from 3.x please refer to the documentation: https://wiki.craftycontrol.com/en/4/ - bridge From 9ebdbbf5af14719eb19845d6f11cfb9cd64ec951 Mon Sep 17 00:00:00 2001 From: Andrew Date: Sun, 1 Jan 2023 23:13:07 -0500 Subject: [PATCH 10/84] Fix bug where nested reaction tasks would stack --- app/classes/shared/tasks.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/app/classes/shared/tasks.py b/app/classes/shared/tasks.py index e7266db7..9ff66418 100644 --- a/app/classes/shared/tasks.py +++ b/app/classes/shared/tasks.py @@ -541,6 +541,9 @@ class TasksManager: def schedule_watcher(self, event): if not event.exception: + task = self.controller.management.get_scheduled_task_model( + int(event.job_id) + ) if str(event.job_id).isnumeric(): task = self.controller.management.get_scheduled_task_model( int(event.job_id) @@ -556,7 +559,7 @@ class TasksManager: if task.one_time: self.remove_job(task.schedule_id) logger.info("one time task detected. Deleting...") - else: + elif task.interval_type != "reaction": self.controller.management.update_scheduled_task( task.schedule_id, { From 872489d12590bcf242f96569507ebfd49e2a9907 Mon Sep 17 00:00:00 2001 From: Andrew Date: Mon, 2 Jan 2023 12:20:18 -0500 Subject: [PATCH 11/84] Remove useless block in unzip method This was causing an error. --- app/classes/shared/file_helpers.py | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) diff --git a/app/classes/shared/file_helpers.py b/app/classes/shared/file_helpers.py index 82b5a560..e26220bb 100644 --- a/app/classes/shared/file_helpers.py +++ b/app/classes/shared/file_helpers.py @@ -298,14 +298,7 @@ class FileHelpers: try: with zipfile.ZipFile(zip_path, "r") as zip_ref: zip_ref.extractall(temp_dir) - for i in enumerate(zip_ref.filelist): - if len(zip_ref.filelist) > 1 or not zip_ref.filelist[ - i - ].filename.endswith("/"): - break - - full_root_path = temp_dir - + full_root_path = temp_dir for item in os.listdir(full_root_path): if os.path.isdir(os.path.join(full_root_path, item)): try: From 6ebb53be21fe9c7167123c0c7855ffc69183baea Mon Sep 17 00:00:00 2001 From: Andrew Date: Mon, 2 Jan 2023 14:01:33 -0500 Subject: [PATCH 12/84] Remove beta naming from intro --- CONTRIBUTING.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index ab58ba50..80d148d1 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -2,7 +2,7 @@ *Don't Panic!*

First off, thank you for choosing Crafty Controller!
-We hope you've been enjoying the beta so far and are absolutely thrilled that you are looking to contribute! +We hope you've been enjoying Crafty so far and are absolutely thrilled that you are looking to contribute! The following guide will show you how to easily and safely contribute to our current workflow. There are a few components that need to be taken into account and processes that need followed before we can merge your code into our repository.

From 985178b9935800a248b1514d0438294e0cd92995 Mon Sep 17 00:00:00 2001 From: Andrew Date: Mon, 2 Jan 2023 14:26:42 -0500 Subject: [PATCH 13/84] Update zip import status --- app/classes/shared/main_controller.py | 1 + 1 file changed, 1 insertion(+) diff --git a/app/classes/shared/main_controller.py b/app/classes/shared/main_controller.py index e6263cdf..3a229d20 100644 --- a/app/classes/shared/main_controller.py +++ b/app/classes/shared/main_controller.py @@ -815,6 +815,7 @@ class Controller: user_id, server_type="minecraft-bedrock", ) + ServersController.set_import(new_id) self.import_helper.import_bedrock_zip_server( temp_dir, new_server_dir, full_jar_path, port, new_id ) From 4922998b144c8837554946194c9f54dfc5c79658 Mon Sep 17 00:00:00 2001 From: Andrew Date: Mon, 2 Jan 2023 14:34:08 -0500 Subject: [PATCH 14/84] Remove extra task definition --- app/classes/shared/tasks.py | 3 --- 1 file changed, 3 deletions(-) diff --git a/app/classes/shared/tasks.py b/app/classes/shared/tasks.py index 9ff66418..17940181 100644 --- a/app/classes/shared/tasks.py +++ b/app/classes/shared/tasks.py @@ -541,9 +541,6 @@ class TasksManager: def schedule_watcher(self, event): if not event.exception: - task = self.controller.management.get_scheduled_task_model( - int(event.job_id) - ) if str(event.job_id).isnumeric(): task = self.controller.management.get_scheduled_task_model( int(event.job_id) From c80d357f13a1ed23c6d19e3b37aa81461149172a Mon Sep 17 00:00:00 2001 From: Zedifus Date: Mon, 2 Jan 2023 20:59:29 +0000 Subject: [PATCH 15/84] Fix CodeQuality, line length --- app/classes/shared/server.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/app/classes/shared/server.py b/app/classes/shared/server.py index 86afa1cf..745d840d 100644 --- a/app/classes/shared/server.py +++ b/app/classes/shared/server.py @@ -655,7 +655,8 @@ class ServerInstance: # We get the server command parameters from forge script server_command = re.findall( r"java @([a-zA-Z0-9_\.]+)" - r" @([a-z.\/\-]+)([0-9.\-]+)\/\b([a-z_0-9]+\.txt)\b( .{2,4})?", + r" @([a-z.\/\-]+)([0-9.\-]+)" + r"\/\b([a-z_0-9]+\.txt)\b( .{2,4})?", run_file_text, )[0] From d4d8fa21d5cf014648b8bd6fe74c2e7a5b05f25e Mon Sep 17 00:00:00 2001 From: Zedifus Date: Mon, 2 Jan 2023 21:01:46 +0000 Subject: [PATCH 16/84] Update changelog !515 --- CHANGELOG.md | 1 + 1 file changed, 1 insertion(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index a61a3c7b..cb023634 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -12,6 +12,7 @@ TBD - Fix root dir selection in Upload Zip Import ([Merge Request](https://gitlab.com/crafty-controller/crafty-4/-/merge_requests/508)) - Fix stats error on mac M1 chips ([Merge Request](https://gitlab.com/crafty-controller/crafty-4/-/merge_requests/512)) - Fix window path escape on java override ([Merge Request](https://gitlab.com/crafty-controller/crafty-4/-/merge_requests/513)) +- Fix Forge import stalling on 1.17 Forge servers ([Merge Request](https://gitlab.com/crafty-controller/crafty-4/-/merge_requests/515)) ### Tweaks - Make server directories non-configurable ([Merge Request](https://gitlab.com/crafty-controller/crafty-4/-/merge_requests/511)) - Add popover to server port to detail it's purpose ([Merge Request](https://gitlab.com/crafty-controller/crafty-4/-/merge_requests/514)) From 695675aa388f7c0a8bc76da7e238f4e744a85d94 Mon Sep 17 00:00:00 2001 From: Zedifus Date: Mon, 2 Jan 2023 21:21:25 +0000 Subject: [PATCH 17/84] Update changelog !516 --- CHANGELOG.md | 1 + 1 file changed, 1 insertion(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index cb023634..2a36de19 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -13,6 +13,7 @@ TBD - Fix stats error on mac M1 chips ([Merge Request](https://gitlab.com/crafty-controller/crafty-4/-/merge_requests/512)) - Fix window path escape on java override ([Merge Request](https://gitlab.com/crafty-controller/crafty-4/-/merge_requests/513)) - Fix Forge import stalling on 1.17 Forge servers ([Merge Request](https://gitlab.com/crafty-controller/crafty-4/-/merge_requests/515)) +- Fix issue with server config for SU Accounts ([Merge Request](https://gitlab.com/crafty-controller/crafty-4/-/merge_requests/516)) ### Tweaks - Make server directories non-configurable ([Merge Request](https://gitlab.com/crafty-controller/crafty-4/-/merge_requests/511)) - Add popover to server port to detail it's purpose ([Merge Request](https://gitlab.com/crafty-controller/crafty-4/-/merge_requests/514)) From 2f8381ea6ee3230347fe11f748604bf54b8cf11c Mon Sep 17 00:00:00 2001 From: Zedifus Date: Mon, 2 Jan 2023 21:40:41 +0000 Subject: [PATCH 18/84] Update changelog !518 --- CHANGELOG.md | 1 + 1 file changed, 1 insertion(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 2a36de19..cc6f600f 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -17,6 +17,7 @@ TBD ### Tweaks - Make server directories non-configurable ([Merge Request](https://gitlab.com/crafty-controller/crafty-4/-/merge_requests/511)) - Add popover to server port to detail it's purpose ([Merge Request](https://gitlab.com/crafty-controller/crafty-4/-/merge_requests/514)) +- Add server start timeout w/ WS Warning ([Merge Request](https://gitlab.com/crafty-controller/crafty-4/-/merge_requests/518)) ### Lang TBD

From 32a49add524beac8af4e225d8258d383da7c06d0 Mon Sep 17 00:00:00 2001 From: Zedifus Date: Mon, 2 Jan 2023 22:15:29 +0000 Subject: [PATCH 19/84] Update changelog !521 --- CHANGELOG.md | 1 + 1 file changed, 1 insertion(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index cc6f600f..602f0c69 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -14,6 +14,7 @@ TBD - Fix window path escape on java override ([Merge Request](https://gitlab.com/crafty-controller/crafty-4/-/merge_requests/513)) - Fix Forge import stalling on 1.17 Forge servers ([Merge Request](https://gitlab.com/crafty-controller/crafty-4/-/merge_requests/515)) - Fix issue with server config for SU Accounts ([Merge Request](https://gitlab.com/crafty-controller/crafty-4/-/merge_requests/516)) +- Fix Nested reaction tasks ([Merge Request](https://gitlab.com/crafty-controller/crafty-4/-/merge_requests/521)) ### Tweaks - Make server directories non-configurable ([Merge Request](https://gitlab.com/crafty-controller/crafty-4/-/merge_requests/511)) - Add popover to server port to detail it's purpose ([Merge Request](https://gitlab.com/crafty-controller/crafty-4/-/merge_requests/514)) From 149744074fddac8890909cadb7a00dfc565db790 Mon Sep 17 00:00:00 2001 From: Zedifus Date: Mon, 2 Jan 2023 22:52:03 +0000 Subject: [PATCH 20/84] Update changelog !522 --- CHANGELOG.md | 1 + 1 file changed, 1 insertion(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 602f0c69..f13d1529 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -15,6 +15,7 @@ TBD - Fix Forge import stalling on 1.17 Forge servers ([Merge Request](https://gitlab.com/crafty-controller/crafty-4/-/merge_requests/515)) - Fix issue with server config for SU Accounts ([Merge Request](https://gitlab.com/crafty-controller/crafty-4/-/merge_requests/516)) - Fix Nested reaction tasks ([Merge Request](https://gitlab.com/crafty-controller/crafty-4/-/merge_requests/521)) +- Remove legacy unzip code causing issues with single file zip files ([Merge Request](https://gitlab.com/crafty-controller/crafty-4/-/merge_requests/522)) ### Tweaks - Make server directories non-configurable ([Merge Request](https://gitlab.com/crafty-controller/crafty-4/-/merge_requests/511)) - Add popover to server port to detail it's purpose ([Merge Request](https://gitlab.com/crafty-controller/crafty-4/-/merge_requests/514)) From 52ef76e15b927a8da19966fb80dadc79b841dc76 Mon Sep 17 00:00:00 2001 From: Andrew Date: Tue, 3 Jan 2023 10:14:10 -0800 Subject: [PATCH 21/84] Replace google ping for ntp for usability in china --- app/classes/shared/helpers.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/classes/shared/helpers.py b/app/classes/shared/helpers.py index 39b7b12e..c5238ae8 100644 --- a/app/classes/shared/helpers.py +++ b/app/classes/shared/helpers.py @@ -272,7 +272,7 @@ class Helpers: @staticmethod def check_internet(): try: - requests.get("https://google.com", timeout=1) + requests.get("https://ntp.org", timeout=1) return True except Exception: return False From 59a904228732dcfcd60b45000303ffb04676d79f Mon Sep 17 00:00:00 2001 From: Freddy 0 Date: Sat, 7 Jan 2023 14:17:14 +0000 Subject: [PATCH 22/84] Fix for the parsed regristry url being incorrect / non existent --- docker/unraid.xml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/docker/unraid.xml b/docker/unraid.xml index a39a9e8a..776282c4 100644 --- a/docker/unraid.xml +++ b/docker/unraid.xml @@ -2,15 +2,15 @@ False Crafty-4 - https://registry.gitlab.com/crafty-controller/ - crafty-controller/crafty-4:latest + registry.gitlab.com/crafty-controller/crafty-4/Repository> + registry.gitlab.com/crafty-controller/crafty-4 bridge sh false https://discord.gg/9VJPhCE https://craftycontrol.com/ - GNU GLP V3 + GNU GPL V3 latest Latest version of Crafty, which should be used for production purposes as it is the most stable From a0e62dbb1d27e73e1ae941613f3ba9119f33df26 Mon Sep 17 00:00:00 2001 From: Zedifus Date: Sat, 7 Jan 2023 14:47:27 +0000 Subject: [PATCH 23/84] Update changelog !524 --- CHANGELOG.md | 1 + 1 file changed, 1 insertion(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index f13d1529..933d1c2a 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -20,6 +20,7 @@ TBD - Make server directories non-configurable ([Merge Request](https://gitlab.com/crafty-controller/crafty-4/-/merge_requests/511)) - Add popover to server port to detail it's purpose ([Merge Request](https://gitlab.com/crafty-controller/crafty-4/-/merge_requests/514)) - Add server start timeout w/ WS Warning ([Merge Request](https://gitlab.com/crafty-controller/crafty-4/-/merge_requests/518)) +- Replace google ping for ntp for internet checks in locked-down countries ([Merge Request](https://gitlab.com/crafty-controller/crafty-4/-/merge_requests/524)) ### Lang TBD

From ba82f8f6b7f6abb5b5db7c9a599c26d317e13d35 Mon Sep 17 00:00:00 2001 From: Zedifus Date: Sat, 7 Jan 2023 15:15:36 +0000 Subject: [PATCH 24/84] Add pushing to DockerHub registry --- .gitlab/docker-build.yml | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/.gitlab/docker-build.yml b/.gitlab/docker-build.yml index 297c2b20..4c906e4e 100644 --- a/.gitlab/docker-build.yml +++ b/.gitlab/docker-build.yml @@ -29,6 +29,7 @@ docker-build-dev: - docker run --rm --privileged aptman/qus -- -r - docker run --rm --privileged aptman/qus -s -- -p aarch64 x86_64 - echo $CI_BUILD_TOKEN | docker login -u "$CI_REGISTRY_USER" --password-stdin $CI_REGISTRY + - echo $DOCKERHUB_TOKEN | docker login -u "$DOCKERHUB_USER" --password-stdin $DOCKERHUB_REGISTRY script: - | tag=":$CI_COMMIT_REF_SLUG" @@ -45,6 +46,7 @@ docker-build-dev: --build-arg "BUILD_REF=${CI_COMMIT_SHA}" --build-arg "CRAFTY_VER=${VERSION}" --tag "$CI_REGISTRY_IMAGE${tag}" + --tag "arcadiatechnology/crafty-4${tag}" --platform linux/arm64/v8,linux/amd64 --push . after_script: @@ -83,6 +85,7 @@ docker-build-prod: - docker run --rm --privileged aptman/qus -- -r - docker run --rm --privileged aptman/qus -s -- -p aarch64 x86_64 - echo $CI_BUILD_TOKEN | docker login -u "$CI_REGISTRY_USER" --password-stdin $CI_REGISTRY + - echo $DOCKERHUB_TOKEN | docker login -u "$DOCKERHUB_USER" --password-stdin $DOCKERHUB_REGISTRY script: - | VERSION="${MAJOR}.${MINOR}.${SUB}" @@ -99,6 +102,8 @@ docker-build-prod: --build-arg "CRAFTY_VER=${VERSION}" --tag "$CI_REGISTRY_IMAGE:$VERSION" --tag "$CI_REGISTRY_IMAGE:latest" + --tag "arcadiatechnology/crafty-4:$VERSION" + --tag "arcadiatechnology/crafty-4:latest" --platform linux/arm64/v8,linux/amd64 --push . after_script: From 3a98a38889d2a5cfc1e8847adae2c14ba9b64695 Mon Sep 17 00:00:00 2001 From: Zedifus Date: Sat, 7 Jan 2023 15:22:45 +0000 Subject: [PATCH 25/84] Update changelog !526 --- CHANGELOG.md | 1 + 1 file changed, 1 insertion(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index f13d1529..94141a2b 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -20,6 +20,7 @@ TBD - Make server directories non-configurable ([Merge Request](https://gitlab.com/crafty-controller/crafty-4/-/merge_requests/511)) - Add popover to server port to detail it's purpose ([Merge Request](https://gitlab.com/crafty-controller/crafty-4/-/merge_requests/514)) - Add server start timeout w/ WS Warning ([Merge Request](https://gitlab.com/crafty-controller/crafty-4/-/merge_requests/518)) +- Add pushing to DockerHub registry ([Merge Request](https://gitlab.com/crafty-controller/crafty-4/-/merge_requests/526)) ### Lang TBD

From 5f177dbb71dd52803669b3a583a0ef8822b1cb1f Mon Sep 17 00:00:00 2001 From: Iain Powrie Date: Sat, 7 Jan 2023 15:51:28 +0000 Subject: [PATCH 26/84] Update documentation for DockerHub --- CHANGELOG.md | 2 +- README.md | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 7c3c4868..5f4a01b2 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -21,7 +21,7 @@ TBD - Add popover to server port to detail it's purpose ([Merge Request](https://gitlab.com/crafty-controller/crafty-4/-/merge_requests/514)) - Add server start timeout w/ WS Warning ([Merge Request](https://gitlab.com/crafty-controller/crafty-4/-/merge_requests/518)) - Replace google ping for ntp for internet checks in locked-down countries ([Merge Request](https://gitlab.com/crafty-controller/crafty-4/-/merge_requests/524)) -- Add pushing to DockerHub registry ([Merge Request](https://gitlab.com/crafty-controller/crafty-4/-/merge_requests/526)) +- Add pushing to DockerHub registry (`arcadiatechnology/crafty-4`) ([Merge Request](https://gitlab.com/crafty-controller/crafty-4/-/merge_requests/526)) ### Lang TBD

diff --git a/README.md b/README.md index 93888c5c..f9a19ae1 100644 --- a/README.md +++ b/README.md @@ -48,7 +48,7 @@ As the Dockerfile uses the permission structure of `crafty:root` **internally** ### - Using the registry image 🌎 The provided image supports both `arm64` and `amd64` out the box, if you have issues though you can build it yourself with the `compose` file in `docker/`. -The image is located at: `registry.gitlab.com/crafty-controller/crafty-4:latest` +The image is located at: `registry.gitlab.com/crafty-controller/crafty-4:latest` or `arcadiatechnology/crafty-4` | Branch | Status | | ----------------- | ------------------------------------------------------------------ | | :latest | [![pipeline status](https://gitlab.com/crafty-controller/crafty-4/badges/master/pipeline.svg)](https://gitlab.com/crafty-controller/crafty-4/-/commits/master) | From d3a62af21a3ea3754404c3414475ae8208244e61 Mon Sep 17 00:00:00 2001 From: Iain Powrie Date: Sat, 7 Jan 2023 15:59:52 +0000 Subject: [PATCH 27/84] Update changelog !519 --- CHANGELOG.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index a61a3c7b..931b71b1 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -16,7 +16,7 @@ TBD - Make server directories non-configurable ([Merge Request](https://gitlab.com/crafty-controller/crafty-4/-/merge_requests/511)) - Add popover to server port to detail it's purpose ([Merge Request](https://gitlab.com/crafty-controller/crafty-4/-/merge_requests/514)) ### Lang -TBD +- Added Czech translation ([Merge Request](https://gitlab.com/crafty-controller/crafty-4/-/merge_requests/519))

## --- [4.0.17/4.0.18] - 2022/11/30 From b6463d372b01063397c39e773b5e9f07a4339cc9 Mon Sep 17 00:00:00 2001 From: Freddy 0 Date: Sat, 7 Jan 2023 18:11:44 +0000 Subject: [PATCH 28/84] Switch to UnRAID xml to use DockerHub --- docker/unraid.xml | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/docker/unraid.xml b/docker/unraid.xml index 776282c4..c1b106fb 100644 --- a/docker/unraid.xml +++ b/docker/unraid.xml @@ -2,8 +2,8 @@ False Crafty-4 - registry.gitlab.com/crafty-controller/crafty-4/Repository> - registry.gitlab.com/crafty-controller/crafty-4 + arcadiatechnology/crafty-4 + https://hub.docker.com/r/arcadiatechnology/crafty-4 bridge sh @@ -21,11 +21,7 @@
https://wiki.craftycontrol.com/uploads/en/crafty%204%20dashboard%20with%20one%20server.jpeg https://wiki.craftycontrol.com/uploads/en/crafty%204%20server%20setup%20details.png - Crafty 4 is the next iteration of our Minecraft Server Wrapper / Controller / Launcher. Boasting a clean new look, rebuilt from the ground up. Crafty 4 brings a whole host of new features such as Bedrock support. With SteamCMD support on the way! -Default login Credentrails are username: "admin" password: "crafty" -Crafty 4 is the successor of Crafty Controller, the Docker image is no longer maintained on DockerHub. (now on GitLab) -For official support join the Discord: https://discord.gg/9VJPhCE -For migration from 3.x please refer to the documentation: https://wiki.craftycontrol.com/en/4/ + Crafty 4 is the next iteration of our Minecraft Server Wrapper / Controller / Launcher. [br]Boasting a clean new look, rebuilt from the ground up. [br] [br] Crafty 4 brings a whole host of new features such as Bedrock support. [br] With SteamCMD support on the way![br] **Default login Credentrails are username: "admin" password: "crafty". ** [br]Crafty 4 is the successor of Crafty Controller. [br]For official support join the Discord server https://discord.gg/9VJPhCE [br] For migration from 3.x please refer to the documentation: https://wiki.craftycontrol.com/en/4/ GameServers: Other: https://[IP]:[PORT:8443]/ From 31d621856421da4a3f1f7051ab9cd88d00d72471 Mon Sep 17 00:00:00 2001 From: Iain Powrie Date: Sat, 7 Jan 2023 18:23:45 +0000 Subject: [PATCH 29/84] Close v4.0.19 changelog --- CHANGELOG.md | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 2364b72d..56b9730d 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,7 +1,5 @@ # Changelog -## --- [4.0.19] - 2022/TBD -### New features -TBD +## --- [4.0.19] - 2022/01/07 ### Bug fixes - Fix port tooltip not showing on dash while server online. ([Merge Request](https://gitlab.com/crafty-controller/crafty-4/-/merge_requests/503)) - Fix '+' char in path causing any file operation to fail. ([Merge Request](https://gitlab.com/crafty-controller/crafty-4/-/merge_requests/502)) From d7d27b00c430b974158c78d1c033afd12da30a8c Mon Sep 17 00:00:00 2001 From: Zedifus Date: Sat, 7 Jan 2023 18:56:13 +0000 Subject: [PATCH 30/84] Prepare 4.0.20 release base --- CHANGELOG.md | 11 +++++++++++ README.md | 2 +- app/config/version.json | 2 +- 3 files changed, 13 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 56b9730d..88f02e8b 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,4 +1,15 @@ # Changelog +## --- [4.0.20] - 2022/TBD +### New features +TBD +### Bug fixes +TBD +### Tweaks +TBD +### Lang +TBD +

+ ## --- [4.0.19] - 2022/01/07 ### Bug fixes - Fix port tooltip not showing on dash while server online. ([Merge Request](https://gitlab.com/crafty-controller/crafty-4/-/merge_requests/503)) diff --git a/README.md b/README.md index f9a19ae1..059df365 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,5 @@ [![Crafty Logo](app/frontend/static/assets/images/logo_long.svg)](https://craftycontrol.com) -# Crafty Controller 4.0.19 +# Crafty Controller 4.0.20 > Python based Control Panel for your Minecraft Server ## What is Crafty Controller? diff --git a/app/config/version.json b/app/config/version.json index 02ec3ae1..d0dce112 100644 --- a/app/config/version.json +++ b/app/config/version.json @@ -1,5 +1,5 @@ { "major": 4, "minor": 0, - "sub": 19 + "sub": 20 } From 199c8a4fe6c92156e76f802632f43e44d5ba90d9 Mon Sep 17 00:00:00 2001 From: Andrew Date: Sun, 8 Jan 2023 00:32:08 -0500 Subject: [PATCH 31/84] Fix local java server imports --- app/classes/web/server_handler.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/classes/web/server_handler.py b/app/classes/web/server_handler.py index 62c549e5..1c0d5962 100644 --- a/app/classes/web/server_handler.py +++ b/app/classes/web/server_handler.py @@ -331,7 +331,7 @@ class ServerHandler(BaseHandler): return if import_type == "import_jar": - if not self.helper.is_subdir( + if self.helper.is_subdir( import_server_path, self.controller.project_root ): self.redirect( From 4031b74e00a350db7c1c71f64736631b881af7b0 Mon Sep 17 00:00:00 2001 From: Andrew Date: Mon, 9 Jan 2023 16:34:12 -0500 Subject: [PATCH 32/84] Hide server stats db from users --- app/classes/shared/helpers.py | 42 +++++++++++++++++++---------------- 1 file changed, 23 insertions(+), 19 deletions(-) diff --git a/app/classes/shared/helpers.py b/app/classes/shared/helpers.py index c5238ae8..01712fbb 100644 --- a/app/classes/shared/helpers.py +++ b/app/classes/shared/helpers.py @@ -960,22 +960,24 @@ class Helpers: file_list = sorted(dir_list, key=str.casefold) + sorted( unsorted_files, key=str.casefold ) + ignored_names = ["crafty_managed.txt", "db_stats"] for raw_filename in file_list: filename = html.escape(raw_filename) rel = os.path.join(folder, raw_filename) dpath = os.path.join(folder, filename) if os.path.isdir(rel): - output += f"""
  • - \n
    - - - - {filename} - -
  • - \n""" + if filename not in ignored_names: + output += f"""
  • + \n
    + + + + {filename} + +
  • + \n""" else: - if filename != "crafty_managed.txt": + if filename not in ignored_names: output += f"""
  • """ for raw_filename in file_list: filename = html.escape(raw_filename) dpath = os.path.join(folder, filename) rel = os.path.join(folder, raw_filename) if os.path.isdir(rel): - output += f"""
  • - \n
    - - - - {filename} - -
  • """ + if filename not in ignored_names: + output += f"""
  • + \n
    + + + + {filename} + +
  • """ else: - if filename != "crafty_managed.txt": + if filename not in ignored_names: output += f"""
  • Date: Mon, 9 Jan 2023 18:52:45 -0500 Subject: [PATCH 33/84] Make config editable from Crafty --- app/classes/web/panel_handler.py | 7 + app/frontend/templates/panel/config_json.html | 229 ++++++++++++++++++ .../templates/panel/panel_config.html | 12 + 3 files changed, 248 insertions(+) create mode 100644 app/frontend/templates/panel/config_json.html diff --git a/app/classes/web/panel_handler.py b/app/classes/web/panel_handler.py index 582517db..3e7699c8 100644 --- a/app/classes/web/panel_handler.py +++ b/app/classes/web/panel_handler.py @@ -897,6 +897,13 @@ class PanelHandler(BaseHandler): template = "panel/panel_config.html" + elif page == "config_json": + with open(self.helper.settings_file, "r", encoding="utf-8") as f: + data = json.load(f) + page_data["config-json"] = data + + template = "panel/config_json.html" + elif page == "add_user": page_data["new_user"] = True page_data["user"] = {} diff --git a/app/frontend/templates/panel/config_json.html b/app/frontend/templates/panel/config_json.html new file mode 100644 index 00000000..68f42b7b --- /dev/null +++ b/app/frontend/templates/panel/config_json.html @@ -0,0 +1,229 @@ +{% extends ../base.html %} + +{% block meta %} +{% end %} + +{% block title %}Crafty Controller - {{ translate('panelConfig', 'pageTitle', data['lang']) }}{% end %} + +{% block content %} + +
    + {% if data['superuser'] %} + + {% end %} + + +
    +
    + +
    + +
    + + +
    +
    +
    +
    +
    + {% for item in data['config-json'].items() %} + + {% if isinstance(item[1], bool) %} + + {% if item[1] == True %} +
    + +  
    + +  
    +
    + {% else %} +
    + +  
    + +  
    +
    + {% end %} + {% elif isinstance(item[1], int) %} + + {% else %} + + {% end %} + {% end %} +
    +
    +
    +
    +
    + + +
    + + + + +{% end %} + +{% block js %} + + + +{% end %} \ No newline at end of file diff --git a/app/frontend/templates/panel/panel_config.html b/app/frontend/templates/panel/panel_config.html index a4ee9f66..15f0a269 100644 --- a/app/frontend/templates/panel/panel_config.html +++ b/app/frontend/templates/panel/panel_config.html @@ -8,6 +8,18 @@ {% block content %}
    + {% if data['superuser'] %} + + {% end %}
    From 3c11f0120da11e436963f5458807c292db7f6d50 Mon Sep 17 00:00:00 2001 From: Silversthorn Date: Tue, 10 Jan 2023 00:53:47 +0100 Subject: [PATCH 34/84] Rework panel config for login page --- .../templates/panel/panel_config.html | 144 +++++++++++------- app/translations/en_EN.json | 2 + 2 files changed, 88 insertions(+), 58 deletions(-) diff --git a/app/frontend/templates/panel/panel_config.html b/app/frontend/templates/panel/panel_config.html index a4ee9f66..050ea9b4 100644 --- a/app/frontend/templates/panel/panel_config.html +++ b/app/frontend/templates/panel/panel_config.html @@ -34,8 +34,8 @@ }} {% if data['user_data']['hints'] %} + data-content="{{ translate('dashboard', 'cannotSeeOnMobile2', data['lang']) }}" , + data-placement="top"> {% end %}
    -
    +
    +
    +

    {{ translate('panelConfig', 'customLoginPage', data['lang']) }}

    +
    - -

    {{ translate('panelConfig', 'loginImage', data['lang']) }}

    -
    -

    - -

    - {% raw xsrf_form_html() %} - - -
    -
    - -
    -
    -
    - - - - -
    +
    +
    +

    {{ translate('panelConfig', 'loginImage', data['lang']) }}

    +
    + + {% raw xsrf_form_html() %} + +
    +
    +
    + +
    + +
    +
    +

    {{ translate('panelConfig', 'loginBackground', data['lang']) }}

    +
    + + +
    +
    +
    +
    +
    {{ translate('panelConfig', 'preview', data['lang']) }}:
    +
    +
    + +
    + +
    +
    + +
    + +
    + +
    +
    + Responsive image +
    + + +
    +
    -
    - -

    -
    -
    -
    -
    -
    -

    {{ translate('panelConfig', 'loginBackground', data['lang']) }}




    -
    - -
    -
    -
    {{ translate('panelConfig', 'preview', data['lang']) }}:
    - -
    -
    -
    - - -
    +
    @@ -404,10 +417,25 @@ }); }) + function updateBackgroundSelect() { + $("#photo").val($("#try_photo").val()).change(); + } + + function updateBackgroundPreview() { + var img = document.getElementById('bg-preview'); + if ($("#photo").val() == "login_1.jpg") { + var src_path = "../../static/assets/images/auth/".concat($("#photo").val()); + } + else { + var src_path = "../../static/assets/images/auth/custom/".concat($("#photo").val()); + } + img.src = src_path; + } + var file; function sendFile() { file = $("#file")[0].files[0] - document.getElementById("upload_input").innerHTML = '
     
    ' + document.getElementById("upload_input").innerHTML = '
     
    '; let xmlHttpRequest = new XMLHttpRequest(); let token = getCookie("_xsrf") let fileName = file.name diff --git a/app/translations/en_EN.json b/app/translations/en_EN.json index 49271004..df422c79 100644 --- a/app/translations/en_EN.json +++ b/app/translations/en_EN.json @@ -228,9 +228,11 @@ "superConfirmTitle": "Enable superuser? Are you sure?", "user": "User", "users": "Users", + "customLoginPage": "Customise the Login Page", "loginImage": "Upload a background image for the login screen.", "backgroundUpload": "Background Upload", "loginBackground": "Login Background Image", + "loginOpacity": "Select the Login Window Opacity", "select": "Select", "selectImage": "Select an image", "preview": "Preview" From 5d3dbc6f9c51cbf8704127c6ea878d6b8b2359b9 Mon Sep 17 00:00:00 2001 From: Andrew Date: Mon, 9 Jan 2023 19:01:05 -0500 Subject: [PATCH 35/84] Fix security --- app/classes/web/panel_handler.py | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/app/classes/web/panel_handler.py b/app/classes/web/panel_handler.py index 3e7699c8..90ba2aef 100644 --- a/app/classes/web/panel_handler.py +++ b/app/classes/web/panel_handler.py @@ -898,11 +898,12 @@ class PanelHandler(BaseHandler): template = "panel/panel_config.html" elif page == "config_json": - with open(self.helper.settings_file, "r", encoding="utf-8") as f: - data = json.load(f) - page_data["config-json"] = data + if exec_user["superuser"]: + with open(self.helper.settings_file, "r", encoding="utf-8") as f: + data = json.load(f) + page_data["config-json"] = data - template = "panel/config_json.html" + template = "panel/config_json.html" elif page == "add_user": page_data["new_user"] = True From bea48d9059d8a43fe01928c4871405c7e894de74 Mon Sep 17 00:00:00 2001 From: Andrew Date: Tue, 10 Jan 2023 14:12:33 -0500 Subject: [PATCH 36/84] Add better formatting for lists. --- app/classes/web/panel_handler.py | 21 +++++++++++++++++++ app/frontend/templates/panel/config_json.html | 21 ++++++++++++++----- 2 files changed, 37 insertions(+), 5 deletions(-) diff --git a/app/classes/web/panel_handler.py b/app/classes/web/panel_handler.py index 90ba2aef..38b9fd71 100644 --- a/app/classes/web/panel_handler.py +++ b/app/classes/web/panel_handler.py @@ -1720,6 +1720,27 @@ class PanelHandler(BaseHandler): self.tasks_manager.reload_schedule_from_db() self.redirect(f"/panel/server_detail?id={server_id}&subpage=backup") + elif page == "config_json": + try: + data = {} + with open(self.helper.settings_file, "r", encoding="utf-8") as f: + print("open") + keys = json.load(f).keys() + for key in keys: + print(self.get_argument(key)) + data[key] = self.get_argument(key) + print("data:", data) + """ + with open(self.helper.settings_file, "w", encoding="utf-8") as f: + json.dump(data, f, indent=4) +""" + except Exception as e: + logger.critical( + f"Config File Error: Unable to read {self.helper.settings_file} due to {e}" + ) + + self.redirect("/panel/config_json") + if page == "new_schedule": server_id = self.check_server_id() if not server_id: diff --git a/app/frontend/templates/panel/config_json.html b/app/frontend/templates/panel/config_json.html index 68f42b7b..c2afaa93 100644 --- a/app/frontend/templates/panel/config_json.html +++ b/app/frontend/templates/panel/config_json.html @@ -37,36 +37,47 @@
    -
    + + {% raw xsrf_form_html() %} {% for item in data['config-json'].items() %} +
    +
    - {% if isinstance(item[1], bool) %} + {% if isinstance(item[1], list) %} +
      + {% for li in item[1] %} +
      + {% end %} +
    + {% elif isinstance(item[1], bool) %} {% if item[1] == True %}
     
    -  
    +  
    {% else %}
     
    -  
    +  
    {% end %} {% elif isinstance(item[1], int) %} + step="1" min="0" required> {% else %} {% end %} {% end %} +
    From f9064eb15f19210df2733829cbd391f720caad98 Mon Sep 17 00:00:00 2001 From: amcmanu3 Date: Sat, 14 Jan 2023 22:22:37 -0500 Subject: [PATCH 37/84] Turn it into a list for a fresh start at this --- app/frontend/templates/panel/config_json.html | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) diff --git a/app/frontend/templates/panel/config_json.html b/app/frontend/templates/panel/config_json.html index c2afaa93..c5f3e5ad 100644 --- a/app/frontend/templates/panel/config_json.html +++ b/app/frontend/templates/panel/config_json.html @@ -46,10 +46,10 @@ {% if isinstance(item[1], list) %} -
      +
        {% for li in item[1] %} -
        +
      • {{li}}
      • +
        {% end %}
      {% elif isinstance(item[1], bool) %} @@ -107,6 +107,15 @@ {% block js %} + \ No newline at end of file diff --git a/app/migrations/20230111_adding_login_opacity.py b/app/migrations/20230111_adding_login_opacity.py new file mode 100644 index 00000000..536e352a --- /dev/null +++ b/app/migrations/20230111_adding_login_opacity.py @@ -0,0 +1,18 @@ +# Generated by database migrator +import peewee + + +def migrate(migrator, database, **kwargs): + migrator.add_columns( + "crafty_settings", login_opacity=peewee.IntegerField(default=100) + ) + """ + Write your migrations here. + """ + + +def rollback(migrator, database, **kwargs): + migrator.drop_columns("crafty_settings", ["login_opacity"]) + """ + Write your rollback migrations here. + """ diff --git a/app/translations/en_EN.json b/app/translations/en_EN.json index df422c79..296f1b16 100644 --- a/app/translations/en_EN.json +++ b/app/translations/en_EN.json @@ -234,6 +234,7 @@ "loginBackground": "Login Background Image", "loginOpacity": "Select the Login Window Opacity", "select": "Select", + "apply": "Apply", "selectImage": "Select an image", "preview": "Preview" }, From 9fc7a0523e9b4ee10373af4745b28a912b1e5c48 Mon Sep 17 00:00:00 2001 From: Silversthorn Date: Tue, 17 Jan 2023 21:48:17 +0100 Subject: [PATCH 47/84] Improve display of the login form on settings --- .../templates/panel/panel_config.html | 19 +++++++++++++------ 1 file changed, 13 insertions(+), 6 deletions(-) diff --git a/app/frontend/templates/panel/panel_config.html b/app/frontend/templates/panel/panel_config.html index 019c8009..255c6ed3 100644 --- a/app/frontend/templates/panel/panel_config.html +++ b/app/frontend/templates/panel/panel_config.html @@ -291,14 +291,22 @@
    -
    +
    Responsive image -
    +
  • \n
    @@ -977,7 +976,7 @@ class Helpers:
  • \n""" else: - if filename not in ignored_names: + if filename not in self.ignored_names: output += f"""
  • {filename}
  • """ return output - @staticmethod - def generate_dir(folder, output=""): + def generate_dir(self, folder, output=""): dir_list = [] unsorted_files = [] @@ -1000,14 +998,13 @@ class Helpers: file_list = sorted(dir_list, key=str.casefold) + sorted( unsorted_files, key=str.casefold ) - ignored_names = ["crafty_managed.txt", "db_stats"] output += f"""
      """ for raw_filename in file_list: filename = html.escape(raw_filename) dpath = os.path.join(folder, filename) rel = os.path.join(folder, raw_filename) if os.path.isdir(rel): - if filename not in ignored_names: + if filename not in self.ignored_names: output += f"""
    • \n
      @@ -1017,7 +1014,7 @@ class Helpers:
    • """ else: - if filename not in ignored_names: + if filename not in self.ignored_names: output += f"""
    • Date: Sun, 29 Jan 2023 19:27:10 +0000 Subject: [PATCH 84/84] Update changelog !532 --- CHANGELOG.md | 1 + 1 file changed, 1 insertion(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index cd7daf70..fb3da326 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,7 @@ ## --- [4.0.20] - 2022/TBD ### New features - Add option to run command before backup. ([Merge Request](https://gitlab.com/crafty-controller/crafty-4/-/merge_requests/536)) +- Make Config.json editable from panel. ([Merge Request](https://gitlab.com/crafty-controller/crafty-4/-/merge_requests/532)) ### Bug fixes - Fix local java server imports. ([Merge Request](https://gitlab.com/crafty-controller/crafty-4/-/merge_requests/529)) - Fix Schedule Restore | Add Backup Config Preservation. ([Merge Request](https://gitlab.com/crafty-controller/crafty-4/-/merge_requests/533))