From 71d17ccd00eb4ab7125a7b98b3750118efb4be84 Mon Sep 17 00:00:00 2001 From: tmunsch Date: Fri, 27 Nov 2020 20:02:38 -0500 Subject: [PATCH 01/16] Create minio.sh --- storage/minio.sh | 63 ++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 63 insertions(+) create mode 100644 storage/minio.sh diff --git a/storage/minio.sh b/storage/minio.sh new file mode 100644 index 00000000..889c4f02 --- /dev/null +++ b/storage/minio.sh @@ -0,0 +1,63 @@ +#!/bin/bash +################################## +echo Starting up.... +echo "Startup Type: (normal/rotate)" +echo Detected $STARTUP_TYPE +if [ -f "key.txt" ]; then +echo "Key file detected..." +export MINIO_ACCESS_KEY=`cat key.txt` +else +echo minioadmin > key.txt +echo "No key file detected...Preparing First Time Boot" +fi +if [ -f "secret.txt" ]; then +echo "Secret file detected..." +export MINIO_SECRET_KEY=`cat secret.txt` +else +echo minioadmin > secret.txt +echo "No secret file detected...Preparing First Time Boot" +fi +if [ -f "oldsecret.txt" ]; then +echo "Old secret file detected..." +export MINIO_SECRET_KEY_OLD=`cat oldsecret.txt` +else +echo ".." +fi +if [ -f "oldkey.txt" ]; then +echo "Old key file detected..." +export MINIO_ACCESS_KEY_OLD=`cat oldkey.txt` +else +echo "......" +fi +if [ -f "justrotated.txt" ]; then +echo "Previous key rotation detected...." +echo "Clearing the Lanes...." +unset MINIO_ACCESS_KEY_OLD +unset MINIO_SECRET_KEY_OLD +STARTUP_TYPE=normal +rm justrotated.txt +rm oldsecret.txt +rm oldkey.txt +else +echo "......" +fi +########################################## +if [ -z "$STARTUP_TYPE" ] || [ "$STARTUP_TYPE" == "rotate" ]; then +touch justrotated.txt +export MINIO_ACCESS_KEY_OLD=$MINIO_ACCESS_KEY +echo $MINIO_ACCESS_KEY_OLD > oldkey.txt +export MINIO_SECRET_KEY_OLD=$MINIO_SECRET_KEY +echo $MINIO_SECRET_KEY_OLD > oldsecret.txt +export MINIO_ACCESS_KEY=$(cat /dev/urandom | tr -dc 'a-zA-Z0-9' | fold -w 32 | head -n 1) +echo $MINIO_ACCESS_KEY > key.txt +export MINIO_SECRET_KEY=$(cat /dev/urandom | tr -dc 'a-zA-Z0-9' | fold -w 32 | head -n 1) +echo $MINIO_SECRET_KEY > secret.txt +echo Your New Access Key is: $MINIO_ACCESS_KEY +echo Your New Secret Key is: $MINIO_SECRET_KEY +echo Your Old Access Key is: $MINIO_ACCESS_KEY_OLD +echo Your Old Access Key is: $MINIO_SECRET_KEY_OLD +echo Booting... +./minio server data --address 0.0.0.0:$SERVER_PORT +else +./minio server data --address 0.0.0.0:$SERVER_PORT +fi From ee4c054d27cc4f465a4e22b0ba865ea918b69ece Mon Sep 17 00:00:00 2001 From: tmunsch Date: Fri, 27 Nov 2020 20:33:10 -0500 Subject: [PATCH 02/16] Cleaned up Key file locations Moved all keys to keys folder --- storage/minio.sh | 38 +++++++++++++++++++------------------- 1 file changed, 19 insertions(+), 19 deletions(-) diff --git a/storage/minio.sh b/storage/minio.sh index 889c4f02..97441d05 100644 --- a/storage/minio.sh +++ b/storage/minio.sh @@ -3,55 +3,55 @@ echo Starting up.... echo "Startup Type: (normal/rotate)" echo Detected $STARTUP_TYPE -if [ -f "key.txt" ]; then +if [ -f "keys/key.txt" ]; then echo "Key file detected..." -export MINIO_ACCESS_KEY=`cat key.txt` +export MINIO_ACCESS_KEY=`cat keys/key.txt` else -echo minioadmin > key.txt +echo minioadmin > keys/key.txt echo "No key file detected...Preparing First Time Boot" fi -if [ -f "secret.txt" ]; then +if [ -f "keys/secret.txt" ]; then echo "Secret file detected..." -export MINIO_SECRET_KEY=`cat secret.txt` +export MINIO_SECRET_KEY=`cat keys/secret.txt` else -echo minioadmin > secret.txt +echo minioadmin > keys/secret.txt echo "No secret file detected...Preparing First Time Boot" fi -if [ -f "oldsecret.txt" ]; then +if [ -f "keys/oldsecret.txt" ]; then echo "Old secret file detected..." -export MINIO_SECRET_KEY_OLD=`cat oldsecret.txt` +export MINIO_SECRET_KEY_OLD=`cat keys/oldsecret.txt` else echo ".." fi -if [ -f "oldkey.txt" ]; then +if [ -f "keys/oldkey.txt" ]; then echo "Old key file detected..." -export MINIO_ACCESS_KEY_OLD=`cat oldkey.txt` +export MINIO_ACCESS_KEY_OLD=`cat keys/oldkey.txt` else echo "......" fi -if [ -f "justrotated.txt" ]; then +if [ -f "keys/justrotated.txt" ]; then echo "Previous key rotation detected...." echo "Clearing the Lanes...." unset MINIO_ACCESS_KEY_OLD unset MINIO_SECRET_KEY_OLD STARTUP_TYPE=normal -rm justrotated.txt -rm oldsecret.txt -rm oldkey.txt +rm keys/justrotated.txt +rm keys/oldsecret.txt +rm keys/oldkey.txt else echo "......" fi ########################################## if [ -z "$STARTUP_TYPE" ] || [ "$STARTUP_TYPE" == "rotate" ]; then -touch justrotated.txt +touch keys/justrotated.txt export MINIO_ACCESS_KEY_OLD=$MINIO_ACCESS_KEY -echo $MINIO_ACCESS_KEY_OLD > oldkey.txt +echo $MINIO_ACCESS_KEY_OLD > keys/oldkey.txt export MINIO_SECRET_KEY_OLD=$MINIO_SECRET_KEY -echo $MINIO_SECRET_KEY_OLD > oldsecret.txt +echo $MINIO_SECRET_KEY_OLD > keys/oldsecret.txt export MINIO_ACCESS_KEY=$(cat /dev/urandom | tr -dc 'a-zA-Z0-9' | fold -w 32 | head -n 1) -echo $MINIO_ACCESS_KEY > key.txt +echo $MINIO_ACCESS_KEY > keys/key.txt export MINIO_SECRET_KEY=$(cat /dev/urandom | tr -dc 'a-zA-Z0-9' | fold -w 32 | head -n 1) -echo $MINIO_SECRET_KEY > secret.txt +echo $MINIO_SECRET_KEY > keys/secret.txt echo Your New Access Key is: $MINIO_ACCESS_KEY echo Your New Secret Key is: $MINIO_SECRET_KEY echo Your Old Access Key is: $MINIO_ACCESS_KEY_OLD From b42ff750d25306d2102803f1f9e5dbdc35b84933 Mon Sep 17 00:00:00 2001 From: tmunsch Date: Fri, 27 Nov 2020 20:46:17 -0500 Subject: [PATCH 03/16] Cleaned up startup --- storage/minio.sh | 6 ------ 1 file changed, 6 deletions(-) diff --git a/storage/minio.sh b/storage/minio.sh index 97441d05..ba131cb9 100644 --- a/storage/minio.sh +++ b/storage/minio.sh @@ -20,14 +20,10 @@ fi if [ -f "keys/oldsecret.txt" ]; then echo "Old secret file detected..." export MINIO_SECRET_KEY_OLD=`cat keys/oldsecret.txt` -else -echo ".." fi if [ -f "keys/oldkey.txt" ]; then echo "Old key file detected..." export MINIO_ACCESS_KEY_OLD=`cat keys/oldkey.txt` -else -echo "......" fi if [ -f "keys/justrotated.txt" ]; then echo "Previous key rotation detected...." @@ -38,8 +34,6 @@ STARTUP_TYPE=normal rm keys/justrotated.txt rm keys/oldsecret.txt rm keys/oldkey.txt -else -echo "......" fi ########################################## if [ -z "$STARTUP_TYPE" ] || [ "$STARTUP_TYPE" == "rotate" ]; then From af8982f6c6213b88abd9a214d0e9add2ed498777 Mon Sep 17 00:00:00 2001 From: tmunsch Date: Fri, 27 Nov 2020 20:49:45 -0500 Subject: [PATCH 04/16] Cleaning up still --- storage/minio.sh | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/storage/minio.sh b/storage/minio.sh index ba131cb9..48b5818e 100644 --- a/storage/minio.sh +++ b/storage/minio.sh @@ -1,8 +1,7 @@ #!/bin/bash ################################## echo Starting up.... -echo "Startup Type: (normal/rotate)" -echo Detected $STARTUP_TYPE +echo "Startup Type: $STARTUP_TYPE" if [ -f "keys/key.txt" ]; then echo "Key file detected..." export MINIO_ACCESS_KEY=`cat keys/key.txt` From b3275943ca5496f4bd0a16c75222192ac4367a12 Mon Sep 17 00:00:00 2001 From: tmunsch Date: Fri, 27 Nov 2020 21:30:39 -0500 Subject: [PATCH 05/16] Added Egg file --- storage/egg-minio-s3.json | 37 +++++++++++++++++++++++++++++++++++++ 1 file changed, 37 insertions(+) create mode 100644 storage/egg-minio-s3.json diff --git a/storage/egg-minio-s3.json b/storage/egg-minio-s3.json new file mode 100644 index 00000000..e7ce05de --- /dev/null +++ b/storage/egg-minio-s3.json @@ -0,0 +1,37 @@ +{ + "_comment": "DO NOT EDIT: FILE GENERATED AUTOMATICALLY BY PTERODACTYL PANEL - PTERODACTYL.IO", + "meta": { + "version": "PTDL_v1" + }, + "exported_at": "2020-11-27T21:24:29-05:00", + "name": "Minio S3", + "author": "accounts@bofanodes.io", + "description": "MinIO is a cloud storage server compatible with Amazon S3, released under Apache License v2. As an object store, MinIO can store unstructured data such as photos, videos, log files, backups and container images. The maximum size of an object is 5TB.", + "features": null, + "image": "quay.io\/parkervcp\/pterodactyl-images:ubuntu", + "startup": ".\/minio.sh", + "config": { + "files": "{}", + "startup": "{\r\n \"done\": \"guide\"\r\n}", + "logs": "{\r\n \"custom\": false,\r\n \"location\": \"logs\/latest.log\"\r\n}", + "stop": "^C" + }, + "scripts": { + "installation": { + "script": "#\r\n#\r\napt update\r\napt install -y wget\r\ncd \/mnt\/server\r\nwget https:\/\/dl.min.io\/server\/minio\/release\/linux-amd64\/minio\r\nchmod +x minio\r\nmkdir data\r\nmkdir keys\r\nwget https:\/\/github.com\/tmunsch\/eggs\/raw\/minio\/storage\/minio.sh\r\nchmod +x minio.sh\r\nexport MINIO_ACCESS_KEY=$(cat \/dev\/urandom | tr -dc 'a-zA-Z0-9' | fold -w 32 | head -n 1)\r\necho $MINIO_ACCESS_KEY > keys\/key.txt\r\nexport MINIO_SECRET_KEY=$(cat \/dev\/urandom | tr -dc 'a-zA-Z0-9' | fold -w 32 | head -n 1)\r\necho $MINIO_SECRET_KEY > keys\/secret.txt\r\necho done", + "container": "debian:buster-slim", + "entrypoint": "bash" + } + }, + "variables": [ + { + "name": "Startup Type", + "description": "normal or rotate", + "env_variable": "STARTUP_TYPE", + "default_value": "normal", + "user_viewable": true, + "user_editable": true, + "rules": "required|string|in:normal,rotate" + } + ] +} \ No newline at end of file From 1fde6e08ea76f9ec5ec8fe653d6d4df71702363b Mon Sep 17 00:00:00 2001 From: tmunsch Date: Fri, 27 Nov 2020 21:32:54 -0500 Subject: [PATCH 06/16] Create minio.sh --- storage/minio/minio.sh | 56 ++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 56 insertions(+) create mode 100644 storage/minio/minio.sh diff --git a/storage/minio/minio.sh b/storage/minio/minio.sh new file mode 100644 index 00000000..48b5818e --- /dev/null +++ b/storage/minio/minio.sh @@ -0,0 +1,56 @@ +#!/bin/bash +################################## +echo Starting up.... +echo "Startup Type: $STARTUP_TYPE" +if [ -f "keys/key.txt" ]; then +echo "Key file detected..." +export MINIO_ACCESS_KEY=`cat keys/key.txt` +else +echo minioadmin > keys/key.txt +echo "No key file detected...Preparing First Time Boot" +fi +if [ -f "keys/secret.txt" ]; then +echo "Secret file detected..." +export MINIO_SECRET_KEY=`cat keys/secret.txt` +else +echo minioadmin > keys/secret.txt +echo "No secret file detected...Preparing First Time Boot" +fi +if [ -f "keys/oldsecret.txt" ]; then +echo "Old secret file detected..." +export MINIO_SECRET_KEY_OLD=`cat keys/oldsecret.txt` +fi +if [ -f "keys/oldkey.txt" ]; then +echo "Old key file detected..." +export MINIO_ACCESS_KEY_OLD=`cat keys/oldkey.txt` +fi +if [ -f "keys/justrotated.txt" ]; then +echo "Previous key rotation detected...." +echo "Clearing the Lanes...." +unset MINIO_ACCESS_KEY_OLD +unset MINIO_SECRET_KEY_OLD +STARTUP_TYPE=normal +rm keys/justrotated.txt +rm keys/oldsecret.txt +rm keys/oldkey.txt +fi +########################################## +if [ -z "$STARTUP_TYPE" ] || [ "$STARTUP_TYPE" == "rotate" ]; then +touch keys/justrotated.txt +export MINIO_ACCESS_KEY_OLD=$MINIO_ACCESS_KEY +echo $MINIO_ACCESS_KEY_OLD > keys/oldkey.txt +export MINIO_SECRET_KEY_OLD=$MINIO_SECRET_KEY +echo $MINIO_SECRET_KEY_OLD > keys/oldsecret.txt +export MINIO_ACCESS_KEY=$(cat /dev/urandom | tr -dc 'a-zA-Z0-9' | fold -w 32 | head -n 1) +echo $MINIO_ACCESS_KEY > keys/key.txt +export MINIO_SECRET_KEY=$(cat /dev/urandom | tr -dc 'a-zA-Z0-9' | fold -w 32 | head -n 1) +echo $MINIO_SECRET_KEY > keys/secret.txt +echo Your New Access Key is: $MINIO_ACCESS_KEY +echo Your New Secret Key is: $MINIO_SECRET_KEY +echo Your Old Access Key is: $MINIO_ACCESS_KEY_OLD +echo Your Old Access Key is: $MINIO_SECRET_KEY_OLD +echo Booting... +./minio server data --address 0.0.0.0:$SERVER_PORT +else +./minio server data --address 0.0.0.0:$SERVER_PORT +fi From 55dc57901dd3c02516e1be97c71ba193706913ca Mon Sep 17 00:00:00 2001 From: tmunsch Date: Fri, 27 Nov 2020 21:33:35 -0500 Subject: [PATCH 07/16] Add files via upload --- storage/minio/egg-minio-s3.json | 37 +++++++++++++++++++++++++++++++++ 1 file changed, 37 insertions(+) create mode 100644 storage/minio/egg-minio-s3.json diff --git a/storage/minio/egg-minio-s3.json b/storage/minio/egg-minio-s3.json new file mode 100644 index 00000000..e7ce05de --- /dev/null +++ b/storage/minio/egg-minio-s3.json @@ -0,0 +1,37 @@ +{ + "_comment": "DO NOT EDIT: FILE GENERATED AUTOMATICALLY BY PTERODACTYL PANEL - PTERODACTYL.IO", + "meta": { + "version": "PTDL_v1" + }, + "exported_at": "2020-11-27T21:24:29-05:00", + "name": "Minio S3", + "author": "accounts@bofanodes.io", + "description": "MinIO is a cloud storage server compatible with Amazon S3, released under Apache License v2. As an object store, MinIO can store unstructured data such as photos, videos, log files, backups and container images. The maximum size of an object is 5TB.", + "features": null, + "image": "quay.io\/parkervcp\/pterodactyl-images:ubuntu", + "startup": ".\/minio.sh", + "config": { + "files": "{}", + "startup": "{\r\n \"done\": \"guide\"\r\n}", + "logs": "{\r\n \"custom\": false,\r\n \"location\": \"logs\/latest.log\"\r\n}", + "stop": "^C" + }, + "scripts": { + "installation": { + "script": "#\r\n#\r\napt update\r\napt install -y wget\r\ncd \/mnt\/server\r\nwget https:\/\/dl.min.io\/server\/minio\/release\/linux-amd64\/minio\r\nchmod +x minio\r\nmkdir data\r\nmkdir keys\r\nwget https:\/\/github.com\/tmunsch\/eggs\/raw\/minio\/storage\/minio.sh\r\nchmod +x minio.sh\r\nexport MINIO_ACCESS_KEY=$(cat \/dev\/urandom | tr -dc 'a-zA-Z0-9' | fold -w 32 | head -n 1)\r\necho $MINIO_ACCESS_KEY > keys\/key.txt\r\nexport MINIO_SECRET_KEY=$(cat \/dev\/urandom | tr -dc 'a-zA-Z0-9' | fold -w 32 | head -n 1)\r\necho $MINIO_SECRET_KEY > keys\/secret.txt\r\necho done", + "container": "debian:buster-slim", + "entrypoint": "bash" + } + }, + "variables": [ + { + "name": "Startup Type", + "description": "normal or rotate", + "env_variable": "STARTUP_TYPE", + "default_value": "normal", + "user_viewable": true, + "user_editable": true, + "rules": "required|string|in:normal,rotate" + } + ] +} \ No newline at end of file From 199e482a380e69d673b967a910dfcc93221908a3 Mon Sep 17 00:00:00 2001 From: tmunsch Date: Fri, 27 Nov 2020 21:34:55 -0500 Subject: [PATCH 08/16] Delete egg-minio-s3.json --- storage/egg-minio-s3.json | 37 ------------------------------------- 1 file changed, 37 deletions(-) delete mode 100644 storage/egg-minio-s3.json diff --git a/storage/egg-minio-s3.json b/storage/egg-minio-s3.json deleted file mode 100644 index e7ce05de..00000000 --- a/storage/egg-minio-s3.json +++ /dev/null @@ -1,37 +0,0 @@ -{ - "_comment": "DO NOT EDIT: FILE GENERATED AUTOMATICALLY BY PTERODACTYL PANEL - PTERODACTYL.IO", - "meta": { - "version": "PTDL_v1" - }, - "exported_at": "2020-11-27T21:24:29-05:00", - "name": "Minio S3", - "author": "accounts@bofanodes.io", - "description": "MinIO is a cloud storage server compatible with Amazon S3, released under Apache License v2. As an object store, MinIO can store unstructured data such as photos, videos, log files, backups and container images. The maximum size of an object is 5TB.", - "features": null, - "image": "quay.io\/parkervcp\/pterodactyl-images:ubuntu", - "startup": ".\/minio.sh", - "config": { - "files": "{}", - "startup": "{\r\n \"done\": \"guide\"\r\n}", - "logs": "{\r\n \"custom\": false,\r\n \"location\": \"logs\/latest.log\"\r\n}", - "stop": "^C" - }, - "scripts": { - "installation": { - "script": "#\r\n#\r\napt update\r\napt install -y wget\r\ncd \/mnt\/server\r\nwget https:\/\/dl.min.io\/server\/minio\/release\/linux-amd64\/minio\r\nchmod +x minio\r\nmkdir data\r\nmkdir keys\r\nwget https:\/\/github.com\/tmunsch\/eggs\/raw\/minio\/storage\/minio.sh\r\nchmod +x minio.sh\r\nexport MINIO_ACCESS_KEY=$(cat \/dev\/urandom | tr -dc 'a-zA-Z0-9' | fold -w 32 | head -n 1)\r\necho $MINIO_ACCESS_KEY > keys\/key.txt\r\nexport MINIO_SECRET_KEY=$(cat \/dev\/urandom | tr -dc 'a-zA-Z0-9' | fold -w 32 | head -n 1)\r\necho $MINIO_SECRET_KEY > keys\/secret.txt\r\necho done", - "container": "debian:buster-slim", - "entrypoint": "bash" - } - }, - "variables": [ - { - "name": "Startup Type", - "description": "normal or rotate", - "env_variable": "STARTUP_TYPE", - "default_value": "normal", - "user_viewable": true, - "user_editable": true, - "rules": "required|string|in:normal,rotate" - } - ] -} \ No newline at end of file From 476c67e25dd193d93cd3e4e032e196091eb1dd17 Mon Sep 17 00:00:00 2001 From: tmunsch Date: Fri, 27 Nov 2020 21:35:03 -0500 Subject: [PATCH 09/16] Delete minio.sh --- storage/minio.sh | 56 ------------------------------------------------ 1 file changed, 56 deletions(-) delete mode 100644 storage/minio.sh diff --git a/storage/minio.sh b/storage/minio.sh deleted file mode 100644 index 48b5818e..00000000 --- a/storage/minio.sh +++ /dev/null @@ -1,56 +0,0 @@ -#!/bin/bash -################################## -echo Starting up.... -echo "Startup Type: $STARTUP_TYPE" -if [ -f "keys/key.txt" ]; then -echo "Key file detected..." -export MINIO_ACCESS_KEY=`cat keys/key.txt` -else -echo minioadmin > keys/key.txt -echo "No key file detected...Preparing First Time Boot" -fi -if [ -f "keys/secret.txt" ]; then -echo "Secret file detected..." -export MINIO_SECRET_KEY=`cat keys/secret.txt` -else -echo minioadmin > keys/secret.txt -echo "No secret file detected...Preparing First Time Boot" -fi -if [ -f "keys/oldsecret.txt" ]; then -echo "Old secret file detected..." -export MINIO_SECRET_KEY_OLD=`cat keys/oldsecret.txt` -fi -if [ -f "keys/oldkey.txt" ]; then -echo "Old key file detected..." -export MINIO_ACCESS_KEY_OLD=`cat keys/oldkey.txt` -fi -if [ -f "keys/justrotated.txt" ]; then -echo "Previous key rotation detected...." -echo "Clearing the Lanes...." -unset MINIO_ACCESS_KEY_OLD -unset MINIO_SECRET_KEY_OLD -STARTUP_TYPE=normal -rm keys/justrotated.txt -rm keys/oldsecret.txt -rm keys/oldkey.txt -fi -########################################## -if [ -z "$STARTUP_TYPE" ] || [ "$STARTUP_TYPE" == "rotate" ]; then -touch keys/justrotated.txt -export MINIO_ACCESS_KEY_OLD=$MINIO_ACCESS_KEY -echo $MINIO_ACCESS_KEY_OLD > keys/oldkey.txt -export MINIO_SECRET_KEY_OLD=$MINIO_SECRET_KEY -echo $MINIO_SECRET_KEY_OLD > keys/oldsecret.txt -export MINIO_ACCESS_KEY=$(cat /dev/urandom | tr -dc 'a-zA-Z0-9' | fold -w 32 | head -n 1) -echo $MINIO_ACCESS_KEY > keys/key.txt -export MINIO_SECRET_KEY=$(cat /dev/urandom | tr -dc 'a-zA-Z0-9' | fold -w 32 | head -n 1) -echo $MINIO_SECRET_KEY > keys/secret.txt -echo Your New Access Key is: $MINIO_ACCESS_KEY -echo Your New Secret Key is: $MINIO_SECRET_KEY -echo Your Old Access Key is: $MINIO_ACCESS_KEY_OLD -echo Your Old Access Key is: $MINIO_SECRET_KEY_OLD -echo Booting... -./minio server data --address 0.0.0.0:$SERVER_PORT -else -./minio server data --address 0.0.0.0:$SERVER_PORT -fi From 971cd784642aacb3232fb946965ef28395cdd80f Mon Sep 17 00:00:00 2001 From: tmunsch Date: Fri, 27 Nov 2020 21:39:18 -0500 Subject: [PATCH 10/16] Delete egg-minio-s3.json --- storage/minio/egg-minio-s3.json | 37 --------------------------------- 1 file changed, 37 deletions(-) delete mode 100644 storage/minio/egg-minio-s3.json diff --git a/storage/minio/egg-minio-s3.json b/storage/minio/egg-minio-s3.json deleted file mode 100644 index e7ce05de..00000000 --- a/storage/minio/egg-minio-s3.json +++ /dev/null @@ -1,37 +0,0 @@ -{ - "_comment": "DO NOT EDIT: FILE GENERATED AUTOMATICALLY BY PTERODACTYL PANEL - PTERODACTYL.IO", - "meta": { - "version": "PTDL_v1" - }, - "exported_at": "2020-11-27T21:24:29-05:00", - "name": "Minio S3", - "author": "accounts@bofanodes.io", - "description": "MinIO is a cloud storage server compatible with Amazon S3, released under Apache License v2. As an object store, MinIO can store unstructured data such as photos, videos, log files, backups and container images. The maximum size of an object is 5TB.", - "features": null, - "image": "quay.io\/parkervcp\/pterodactyl-images:ubuntu", - "startup": ".\/minio.sh", - "config": { - "files": "{}", - "startup": "{\r\n \"done\": \"guide\"\r\n}", - "logs": "{\r\n \"custom\": false,\r\n \"location\": \"logs\/latest.log\"\r\n}", - "stop": "^C" - }, - "scripts": { - "installation": { - "script": "#\r\n#\r\napt update\r\napt install -y wget\r\ncd \/mnt\/server\r\nwget https:\/\/dl.min.io\/server\/minio\/release\/linux-amd64\/minio\r\nchmod +x minio\r\nmkdir data\r\nmkdir keys\r\nwget https:\/\/github.com\/tmunsch\/eggs\/raw\/minio\/storage\/minio.sh\r\nchmod +x minio.sh\r\nexport MINIO_ACCESS_KEY=$(cat \/dev\/urandom | tr -dc 'a-zA-Z0-9' | fold -w 32 | head -n 1)\r\necho $MINIO_ACCESS_KEY > keys\/key.txt\r\nexport MINIO_SECRET_KEY=$(cat \/dev\/urandom | tr -dc 'a-zA-Z0-9' | fold -w 32 | head -n 1)\r\necho $MINIO_SECRET_KEY > keys\/secret.txt\r\necho done", - "container": "debian:buster-slim", - "entrypoint": "bash" - } - }, - "variables": [ - { - "name": "Startup Type", - "description": "normal or rotate", - "env_variable": "STARTUP_TYPE", - "default_value": "normal", - "user_viewable": true, - "user_editable": true, - "rules": "required|string|in:normal,rotate" - } - ] -} \ No newline at end of file From e1d9bb1fbcbc15f292be6b768479e540745aebc8 Mon Sep 17 00:00:00 2001 From: tmunsch Date: Fri, 27 Nov 2020 21:39:36 -0500 Subject: [PATCH 11/16] Add files via upload --- storage/minio/egg-minio-s3.json | 37 +++++++++++++++++++++++++++++++++ 1 file changed, 37 insertions(+) create mode 100644 storage/minio/egg-minio-s3.json diff --git a/storage/minio/egg-minio-s3.json b/storage/minio/egg-minio-s3.json new file mode 100644 index 00000000..246cf00f --- /dev/null +++ b/storage/minio/egg-minio-s3.json @@ -0,0 +1,37 @@ +{ + "_comment": "DO NOT EDIT: FILE GENERATED AUTOMATICALLY BY PTERODACTYL PANEL - PTERODACTYL.IO", + "meta": { + "version": "PTDL_v1" + }, + "exported_at": "2020-11-27T21:39:14-05:00", + "name": "Minio S3", + "author": "accounts@bofanodes.io", + "description": "MinIO is a cloud storage server compatible with Amazon S3, released under Apache License v2. As an object store, MinIO can store unstructured data such as photos, videos, log files, backups and container images. The maximum size of an object is 5TB.", + "features": null, + "image": "quay.io\/parkervcp\/pterodactyl-images:ubuntu", + "startup": ".\/minio.sh", + "config": { + "files": "{}", + "startup": "{\r\n \"done\": \"guide\"\r\n}", + "logs": "{\r\n \"custom\": false,\r\n \"location\": \"logs\/latest.log\"\r\n}", + "stop": "^C" + }, + "scripts": { + "installation": { + "script": "#\r\n#\r\napt update\r\napt install -y wget\r\ncd \/mnt\/server\r\nwget https:\/\/dl.min.io\/server\/minio\/release\/linux-amd64\/minio\r\nchmod +x minio\r\nmkdir data\r\nmkdir keys\r\nwget https:\/\/github.com\/tmunsch\/eggs\/raw\/minio\/storage\/minio\/minio.sh\r\nchmod +x minio.sh\r\nexport MINIO_ACCESS_KEY=$(cat \/dev\/urandom | tr -dc 'a-zA-Z0-9' | fold -w 32 | head -n 1)\r\necho $MINIO_ACCESS_KEY > keys\/key.txt\r\nexport MINIO_SECRET_KEY=$(cat \/dev\/urandom | tr -dc 'a-zA-Z0-9' | fold -w 32 | head -n 1)\r\necho $MINIO_SECRET_KEY > keys\/secret.txt\r\necho done", + "container": "debian:buster-slim", + "entrypoint": "bash" + } + }, + "variables": [ + { + "name": "Startup Type", + "description": "normal or rotate", + "env_variable": "STARTUP_TYPE", + "default_value": "normal", + "user_viewable": true, + "user_editable": true, + "rules": "required|string|in:normal,rotate" + } + ] +} \ No newline at end of file From c9040395ca572285a462002001c941bbe832399d Mon Sep 17 00:00:00 2001 From: tmunsch Date: Fri, 27 Nov 2020 21:42:59 -0500 Subject: [PATCH 12/16] Added storage for s3 minio --- README.md | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 8fcfa050..b59d6471 100644 --- a/README.md +++ b/README.md @@ -174,4 +174,8 @@ If you are reading this it looks like you are looking to add an egg to your serv [Xonotic](/xonotic/xonotic/) -[Cryofall](/cryofall/) \ No newline at end of file +[Cryofall](/cryofall/) + +## [Storage](/storage/) +### S3 Storage +* [minio](/storage/minio) From 413f221b6b74f8f53ce2f3e1d7baed9af124ce2a Mon Sep 17 00:00:00 2001 From: tmunsch Date: Fri, 27 Nov 2020 21:46:27 -0500 Subject: [PATCH 13/16] Create README.md --- storage/minio/README.md | 8 ++++++++ 1 file changed, 8 insertions(+) create mode 100644 storage/minio/README.md diff --git a/storage/minio/README.md b/storage/minio/README.md new file mode 100644 index 00000000..a3751189 --- /dev/null +++ b/storage/minio/README.md @@ -0,0 +1,8 @@ +# minio s3 + +## Known Issues +Double encryption may occur if you manually manipulate files in the /keys directory + +##Required Server Ports + +#### Key rotation is handled automatically, DO NOT manually delete files in /keys From eed9c06a7e3994a6d581784b3738564805484743 Mon Sep 17 00:00:00 2001 From: tmunsch Date: Fri, 27 Nov 2020 21:47:12 -0500 Subject: [PATCH 14/16] Update README.md --- storage/minio/README.md | 2 -- 1 file changed, 2 deletions(-) diff --git a/storage/minio/README.md b/storage/minio/README.md index a3751189..eb3f0eae 100644 --- a/storage/minio/README.md +++ b/storage/minio/README.md @@ -3,6 +3,4 @@ ## Known Issues Double encryption may occur if you manually manipulate files in the /keys directory -##Required Server Ports - #### Key rotation is handled automatically, DO NOT manually delete files in /keys From 4e4d9898adab27c605b1bc326055520a0ae30308 Mon Sep 17 00:00:00 2001 From: tmunsch Date: Fri, 27 Nov 2020 21:52:58 -0500 Subject: [PATCH 15/16] Update README.md --- storage/minio/README.md | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/storage/minio/README.md b/storage/minio/README.md index eb3f0eae..1983fcbe 100644 --- a/storage/minio/README.md +++ b/storage/minio/README.md @@ -1,6 +1,22 @@ # minio s3 +## Features +Auto generate keys on server creation bypassing default minio keys + + +Automatic Key rotation using "rotate" startup feature + +## Auto Rotate +It's possible to rotate your keys by changing the startup option to "rotate" + + +Once this is changed restart your server and it will automatically move your current keys to old and create your new keys + + +Be sure to change your startup back to "normal" once you have started your server using "rotate". This will ensure that you don't accidentally rotate your keys twice + ## Known Issues + Double encryption may occur if you manually manipulate files in the /keys directory #### Key rotation is handled automatically, DO NOT manually delete files in /keys From ed3159b34bc79bd6268758cd044ad7a88698c3a0 Mon Sep 17 00:00:00 2001 From: tmunsch Date: Fri, 27 Nov 2020 21:53:36 -0500 Subject: [PATCH 16/16] Update README.md --- storage/minio/README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/storage/minio/README.md b/storage/minio/README.md index 1983fcbe..da88976a 100644 --- a/storage/minio/README.md +++ b/storage/minio/README.md @@ -17,6 +17,6 @@ Be sure to change your startup back to "normal" once you have started your serve ## Known Issues -Double encryption may occur if you manually manipulate files in the /keys directory +Double encryption may occur if you manually manipulate files in the keys directory -#### Key rotation is handled automatically, DO NOT manually delete files in /keys +#### Key rotation is handled automatically, DO NOT manually delete files in keys directory