mirror of
				https://github.com/pelican-eggs/eggs.git
				synced 2025-10-31 08:58:06 +00:00 
			
		
		
		
	Do it this way
This commit is contained in:
		
							parent
							
								
									0f8574c343
								
							
						
					
					
						commit
						534a25fce5
					
				| @ -4,7 +4,7 @@ | ||||
|         "version": "PTDL_v2", | ||||
|         "update_url": null | ||||
|     }, | ||||
|     "exported_at": "2022-09-30T18:42:39+02:00", | ||||
|     "exported_at": "2022-09-30T19:32:46+02:00", | ||||
|     "name": "Veloren", | ||||
|     "author": "parker@parkervcp.com", | ||||
|     "description": "Veloren is a multiplayer voxel RPG written in Rust. It is inspired by games such as Cube World, Legend of Zelda: Breath of the Wild, Dwarf Fortress and Minecraft.", | ||||
| @ -22,7 +22,7 @@ | ||||
|     }, | ||||
|     "scripts": { | ||||
|         "installation": { | ||||
|             "script": "#!\/bin\/bash\r\n\r\napt update\r\napt install -y curl wget unzip git jq\r\n\r\nmkdir -p \/mnt\/server\r\ncd \/mnt\/server\r\n\r\nLATEST_JSON=$(curl --silent \"https:\/\/api.github.com\/repos\/veloren\/veloren\/releases\/latest\")\r\nRELEASES=$(curl --silent \"https:\/\/api.github.com\/repos\/${GITHUB_PACKAGE}\/releases\")\r\nARCH=$([[ \"$(uname -m)\" == \"x86_64\" ]] && echo \"-linux-x86_64-\" || echo \"-linux-aarch64-\")\r\nMARCH_AND_SPACES=$(echo ${VERSION} && echo ${ARCH} && echo ${RELEASE_DATE})\r\nMATCH=$(echo ${MARCH_AND_SPACES} | sed 's\/ \/\/g')\r\n\r\necho ${MATCH}\r\n\r\nif [ -z \"${VERSION}\" ] || [ \"${VERSION}\" == \"weekly\" ]; then\r\n    DOWNLOAD_URL=$(echo ${LATEST_JSON} | jq .assets | jq -r .[].browser_download_url | grep -i ${MATCH})\r\nelse\r\n    VERSION_CHECK=$(echo ${RELEASES} | jq -r --arg VERSION \"${VERSION}\" '.[] | select(.tag_name==$VERSION) | .tag_name')\r\n    if [ \"${VERSION}\" == \"${VERSION_CHECK}\" ]; then\r\n        DOWNLOAD_URL=$(echo ${RELEASES} | jq -r --arg VERSION \"${VERSION}\" '.[] | select(.tag_name==$VERSION) | .assets[].browser_download_url' | grep -i ${MATCH})\r\n    else\r\n        echo -e \"invalid ${RELEASE_DATE}\"\r\n    fi\r\nfi\r\n\r\nwget ${DOWNLOAD_URL} -O files.zip\r\n\r\nunzip -o files.zip\r\nrm files.zip\r\n\r\nchmod +x veloren-server-cli\r\n\r\n## generate config because there is no better way to get it.\r\nmkdir -p \/mnt\/server\/userdata\/server\/server_config\/\r\nif [ ! -f \/mnt\/server\/userdata\/server\/server_config\/settings.ron ]; then\r\n    cp \/mnt\/server\/userdata\/server\/server_config\/settings.template.ron \/mnt\/server\/userdata\/server\/server_config\/settings.ron\r\n    echo \"config file pulled\"\r\nfi\r\n\r\necho -e \"install complete\"", | ||||
|             "script": "#!\/bin\/bash\r\n\r\napt update\r\napt install -y curl wget unzip git jq\r\n\r\nmkdir -p \/mnt\/server\r\ncd \/mnt\/server\r\n\r\nLATEST_JSON=$(curl --silent \"https:\/\/api.github.com\/repos\/veloren\/veloren\/releases\/latest\")\r\nRELEASES=$(curl --silent \"https:\/\/api.github.com\/repos\/veloren\/veloren\/releases\")\r\nARCH=$([[ \"$(uname -m)\" == \"x86_64\" ]] && echo \"linux-x86_64\" || echo \"linux-aarch64\")\r\nPART=$([[ \"$(uname -m)\" == \"x86_64\" ]] && echo \"-linux-x86_64-\" || echo \"-linux-aarch64-\")\r\nMATCH_AND_SPACES=$(echo \"weekly\" && echo ${PART} && echo ${RELEASE_DATE})\r\nMATCH=$(echo ${MATCH_AND_SPACES} | sed 's\/ \/\/g')\r\n\r\n\r\nif [ -z \"${VERSION}\" ] || [ \"${VERSION}\" == \"weekly\" ]; then\r\n    echo -e \"weekly\"\r\n    DOWNLOAD_URL=$(echo ${LATEST_JSON} | jq .assets | jq -r .[].browser_download_url | grep -i \"${ARCH}\" | tail -n 1)\r\nelif [ \"${VERSION}\" == \"nightly\" ]; then\r\n    echo -e \"nightly\"\r\n    DOWNLOAD_URL=$(echo ${RELEASES} | jq -r --arg VERSION \"nightly\" '.[] | select(.tag_name==\"nightly\") | .assets[].browser_download_url' | grep -i \"${ARCH}\" | tail -n 1)\r\nelif [ \"${VERSION}\" == \"dated_weekly\" ]; then\r\n    echo -e ${MATCH} \r\n    DOWNLOAD_URL=$(echo ${LATEST_JSON} | jq .assets | jq -r .[].browser_download_url | grep -i \"${MATCH}\")\r\nelse\r\n    echo -e  \"something went wrong\"\r\nfi\r\n\r\necho -e \"download url: ${DOWNLOAD_URL}\"\r\nwget ${DOWNLOAD_URL} -O files.zip\r\n\r\nunzip -o files.zip\r\nrm files.zip\r\n\r\nchmod +x veloren-server-cli\r\n\r\n## generate config because there is no better way to get it.\r\nmkdir -p \/mnt\/server\/userdata\/server\/server_config\/\r\nif [ ! -f \/mnt\/server\/userdata\/server\/server_config\/settings.ron ]; then\r\n    wget https:\/\/raw.githubusercontent.com\/parkervcp\/eggs\/master\/game_eggs\/veloren\/settings.ron \/mnt\/server\/userdata\/server\/server_config\/settings.ron\r\n    echo \"config file pulled\"\r\nfi\r\n\r\necho -e \"install complete\"", | ||||
|             "container": "debian:bullseye-slim", | ||||
|             "entrypoint": "bash" | ||||
|         } | ||||
| @ -30,22 +30,22 @@ | ||||
|     "variables": [ | ||||
|         { | ||||
|             "name": "Version", | ||||
|             "description": "The version you want weekly or nightly", | ||||
|             "description": "weekly = download the latest weekly build,\r\nnightly = download the latestes nightly build,\r\ndated_weekly = download specific weekly build for that set the Weekly specific build date.", | ||||
|             "env_variable": "VERSION", | ||||
|             "default_value": "weekly", | ||||
|             "user_viewable": false, | ||||
|             "user_editable": false, | ||||
|             "rules": "required|string|in:weekly,nightly", | ||||
|             "user_viewable": true, | ||||
|             "user_editable": true, | ||||
|             "rules": "required|string|in:weekly,nightly,dated_weekly", | ||||
|             "field_type": "text" | ||||
|         }, | ||||
|         { | ||||
|             "name": "Release date", | ||||
|             "description": "The date of the version you want look here:\r\nhttps:\/\/github.com\/veloren\/veloren\/releases\r\n\r\neverything after the x86_64 but not the first -\r\nand not the .zip extention\r\n\r\nexample:\r\n2022-08-31T08_26", | ||||
|             "name": "Weekly specific build date", | ||||
|             "description": "The date of the weekly version you want. \r\nOnly used if Version is set to dated_weekly!\r\nhttps:\/\/github.com\/veloren\/veloren\/releases\r\n\r\nEverything after the x86_64 but not the first -\r\nand not the .zip extention\r\n\r\nexample:\r\n2022-08-31T08_26 or 2022-09-26T13_34", | ||||
|             "env_variable": "RELEASE_DATE", | ||||
|             "default_value": "2022-09-26T13_34", | ||||
|             "user_viewable": true, | ||||
|             "user_editable": true, | ||||
|             "rules": "required|string|max:40", | ||||
|             "rules": "nullable|string|max:40", | ||||
|             "field_type": "text" | ||||
|         }, | ||||
|         { | ||||
|  | ||||
							
								
								
									
										36
									
								
								game_eggs/veloren/settings.ron
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										36
									
								
								game_eggs/veloren/settings.ron
									
									
									
									
									
										Normal file
									
								
							| @ -0,0 +1,36 @@ | ||||
| ( | ||||
|     gameserver_protocols: [ | ||||
|         Tcp( | ||||
|             address: "[::]:14004", | ||||
|         ), | ||||
|         Tcp( | ||||
|             address: "0.0.0.0:14004", | ||||
|         ), | ||||
|     ], | ||||
|     metrics_address: "127.0.0.1:14005", | ||||
|     auth_server_address: Some("https://auth.veloren.net"), | ||||
|     max_players: 100, | ||||
|     world_seed: 230, | ||||
|     server_name: "Veloren Server", | ||||
|     start_time: 32400.0, | ||||
|     map_file: None, | ||||
|     max_view_distance: Some(65), | ||||
|     max_player_group_size: 6, | ||||
|     client_timeout: ( | ||||
|         secs: 40, | ||||
|         nanos: 0, | ||||
|     ), | ||||
|     spawn_town: None, | ||||
|     max_player_for_kill_broadcast: None, | ||||
|     calendar_mode: Auto, | ||||
|     gameplay: ( | ||||
|         battle_mode: Global(PvP), | ||||
|         safe_spawn: false, | ||||
|         explosion_burn_marks: true, | ||||
|     ), | ||||
|     moderation: ( | ||||
|         banned_words_files: [], | ||||
|         automod: false, | ||||
|         admins_exempt: true, | ||||
|     ), | ||||
| ) | ||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user