feat: rename WHM→NixServer, cPanel→NixClient, bump v0.2.0

- Rename frontend workspaces: whm/ → nixserver/, cpanel/ → nixclient/
- Rename server route dirs: routes/whm/ → routes/nixserver/, routes/cpanel/ → routes/nixclient/
- Update all API prefixes: /api/whm → /api/nixserver, /api/cpanel → /api/nixclient
- Rename env vars: WHM_PORT → NIXSERVER_PORT, CPANEL_PORT → NIXCLIENT_PORT
- Update config properties: whmPort → nixserverPort, cpanelPort → nixclientPort
- Update all UI labels, login pages, sidebar branding, and error messages
- Update installer and update scripts to match new names
- Add cpanel email route (missing from initial scaffold)
- Add .gitattributes to enforce LF line endings
- Bump version to 0.2.0 across all package.json files
This commit is contained in:
NixReaper
2026-04-05 10:54:15 -05:00
parent 16245b2d4b
commit 92d08d7b79
84 changed files with 243 additions and 234 deletions
+18 -18
View File
@@ -30,8 +30,8 @@ EOF
echo -e "${RESET}"
echo -e " Version : ${BOLD}0.1.0${RESET}"
echo -e " GitHub : ${BOLD}https://github.com/NixReaper/nixpanel-server${RESET}"
echo -e " WHM : ${BOLD}https://<your-ip>:2087${RESET}"
echo -e " cPanel : ${BOLD}https://<your-ip>:2083${RESET}"
echo -e " NixServer: ${BOLD}https://<your-ip>:2087${RESET}"
echo -e " NixClient: ${BOLD}https://<your-ip>:2083${RESET}"
echo ""
# ── Root check ────────────────────────────────────────────────────────────────
@@ -341,8 +341,8 @@ JWT_REFRESH_EXPIRES_IN="7d"
# Server
NODE_ENV="production"
WHM_PORT=2087
CPANEL_PORT=2083
NIXSERVER_PORT=2087
NIXCLIENT_PORT=2083
HOST="0.0.0.0"
# Admin credentials (used during initial seed only)
@@ -398,11 +398,11 @@ ADMIN_EMAIL="${ADMIN_EMAIL}" \
success "Default admin, packages, and settings seeded"
# ── Build frontends ───────────────────────────────────────────────────────────
step "Building WHM + cPanel frontends"
step "Building NixServer + NixClient frontends"
cd "$INSTALL_DIR"
npm run build --workspace=whm --silent
npm run build --workspace=cpanel --silent
npm run build --workspace=nixserver --silent
npm run build --workspace=nixclient --silent
success "Frontends built"
# ── systemd service ───────────────────────────────────────────────────────────
@@ -453,13 +453,13 @@ fi
cat > /etc/nginx/sites-available/nixpanel.conf <<NGINX
# NixPanel — generated by installer
# WHM admin panel on port 2087
# NixServer admin panel on port 2087
server {
listen 2087;
server_name _;
# Serve pre-built WHM React app
root ${INSTALL_DIR}/whm/dist;
# Serve pre-built NixServer React app
root ${INSTALL_DIR}/nixserver/dist;
index index.html;
location / {
@@ -485,12 +485,12 @@ server {
}
}
# cPanel user panel on port 2083
# NixClient user panel on port 2083
server {
listen 2083;
server_name _;
root ${INSTALL_DIR}/cpanel/dist;
root ${INSTALL_DIR}/nixclient/dist;
index index.html;
location / {
@@ -538,8 +538,8 @@ if [[ "$PKG_MGR" == "apt" ]]; then
ufw allow 22/tcp comment "SSH" >/dev/null
ufw allow 80/tcp comment "HTTP" >/dev/null
ufw allow 443/tcp comment "HTTPS" >/dev/null
ufw allow 2087/tcp comment "WHM" >/dev/null
ufw allow 2083/tcp comment "cPanel" >/dev/null
ufw allow 2087/tcp comment "NixServer" >/dev/null
ufw allow 2083/tcp comment "NixClient" >/dev/null
ufw allow 21/tcp comment "FTP" >/dev/null
ufw allow 25/tcp comment "SMTP" >/dev/null
ufw allow 143/tcp comment "IMAP" >/dev/null
@@ -637,12 +637,12 @@ echo -e "${BOLD}${GREEN}╔═════════════════
echo -e "${BOLD}${GREEN}║ NixPanel Installation Complete! ║${RESET}"
echo -e "${BOLD}${GREEN}╚══════════════════════════════════════════════════════╝${RESET}"
echo ""
echo -e " ${BOLD}WHM (Admin Panel)${RESET}"
echo -e " ${BOLD}NixServer (Admin Panel)${RESET}"
echo -e " URL : ${CYAN}http://${SERVER_IP}:2087${RESET}"
echo -e " Username : ${BOLD}${ADMIN_USER}${RESET}"
echo -e " Password : ${BOLD}${ADMIN_PASS}${RESET}"
echo ""
echo -e " ${BOLD}cPanel (User Panel)${RESET}"
echo -e " ${BOLD}NixClient (User Panel)${RESET}"
echo -e " URL : ${CYAN}http://${SERVER_IP}:2083${RESET}"
echo ""
echo -e " ${BOLD}Database${RESET}"
@@ -671,8 +671,8 @@ CRED_FILE="/root/.nixpanel_credentials"
cat > "$CRED_FILE" <<CREDS
NixPanel Credentials — $(date -u '+%Y-%m-%d %H:%M:%S UTC')
==========================================================
WHM URL : http://${SERVER_IP}:2087
cPanel URL : http://${SERVER_IP}:2083
NixServer URL : http://${SERVER_IP}:2087
NixClient URL : http://${SERVER_IP}:2083
Admin User : ${ADMIN_USER}
Admin Pass : ${ADMIN_PASS}
Admin Email: ${ADMIN_EMAIL}
+2 -2
View File
@@ -30,8 +30,8 @@ success "Migrations applied"
step "Rebuilding frontends"
cd "$INSTALL_DIR"
npm run build --workspace=whm --silent
npm run build --workspace=cpanel --silent
npm run build --workspace=nixserver --silent
npm run build --workspace=nixclient --silent
success "Frontends rebuilt"
step "Rebuilding server"