Files
Alte_Skripte/de.ing.EPP_Setup.sh
2026-02-16 15:05:15 +01:00

39 lines
1.2 KiB
Bash

#!/bin/bash
### Edit this script and set the EPP server parameters in this section ###
EPP_SERVER_ADDRESS="10.92.126.250"
EPP_SERVER_PORT="443"
EPP_DEPARTMENT_CODE="defdep"
# do NOT modify the script below this line
if [ ${EPP_SERVER_ADDRESS} == "127.0.0.1" ]; then
/bin/echo "You have to set the EPP server address before running this script!"
exit 1
fi
/bin/echo "Setting the EPP server address ..."
if [ -e /Library/LaunchDaemons/com.cososys.eppclient.launchdaemon.plist ]; then
/bin/launchctl unload /Library/LaunchDaemons/com.cososys.eppclient.launchdaemon.plist 2>/dev/null
fi
/bin/sleep 4
echo "sleep"
# export EPP_INSTALL_CONFIG="/private/etc/epp/options.ini"
export EPP_INSTALL_CONFIG="/tmp/epp-srv201f0dd30"
echo "export"
/bin/mkdir -p /private/etc/epp
/bin/echo "ws_server=${EPP_SERVER_ADDRESS}" >> ${EPP_INSTALL_CONFIG}
/bin/echo "ws_port=${EPP_SERVER_PORT}" >> ${EPP_INSTALL_CONFIG}
/bin/echo "DepartmentCode=${EPP_DEPARTMENT_CODE}" >> ${EPP_INSTALL_CONFIG}
/bin/rm /private/etc/epp/cert.* 2>/dev/null
if [ -e /Library/LaunchDaemons/com.cososys.eppclient.launchdaemon.plist ]; then
/bin/launchctl load /Library/LaunchDaemons/com.cososys.eppclient.launchdaemon.plist 2>/dev/null
fi
/bin/echo "Done."