Skip to content

A self-hosted media server and file management system

Remove Debugging changes and fix batch script

aminnausinf54cb3a0f07b
diff --git a/docker-compose.yaml b/docker-compose.yaml
index a1aed97e..f3cd3cfe 100644
--- a/docker-compose.yaml
+++ b/docker-compose.yaml
@@ -1,7 +1,7 @@
services:
app:
image: aminnausin/mediaserver:latest
- container_name: MediaServer2
+ container_name: MediaServer
volumes:
- app-public:/var/www/html/public
- ./data:/var/www/html/storage/app/public
@@ -18,7 +18,7 @@ services:
- .env
queue:
image: aminnausin/mediaserver:latest
- container_name: job_queue2
+ container_name: job_queue
command: php artisan queue:work --timeout=3600 --tries=3
restart: unless-stopped
tty: true
@@ -32,7 +32,7 @@ services:
- .env
event-queue:
image: aminnausin/mediaserver:latest
- container_name: event_queue2
+ container_name: event_queue
command: php artisan queue:work --queue=high --tries=3
restart: unless-stopped
tty: true
@@ -46,7 +46,7 @@ services:
- .env
scheduler:
image: aminnausin/mediaserver:latest
- container_name: laravel_scheduler2
+ container_name: laravel_scheduler
command: php artisan schedule:work
restart: unless-stopped
tty: true
@@ -61,7 +61,7 @@ services:
ws:
image: aminnausin/mediaserver:latest
- container_name: ws2
+ container_name: ws
command: php artisan reverb:start
restart: unless-stopped
tty: true
@@ -79,7 +79,7 @@ services:
- .env
nginx:
image: nginx:alpine
- container_name: nginx2
+ container_name: nginx
volumes:
- ./docker/nginx/app.conf:/etc/nginx/conf.d/default.conf
- ./data:/var/www/html/storage/app/public
@@ -95,7 +95,7 @@ services:
- docker-network
db:
image: bitnami/postgresql:17.2.0
- container_name: database2
+ container_name: database
platform: linux/amd64
ports:
- 5432:5432
diff --git a/docker/.env.docker b/docker/.env.docker
index d4efb8b3..e8159479 100644
--- a/docker/.env.docker
+++ b/docker/.env.docker
@@ -4,5 +4,6 @@ APP_PORT=8080
DB_HOST=db
DB_PORT=5432
+DB_DATABASE=mediaServer
DB_USERNAME=postgres
DB_PASSWORD=root
diff --git a/startDocker.bat b/startDocker.bat
index f791c465..a91a198d 100644
--- a/startDocker.bat
+++ b/startDocker.bat
@@ -3,45 +3,45 @@ echo Checking required files and folders...
:: Ensure .docker-compose.yaml exists -> Holds app setup
if not exist docker-compose.yaml (
- echo ❌ ERROR: Missing docker compose file
- echo ➡️ Please download this file before running Docker.
+ echo ERROR: Missing docker compose file
+ echo Please download this file before running Docker.
exit /b 1
)
:: Ensure app.conf exists -> Holds nginx config
if not exist "docker/nginx/app.conf" (
- echo ❌ ERROR: Missing docker/nginx/app.conf
- echo ➡️ Please download this file before running Docker.
+ echo ERROR: Missing docker/nginx/app.conf
+ echo Please download this file before running Docker.
exit /b 1
) else (
- echo ✅ Found nginx config
+ echo Found nginx config
echo Make sure to replace 'app.test' with your website URL in 'docker/nginx/app.conf' if you have one
)
:: Ensure .env.docker exists -> Holds default environment variables
if not exist "docker/.env.docker" (
- echo ❌ ERROR: Missing ./docker/.env.docker
- echo ➡️ Please download this file before running Docker.
+ echo ERROR: Missing ./docker/.env.docker
+ echo Please download this file before running Docker.
exit /b 1
) else (
- echo ✅ Found environment variables
+ echo Found environment variables
)
:: Ensure .env exists
if not exist .env (
- echo ⚠️ .env file not found! Creating from .env.docker...
- copy docker/.env.docker .env
- echo ✅ .env file created.
+ echo .env file not found! Creating from .env.docker...
+ copy ".\docker\.env.docker" ".env"
+ echo .env file created.
)
:: Ensure the ./data directory exists -> Holds user media
if not exist "data" (
- echo ⚠️ Missing ./data directory...
+ echo Missing ./data directory...
mkdir data
- echo ✅ ./data directory created.
+ echo ./data directory created.
) else (
- echo ✅ Found ./data directory
+ echo Found ./data directory
)
-echo ✅ Setup complete
+echo Setup complete
docker-compose up
diff --git a/startDocker.sh b/startDocker.sh
index 6ded7bbe..a672c6d3 100644
--- a/startDocker.sh
+++ b/startDocker.sh
@@ -7,45 +7,45 @@ echo "🔹 Checking required files and folders..."
# Ensure .docker-compose.yaml exists -> Holds app setup
if [ ! -f "docker-compose.yaml" ]; then
- echo "❌ ERROR: Missing docker compose file"
- echo "➡️ Please download this file before running Docker."
+ echo "ERROR: Missing docker compose file"
+ echo "Please download this file before running Docker."
exit 1
fi
# Ensure app.conf exists
if [ ! -f "./docker/nginx/app.conf" ]; then
- echo "❌ ERROR: Missing ./docker/nginx/app.conf"
- echo "➡️ Please download this file before running Docker."
+ echo "ERROR: Missing ./docker/nginx/app.conf"
+ echo "Please download this file before running Docker."
exit 1
else
- echo "✅ Found nginx config"
+ echo "Found nginx config"
echo "Make sure to replace 'app.test' with your website URL in 'docker/nginx/app.conf' if you have one"
fi
# Ensure docker env exists
if [ ! -f "./docker/.env.docker" ]; then
- echo "❌ ERROR: Missing ./docker/.env.docker"
- echo "➡️ Please download this file before running Docker."
+ echo "ERROR: Missing ./docker/.env.docker"
+ echo "Please download this file before running Docker."
exit 1
else
- echo "✅ Found environment variables"
+ echo "Found environment variables"
fi
# Check if .env exists, otherwise create it from .env.example
if [ ! -f ".env" ]; then
- echo "⚠️ .env file not found! Creating from .env.docker..."
+ echo ".env file not found! Creating from .env.docker..."
cp ./docker/.env.docker .env
- echo "✅ .env file created."
+ echo ".env file created."
fi
# Ensure the ./data directory exists
if [ ! -d "./data" ]; then
- echo "⚠️ Missing ./data directory! Creating it..."
+ echo "Missing ./data directory! Creating it..."
mkdir -p ./data
- echo "✅ ./data directory created."
+ echo "./data directory created."
else
- echo "✅ Found ./data directory"
+ echo "Found ./data directory"
fi
-echo "✅ Setup complete"
+echo "Setup complete"
docker-compose up