Supporto Docker/Unraid: build, healthcheck, docs
Aggiunti Dockerfile multi-stage, .dockerignore e docker-compose.yml per deployment containerizzato (con healthcheck, volumi persistenti, limiti risorse). Script di build per Linux/Mac e Windows. In Program.cs aggiunto endpoint /health e health checks per orchestrazione. Documentazione estesa: guide Unraid, quickstart Docker, workflow Git/DevOps, best practices su sicurezza, backup, monitoring. Progetto ora pronto per deploy e gestione professionale in ambienti Docker/Unraid.
This commit is contained in:
29
TradingBot/build-docker.bat
Normal file
29
TradingBot/build-docker.bat
Normal file
@@ -0,0 +1,29 @@
|
||||
@echo off
|
||||
REM Script di build Docker per Windows
|
||||
|
||||
echo Building TradingBot Docker Image...
|
||||
|
||||
SET IMAGE_NAME=tradingbot
|
||||
SET TAG=%1
|
||||
IF "%TAG%"=="" SET TAG=latest
|
||||
|
||||
echo Building image: %IMAGE_NAME%:%TAG%
|
||||
|
||||
docker build -t %IMAGE_NAME%:%TAG% -f Dockerfile .
|
||||
|
||||
IF %ERRORLEVEL% NEQ 0 (
|
||||
echo Build failed!
|
||||
exit /b %ERRORLEVEL%
|
||||
)
|
||||
|
||||
echo Build completed successfully!
|
||||
|
||||
REM Tag come latest se diverso
|
||||
IF NOT "%TAG%"=="latest" (
|
||||
echo Tagging as latest...
|
||||
docker tag %IMAGE_NAME%:%TAG% %IMAGE_NAME%:latest
|
||||
)
|
||||
|
||||
echo Done! Run with: docker-compose up -d
|
||||
|
||||
pause
|
||||
Reference in New Issue
Block a user