Skip to content

Instantly share code, notes, and snippets.

View NotYusta's full-sized avatar

Yusta NotYusta

View GitHub Profile
@NotYusta
NotYusta / BouncePearl.kt
Created August 24, 2020 14:36
Enderpearl yang bisa genjot genjot
package me.redepic.checkpearl
import net.milkbowl.vault.permission.Permission
import org.bukkit.Bukkit
import org.bukkit.entity.EnderPearl
import org.bukkit.entity.Player
import org.bukkit.event.EventHandler
import org.bukkit.event.Listener
import org.bukkit.event.entity.ProjectileHitEvent
import org.bukkit.event.entity.ProjectileLaunchEvent
@NotYusta
NotYusta / minecraft.sh
Last active February 8, 2024 12:00
Minecraft Custom Startup
DEFAULT_ARGUMENT="-Dterminal.jline=false \
-Dterminal.ansi=true \
-XX:+UseG1GC \
-XX:+ParallelRefProcEnabled \
-XX:MaxGCPauseMillis=200 \
-XX:+UnlockExperimentalVMOptions \
-XX:+DisableExplicitGC \
-XX:G1NewSizePercent=30 \
-XX:G1MaxNewSizePercent=40 \
-XX:G1HeapRegionSize=8M \
@NotYusta
NotYusta / minecraft_forge.sh
Last active February 8, 2024 12:01
Minecraft Custom Startup for forge
DEFAULT_ARGUMENT="-XX:+UseG1GC \
-XX:+ParallelRefProcEnabled \
-XX:MaxGCPauseMillis=200 \
-XX:+UnlockExperimentalVMOptions \
-XX:+DisableExplicitGC \
-XX:G1NewSizePercent=30 \
-XX:G1MaxNewSizePercent=40 \
-XX:G1HeapRegionSize=8M \
-XX:G1ReservePercent=20 \
-XX:G1HeapWastePercent=5 \
@NotYusta
NotYusta / firewall.sh
Last active March 28, 2025 17:07
Firewall Cloudflare & SSH
#!/bin/sh
# Check if firewalld exists and stop/disable it if present
if command -v firewalld >/dev/null 2>&1; then
echo "Firewalld detected. Stopping and disabling firewalld..."
systemctl stop firewalld
systemctl disable firewalld
else
echo "Firewalld not found. Continuing with iptables..."
fi
@NotYusta
NotYusta / add_swap.sh
Last active May 4, 2025 10:53
Swapfile installation script (Auto - 30%) - Enterprise Linux
#!/bin/sh
# Update system and install grep
if command -v dnf >/dev/null 2>&1; then
dnf update -y
dnf install -y grep
elif command -v apt >/dev/null 2>&1; then
apt update -y
apt install -y grep
else
@NotYusta
NotYusta / install_wings.sh
Last active March 18, 2025 14:23
Install Pterodactyl Wings & Docker
#!/bin/sh
WINGS_SYSTEMD_FILE="/etc/systemd/system/wings.service"
WINGS_SYSTEMD="\
[Unit]
Description=Pterodactyl Wings Daemon
After=docker.service
Requires=docker.service
PartOf=docker.service
[Service]
@NotYusta
NotYusta / install_wings_full.sh
Last active May 4, 2025 10:54
Add swap, Install Firewall, Wings & Docker
#!/bin/sh
INSTALL_FIREWALL_URL="https://gist.githubusercontent.com/NotYusta/d1e227f6dbd27323b8c475586fe6d43d/raw/50d7798fd65bbaef945d8316df7a413fa25fe359/firewall.sh"
INSTALL_WINGS_URL="https://gist.githubusercontent.com/NotYusta/77c998832676310b53761adb0c3546c7/raw/5c220329c685ba8f331395629daaea7bb11c9a4b/install_wings.sh"
ADD_SWAP_URL="https://gist.githubusercontent.com/NotYusta/bc86b388b0661604bbab70a987c88bd2/raw/34900dba58368aeca79d0e6cb2050f0cc4330f5a/add_swap.sh"
RC_LOCAL_URL="https://gist.githubusercontent.com/NotYusta/0d669bd57bfc67a56c8f1f18941a2b9a/raw/9b01ea04856264b619c604699cf7202a250614b5/rc-local.sh"
if command -v dnf >/dev/null; then
dnf update -y
dnf install curl -y
elif command -v apt >/dev/null; then
@NotYusta
NotYusta / test.sh
Last active March 2, 2024 07:57
Test bash
#!/bin/sh
mkdir test
echo "You successfully did it"
echo "$TOKEN"
@NotYusta
NotYusta / install_certificate.sh
Last active February 17, 2024 05:58
Install certificate and replace all certificate subdomains with domain's one.
#!/bin/sh
DOMAIN_NAME=""
CERTIFICATE_PATH="/etc/letsencrypt/live"
# MAKE SURE USE \ TO PREVENT TRAILING SPACES.
PRIVATE_KEY=""
PUBLIC_CERT=""
rm -rfv "$CERTIFICATE_PATH/$DOMAIN_NAME"
mkdir -pv "$CERTIFICATE_PATH/$DOMAIN_NAME"
echo "$PUBLIC_CERT" | sudo tee -a "$CERTIFICATE_PATH/$DOMAIN_NAME/fullchain.pem"
@NotYusta
NotYusta / rc-local.sh
Last active March 18, 2025 12:18
RC Local
#!/bin/sh
# Detect system type
if command -v dnf >/dev/null 2>&1; then
OS="rhel"
RC_LOCAL="/etc/rc.d/rc.local"
elif command -v apt >/dev/null 2>&1; then
OS="debian"
RC_LOCAL="/etc/rc.local"
else