Files
caliverse_doc/11. 서버 세팅/Dev_Server/Auto_Install.bat
2025-05-01 07:27:54 +09:00

87 lines
4.4 KiB
Batchfile

@echo off
:: 현재 날짜를 YYYYMMDD 형식으로 가져오기
for /f "tokens=2 delims= " %%a in ('date /t') do set DATE=%%a
set LOG_DATE=%DATE:-=%
:: 로그 파일 경로 설정 (배치 파일과 같은 디렉토리, 날짜 포함)
set LOG_FILE=%~dp0install_%LOG_DATE%_log.txt
echo Metaverse Development Server installation starting... %date% %time%
echo Metaverse Development Server installation starting... %date% %time% >> %LOG_FILE%
:: Microsoft Visual C++ Runtime 설치 및 로그 기록
echo Installing Microsoft Visual C++ 2015-2022 Redistributable... >> %LOG_FILE%
echo Start Microsoft Visual C++ 2015-2022 Runtime installation: %time%
echo Start Microsoft Visual C++ 2015-2022 Runtime installation: %time% >> %LOG_FILE%
start /wait "" "%~dp0VC_redist.x64.exe" /quiet /install /norestart >> %LOG_FILE% 2>&1
echo End Microsoft Visual C++ 2015-2022 Runtime installation: %time%
echo End Microsoft Visual C++ 2015-2022 Runtime installation: %time% >> %LOG_FILE%
:: Microsoft .NET SDK 설치 및 로그 기록
echo Installing Microsoft .NET 8.0 SDK... >> %LOG_FILE%
echo Start Microsoft .NET 8.0 SDK installation: %time%
echo Start Microsoft .NET 8.0 SDK installation: %time% >> %LOG_FILE%
start /wait "" "%~dp0dotnet-sdk-8.0.407-win-x64.exe" /quiet /install /norestart >> %LOG_FILE% 2>&1
echo End Microsoft .NET 8.0 SDK installation: %time%
echo End Microsoft .NET 8.0 SDK installation: %time% >> %LOG_FILE%
:: Microsoft Windows SDK 설치 및 로그 기록 (Jenkins 개발 스크립트에서 사용: ssindex, symstore)
echo Installing Microsoft Windows SDK... >> %LOG_FILE%
echo Start Microsoft Windows SDK installation: %time%
echo Start Microsoft Windows SDK installation: %time% >> %LOG_FILE%
start /wait "" "%~dp0winsdksetup.exe" /features OptionId.WindowsDesktopDebugger /quiet /norestart >> %LOG_FILE% 2>&1
echo End Microsoft Windows SDK installation: %time%
echo End Microsoft Windows SDK installation: %time% >> %LOG_FILE%
:: Strawberry Perl 설치 및 로그 기록 (Jenkins 개발 스크립트에서 사용: perl)
echo Installing Strawberry Perl... >> %LOG_FILE%
echo Start Strawberry Perl installation: %time%
echo Start Strawberry Perl installation: %time% >> %LOG_FILE%
start /wait "" "%~dp0strawberry-perl-5.40.0.1-64bit.msi" /quiet /norestart >> %LOG_FILE% 2>&1
echo End Strawberry Perl installation: %time%
echo End Strawberry Perl installation: %time% >> %LOG_FILE%
:: OpenJDK 설치 및 로그 기록
echo Installing OpenJDK... >> %LOG_FILE%
echo Start OpenJDK installation: %time%
echo Start OpenJDK installation: %time% >> %LOG_FILE%
start /wait "" "%~dp0OpenJDK21U-jdk_x64_windows_hotspot_21.0.6_7.msi" /quiet /norestart >> %LOG_FILE% 2>&1
echo End OpenJDK installation: %time%
echo End OpenJDK installation: %time% >> %LOG_FILE%
:: Docker 설치 및 로그 기록
echo Installing Docker... >> %LOG_FILE%
echo Start Docker installation: %time%
echo Start Docker installation: %time% >> %LOG_FILE%
start /wait "" "%~dp0Docker Desktop Installer.exe" install --quiet --accept-license --no-start >> %LOG_FILE% 2>&1
echo End Docker installation: %time%
echo End Docker installation: %time% >> %LOG_FILE%
:: ProudNET 설치 및 로그 기록
echo Installing ProudNET... >> %LOG_FILE%
echo Start ProudNET installation: %time%
echo Start ProudNET installation: %time% >> %LOG_FILE%
start /wait "" "%~dp0ProudNetLibSetup-1.7.56164-master.exe" /silent >> %LOG_FILE% 2>&1
echo End ProudNET installation: %time%
echo End ProudNET installation: %time% >> %LOG_FILE%
:: ProudNET 라이선스 적용 시간 기록
echo Installing license... >> %LOG_FILE%
echo Start license installation: %time%
echo Start license installation: %time% >> %LOG_FILE%
start /wait "" "%~dp0PNLicenseAuth.exe" "%~dp0PNLicenseKey.txt" >> %LOG_FILE% 2>&1
echo End license installation: %time%
echo End license installation: %time% >> %LOG_FILE%
:: 그 외 필수 설치 패키지 안내
echo Please manually install jenkins.msi and TortoiseSVN-1.14.9.29743-x64-svn-1.14.5.msi in the Dev_Server folder.
echo Please manually install jenkins.msi and TortoiseSVN-1.14.9.29743-x64-svn-1.14.5.msi in the Dev_Server folder. >> %LOG_FILE% 2>&1
:: 설치 완료 메시지 및 재부팅
echo Metaverse Development Server Installation completed. System will reboot in 300 seconds... %date% %time%
echo Metaverse Development Server Installation completed. System will reboot in 300 seconds... %date% %time% >> %LOG_FILE%
timeout /t 300
shutdown /r /t 0