added docker script and other necessary changes

This commit is contained in:
metatroncubeswdev 2026-01-31 09:10:01 -05:00
parent 3b4d2f4866
commit a6547c8778
4 changed files with 144 additions and 27 deletions

View File

@ -1,43 +1,42 @@
/* ========================================
ODOO THEME COLOR VARIABLES
Primary Color: #fecd4f (Golden Yellow)
Secondary Color: #2bb1a5 (Teal)
Primary Color: #ec0000 (Dine360 Red)
Secondary Color: #000000 (Black)
======================================== */
:root {
/* Primary Brand Colors */
--primary-color: #fecd4f;
--primary-dark: #e5b846;
--primary-light: #ffd970;
--primary-lighter: #ffe599;
--primary-color: #ec0000;
--primary-dark: #c80000;
--primary-light: #ff3b3b;
--primary-lighter: #ff7a7a;
/* Secondary/Accent Color - Used in Gradients */
--secondary-color: #2bb1a5;
--secondary-dark: #259a8f;
--secondary-light: #4dc4b8;
/* Secondary/Accent Color */
--secondary-color: #000000;
--secondary-dark: #000000;
--secondary-light: #1a1a1a;
/* Gradient Combinations - Matching Login Page */
--gradient-primary: linear-gradient(135deg, #2bb1a5 0%, #fecd4f 100%);
--gradient-primary-hover: linear-gradient(135deg, #259a8f 0%, #e5b846 100%);
/* Gradient Combinations */
--gradient-primary: linear-gradient(135deg, #000000 0%, #ec0000 100%);
--gradient-primary-hover: linear-gradient(135deg, #1a1a1a 0%, #c80000 100%);
/* Home Page Background Gradient */
--bg-gradient-main: linear-gradient(135deg, #8fe0d6 0%, #ffecb5 100%);
/* Home Page Background */
--bg-gradient-main: #ffffff;
/* UI Element Colors */
--btn-primary-bg: #fecd4f;
--link-color: #2bb1a5;
/* Teal for better contrast on white */
--link-hover: #e5b846;
--btn-primary-bg: #ec0000;
--link-color: #000000;
--link-hover: #c80000;
/* Status Colors */
--success-color: #2bb1a5;
--warning-color: #fecd4f;
--danger-color: #ff5e62;
--info-color: #4dc4b8;
--success-color: #000000;
--warning-color: #ec0000;
--danger-color: #ec0000;
--info-color: #1a1a1a;
/* Shadows */
--shadow-primary: 0 4px 15px rgba(43, 177, 165, 0.2);
--shadow-primary-hover: 0 8px 20px rgba(43, 177, 165, 0.3);
--shadow-primary: 0 4px 15px rgba(236, 0, 0, 0.2);
--shadow-primary-hover: 0 8px 20px rgba(236, 0, 0, 0.3);
--shadow-card: 0 10px 30px rgba(0, 0, 0, 0.08);
}
@ -579,4 +578,4 @@ a:hover,
color: #fff;
background-color: #259a8f;
border-color: #259a8f;
}
}

View File

@ -13,7 +13,7 @@
- Store Keeper
""",
'author': 'Dine360',
'depends': ['point_of_sale', 'purchase', 'stock', 'website_sale'],
'depends': ['point_of_sale', 'pos_restaurant', 'purchase', 'stock', 'website_sale'],
'data': [
'security/restaurant_security.xml',
'security/ir.model.access.csv',

59
new-client-compose.bat Normal file
View File

@ -0,0 +1,59 @@
@echo off
setlocal enabledelayedexpansion
if "%~1"=="" (
echo Usage: new-client-compose.bat NAME [PORT]
exit /b 1
)
set NAME=%~1
set PORT=%~2
:: Normalize name (replace spaces with underscore)
set SLUG=%NAME: =_%
if "%PORT%"=="" (
for /f %%A in ('dir /b docker-compose-*.yml ^| find /c /v ""') do set COUNT=%%A
set /a PORT=10001+%COUNT%+1
)
set FILE=docker-compose-%SLUG%.yml
(
echo version: "3.8"
echo services:
echo db:
echo image: postgres:15
echo container_name: odoo_%SLUG%_db
echo environment:
echo POSTGRES_DB: postgres
echo POSTGRES_USER: odoo
echo POSTGRES_PASSWORD: odoo
echo volumes:
echo - %SLUG%_pgdata:/var/lib/postgresql/data
echo restart: always
echo.
echo odoo:
echo image: odoo:17.0
echo container_name: odoo_%SLUG%
echo depends_on:
echo - db
echo ports:
echo - "%PORT%:8069"
echo environment:
echo HOST: db
echo USER: odoo
echo PASSWORD: odoo
echo volumes:
echo - %SLUG%_odoo_data:/var/lib/odoo
echo - ./addons:/mnt/extra-addons
echo restart: always
echo.
echo volumes:
echo %SLUG%_pgdata:
echo %SLUG%_odoo_data:
) > "%FILE%"
echo Created %FILE% with Odoo port %PORT%
echo Run: docker-compose -p %SLUG% -f %FILE% up -d
endlocal

59
new-client-compose.ps1 Normal file
View File

@ -0,0 +1,59 @@
param(
[Parameter(Mandatory=$true)]
[string]$Name,
[int]$Port = 0
)
$clean = $Name.Trim()
if (-not $clean) { throw "Name is required." }
# Normalize name for Docker resources
$slug = ($clean -replace '[^a-zA-Z0-9_-]', '_').ToLower()
if ($Port -eq 0) {
# Auto-pick port: 10001 + current compose count (simple heuristic)
$existing = Get-ChildItem -Filter 'docker-compose-*.yml' | Measure-Object | Select-Object -ExpandProperty Count
$Port = 10001 + $existing + 1
}
$filename = "docker-compose-$slug.yml"
$yml = @"
version: "3.8"
services:
db:
image: postgres:15
container_name: odoo_${slug}_db
environment:
POSTGRES_DB: postgres
POSTGRES_USER: odoo
POSTGRES_PASSWORD: odoo
volumes:
- ${slug}_pgdata:/var/lib/postgresql/data
restart: always
odoo:
image: odoo:17.0
container_name: odoo_${slug}
depends_on:
- db
ports:
- "${Port}:8069"
environment:
HOST: db
USER: odoo
PASSWORD: odoo
volumes:
- ${slug}_odoo_data:/var/lib/odoo
- ./addons:/mnt/extra-addons
restart: always
volumes:
${slug}_pgdata:
${slug}_odoo_data:
"@
$yml | Set-Content -Path $filename
Write-Host "Created $filename with Odoo port $Port" -ForegroundColor Green
Write-Host "Run: docker-compose -p $slug -f $filename up -d" -ForegroundColor Cyan