This commit is contained in:
parent
c60cadc638
commit
609e729a5f
1 changed files with 13 additions and 7 deletions
|
|
@ -7,9 +7,10 @@ for PARAM in "$@"; do
|
|||
--static) STATIC=true ;;
|
||||
--nouefi) UEFI=false ;;
|
||||
--nocrypt) HDDCRYPT=false ;;
|
||||
--noswap) NOSWAP=false ;;
|
||||
--desktop) DESKTOP=desktop ;;
|
||||
--help)
|
||||
echo "syntaxe: $0 [--help] [--static] [--version=7|8] [--distrib=RedHat|CentOS|AlmaLinux] [--nouefi] [--nocrypt] [--desktop]"
|
||||
echo "syntaxe: $0 [--help] [--static] [--version=7|8|9] [--distrib=RedHat|CentOS|AlmaLinux|RockyLinux] [--nouefi] [--nocrypt] [--desktop] [--noswap]"
|
||||
exit 0
|
||||
;;
|
||||
esac
|
||||
|
|
@ -38,18 +39,18 @@ MAC="$(ip addr show $IF | grep ether\ | awk '{print $2}' | cut -d/ -f2 | tr [A-
|
|||
DNS="$(grep nameserver /etc/resolv.conf | grep -v 127.0.0.1 | awk '{printf $2","}' | sed 's/,$//')"
|
||||
ARCH=$(uname -m | sed 's|i.86|i386|')
|
||||
|
||||
if [ "${DIST_VERSION}" == "8" ]; then
|
||||
if [ "${DIST_VERSION}" == "8" -o "${DIST_VERSION}" == "9" ]; then
|
||||
#MIRROIR=http://lune.saacy.reslinger.net/repos/CentOS8/$ARCH/os
|
||||
if [ "$DISTRIB" == "CentOS" ]; then
|
||||
MIRROIR=http://mirror.centos.org/centos/8/BaseOS/$ARCH/os
|
||||
MIRROIR=http://mirror.centos.org/centos/${DIST_VERSION}/BaseOS/$ARCH/os
|
||||
elif [ "$DISTRIB" == "RedHat" ]; then
|
||||
MIRROIR=https://boot.reslinger.net/repo/8/rhel
|
||||
MIRROIR=https://boot.reslinger.net/repo/${DIST_VERSION}/rhel
|
||||
# elif [ "$DISTRIB" == "OracleLinux" ]; then
|
||||
# MIRROIR=https://xxxx/8/BaseOS/$ARCH/os
|
||||
# MIRROIR=https://xxxx/${DIST_VERSION}/BaseOS/$ARCH/os
|
||||
elif [ "$DISTRIB" == "RockyLinux" ]; then
|
||||
MIRROIR=https://download.rockylinux.org/pub/rocky/8/BaseOS/$ARCH/os/
|
||||
MIRROIR=https://download.rockylinux.org/pub/rocky/${DIST_VERSION}/BaseOS/$ARCH/os/
|
||||
elif [ "$DISTRIB" == "AlmaLinux" ]; then
|
||||
MIRROIR=https://repo.almalinux.org/almalinux/8/BaseOS/$ARCH/os
|
||||
MIRROIR=https://repo.almalinux.org/almalinux/${DIST_VERSION}/BaseOS/$ARCH/os
|
||||
fi
|
||||
elif [ "${DIST_VERSION}" == "7" ]; then
|
||||
#MIRROIR=http://centos.mirrors.ovh.net/ftp.centos.org/7/os/$ARCH
|
||||
|
|
@ -72,6 +73,11 @@ if [ ! -z "$HDDCRYPT" ]; then
|
|||
INST_OPTIONS="${INST_OPTIONS} nocrypt"
|
||||
fi
|
||||
fi
|
||||
if [ ! -z "$NOSWAP" ]; then
|
||||
if [ "$NOSWAP" == "false" ]; then
|
||||
INST_OPTIONS="${INST_OPTIONS} noswap"
|
||||
fi
|
||||
fi
|
||||
if [ -z "$DNS" ]; then
|
||||
if [ $(whois $IP | grep -ci dedibox) -gt 0 ]; then
|
||||
# Dedibox
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue