Fix Docker Compose version warning and improve script permissions

DOCKER COMPOSE:
- Removed obsolete 'version' attribute from docker-compose.yml
- Keeps db-ui image as ghcr.io/n7olkachev/db-ui:latest

SCRIPT PERMISSIONS:
- Updated README.md with recursive chmod command: find . -name '*.sh' -exec chmod +x {} \;
- Updated QUICKSTART.md with Step 0: Make Scripts Executable
- Removed individual chmod commands from each step
- Single command makes all .sh files executable at once

DOCUMENTATION:
- Renumbered steps in QUICKSTART.md for clarity
- Step 0: Make Scripts Executable
- Step 1: Install Dependencies (Optional)
- Step 2: Start Docker Containers
- Step 3: Initialize Database Schema
- Step 4: Generate Test Data

This resolves the Docker Compose warning and simplifies the setup process with a single chmod command.
This commit is contained in:
Alphaeus Mote
2025-10-23 16:40:43 -04:00
parent 3dde2997f6
commit bf70fba516
3 changed files with 21 additions and 22 deletions
+10 -7
View File
@@ -108,14 +108,19 @@ git clone https://github.com/freedbygrace/SQL.git
cd SQL cd SQL
``` ```
### 2. Install Dependencies (Optional) ### 2. Make Scripts Executable
```bash
# Make all .sh files executable recursively
find . -name "*.sh" -exec chmod +x {} \;
```
### 3. Install Dependencies (Optional)
```bash ```bash
# Only if you don't have Docker, psql, etc. # Only if you don't have Docker, psql, etc.
chmod +x scripts/install-dependencies.sh
./scripts/install-dependencies.sh ./scripts/install-dependencies.sh
``` ```
### 3. Start the Database ### 4. Start the Database
```bash ```bash
docker-compose up -d docker-compose up -d
``` ```
@@ -124,17 +129,15 @@ This starts:
- **PostgreSQL 16** on port `5432` - **PostgreSQL 16** on port `5432`
- **DB-UI** web interface on port `3000` - **DB-UI** web interface on port `3000`
### 4. Initialize the Schema ### 5. Initialize the Schema
```bash ```bash
chmod +x scripts/setup-database.sh
./scripts/setup-database.sh ./scripts/setup-database.sh
``` ```
**Note:** The script will automatically check for required dependencies and prompt you to install them if missing. **Note:** The script will automatically check for required dependencies and prompt you to install them if missing.
### 5. Generate Test Data ### 6. Generate Test Data
```bash ```bash
chmod +x data/generate_data.sh
./data/generate_data.sh ./data/generate_data.sh
``` ```
-2
View File
@@ -1,5 +1,3 @@
version: '3.8'
services: services:
postgres: postgres:
image: postgres:16-alpine image: postgres:16-alpine
+11 -13
View File
@@ -2,14 +2,18 @@
## 🚀 Get Up and Running in 5 Minutes ## 🚀 Get Up and Running in 5 Minutes
### Step 0: Install Dependencies (Optional - 5 minutes) ### Step 0: Make Scripts Executable
```bash
# Make all .sh files executable recursively
find . -name "*.sh" -exec chmod +x {} \;
```
### Step 1: Install Dependencies (Optional - 5 minutes)
**If you don't have Docker, PostgreSQL client (psql), or other required tools:** **If you don't have Docker, PostgreSQL client (psql), or other required tools:**
```bash ```bash
# Make script executable
chmod +x scripts/install-dependencies.sh
# Run the installer # Run the installer
./scripts/install-dependencies.sh ./scripts/install-dependencies.sh
``` ```
@@ -25,7 +29,7 @@ chmod +x scripts/install-dependencies.sh
--- ---
### Step 1: Start Docker Containers (1 minute) ### Step 2: Start Docker Containers (1 minute)
```bash ```bash
# From the project root directory # From the project root directory
@@ -46,12 +50,9 @@ You should see both `business_analytics_db` and `business_analytics_ui` running.
--- ---
### Step 2: Initialize Database Schema (1 minute) ### Step 3: Initialize Database Schema (1 minute)
```bash ```bash
# Make script executable (first time only)
chmod +x scripts/setup-database.sh
# Run setup # Run setup
./scripts/setup-database.sh ./scripts/setup-database.sh
``` ```
@@ -71,12 +72,9 @@ chmod +x scripts/setup-database.sh
--- ---
### Step 3: Generate Test Data (15-30 minutes) ### Step 4: Generate Test Data (15-30 minutes)
```bash ```bash
# Make script executable (first time only)
chmod +x data/generate_data.sh
# Run data generation # Run data generation
./data/generate_data.sh ./data/generate_data.sh
``` ```