Refactor dnsmasq setup script: update file paths and remove obsolete script

This commit is contained in:
2025-06-27 08:48:13 -07:00
parent d1ea7ea998
commit 274e8de4b8
3 changed files with 1 additions and 51 deletions

View File

@@ -94,7 +94,7 @@ wget http://boot.ipxe.org/arm64-efi/ipxe.efi -O ${FTPD_DIR}/ipxe-arm64.efi
cp "${DNSMASQ_SETUP_DIR}/nginx.conf" "${BUNDLE_DIR}/nginx.conf" cp "${DNSMASQ_SETUP_DIR}/nginx.conf" "${BUNDLE_DIR}/nginx.conf"
cp "${DNSMASQ_SETUP_DIR}/dnsmasq.conf" "${BUNDLE_DIR}/dnsmasq.conf" cp "${DNSMASQ_SETUP_DIR}/dnsmasq.conf" "${BUNDLE_DIR}/dnsmasq.conf"
cp "${DNSMASQ_SETUP_DIR}/bin/setup.sh" "${BUNDLE_DIR}/setup.sh" cp "${DNSMASQ_SETUP_DIR}/setup.sh" "${BUNDLE_DIR}/setup.sh"
# Copy setup bundle to DNSMasq server. # Copy setup bundle to DNSMasq server.
# This is the server that will run DNSMasq and serve PXE boot files. # This is the server that will run DNSMasq and serve PXE boot files.

View File

@@ -1,50 +0,0 @@
#!/bin/bash
set -e
set -o pipefail
if [ ! -d ".wildcloud" ]; then
echo "Error: You must run this script from a wild-cloud directory"
exit 1
fi
WILDCLOUD_ROOT=$(wild-config wildcloud.root) || exit 1
# Cluster-nodes
if [ -d "${DEST_DIR}/cluster-nodes" ]; then
echo "Warning: ${DEST_DIR}/cluster-nodes already exists"
read -p "Overwrite? (y/N): " -n 1 -r
echo
if [[ ! $REPLY =~ ^[Yy]$ ]]; then
echo "Skipping cluster-nodes setup"
else
rm -rf "${DEST_DIR}/cluster-nodes"
cp -r "${SOURCE_DIR}/cluster-nodes" "${DEST_DIR}/cluster-nodes"
echo "Successfully created cluster-nodes setup files."
fi
else
cp -r "${SOURCE_DIR}/cluster-nodes" "${DEST_DIR}/cluster-nodes"
echo "Successfully created cluster-nodes setup files."
fi
# Cluster
if [ -d "${DEST_DIR}/cluster" ]; then
echo "Warning: ${DEST_DIR}/cluster already exists"
read -p "Overwrite? (y/N): " -n 1 -r
echo
if [[ ! $REPLY =~ ^[Yy]$ ]]; then
echo "Skipping cluster setup"
else
rm -rf "${DEST_DIR}/cluster"
cp -r "${SOURCE_DIR}/cluster" "${DEST_DIR}/cluster"
echo "Successfully created cluster setup files."
fi
else
cp -r "${SOURCE_DIR}/cluster" "${DEST_DIR}/cluster"
echo "Successfully created cluster setup files."
fi
# Instructions
cp "${SOURCE_DIR}/README.md" "${DEST_DIR}/README.md"