Fix healthcheck URL in Dockerfile and compose; update README
This commit is contained in:
@@ -29,6 +29,6 @@ USER appuser
|
|||||||
EXPOSE 5000
|
EXPOSE 5000
|
||||||
|
|
||||||
HEALTHCHECK --interval=30s --timeout=5s --start-period=10s --retries=3 \
|
HEALTHCHECK --interval=30s --timeout=5s --start-period=10s --retries=3 \
|
||||||
CMD curl -fsS http://localhost:5000/login >/dev/null || exit 1
|
CMD curl -fsS http://localhost:5000/ >/dev/null || exit 1
|
||||||
|
|
||||||
CMD ["python", "app.py"]
|
CMD ["python", "app.py"]
|
||||||
|
|||||||
98
README.md
98
README.md
@@ -1,66 +1,56 @@
|
|||||||
# KSNE-Rendiciones-App
|
# KSNE-Rendiciones-App
|
||||||
|
|
||||||
## 🐳 Docker Deployment (Server)
|
## Docker Deployment
|
||||||
|
|
||||||
Build and run the central inventory server:
|
Build and deploy the application:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
# Build the image
|
./build-deploy.sh # pulls latest code, builds image, starts container
|
||||||
docker build -t rendiciones:latest .
|
|
||||||
|
|
||||||
# Run the container (Map port 5000 and persist the database/cache)
|
# Or step by step:
|
||||||
docker run -d \
|
docker compose up -d --build
|
||||||
-p 5000:5000 \
|
|
||||||
-v $(pwd)/rendiciones/db:/app/db \
|
|
||||||
-v $(pwd)/rendiciones/static/cache:/app/static/cache \
|
|
||||||
--name rendiciones-server \
|
|
||||||
--restart unless-stopped \
|
|
||||||
rendiciones:latest
|
|
||||||
```
|
```
|
||||||
|
|
||||||
Or use this stack:
|
The app will be available at `http://localhost:5500`.
|
||||||
```yml
|
|
||||||
name: rendiciones
|
|
||||||
services:
|
|
||||||
rendiciones:
|
|
||||||
ports:
|
|
||||||
- 5000:5000
|
|
||||||
volumes:
|
|
||||||
- YOUR_PATH/rendiciones/db:/app/db
|
|
||||||
- YOUR_PATH/rendiciones/static/cache:/app/static/cache
|
|
||||||
container_name: rendiciones-server
|
|
||||||
image: rendiciones:latest
|
|
||||||
restart: unless-stopped
|
|
||||||
```
|
|
||||||
# TODO preguntas:
|
|
||||||
- ver si tienen como turnos fijos para setear un horario
|
|
||||||
- ver si trabajan mas de 2 personas maximo al dia
|
|
||||||
- ver como funcionan los productos / precios de HC
|
|
||||||
|
|
||||||
# TODO general:
|
### Volumes
|
||||||
- generar regitro centros comerciales
|
|
||||||
- generar reportes y exportar a excel
|
|
||||||
- tabla de productos vendidos durante el mes
|
|
||||||
- formulario de cosas robadas
|
|
||||||
- implementar horas extra?
|
|
||||||
- implemetar calendario como el excel
|
|
||||||
- arrglar colores en modo claro y oscuro
|
|
||||||
- separar productos para tiendas
|
|
||||||
- limpiar requirements.txt
|
|
||||||
- mostrar total de ventas con graficos en el index(?)
|
|
||||||
- mostrar ventas diarias por modulo y zona(?)
|
|
||||||
- formulario de perdidas en el dashboard(?) o hub
|
|
||||||
- categorias de productos (complementos, etc)
|
|
||||||
- precio de productos por zona
|
|
||||||
- hacer que contraseña autogenerada force a crear una nueva para el trabajador
|
|
||||||
|
|
||||||
# TODO no prioritario:
|
Persistent data is stored outside the container:
|
||||||
- dejar mas bonito las cosas de admin en media ventana o otros formatos
|
|
||||||
|
|
||||||
# TODO peppermint:
|
| Host path | Container path | Purpose |
|
||||||
## formulario
|
|---|---|---|
|
||||||
- cantidad de boletas por metodo de pago
|
| `./db` | `/app/db` | SQLite database |
|
||||||
- permitir subir foto de total gastos (boleta/factura)
|
| `./static/cache` | `/app/static/cache` | Cached files |
|
||||||
|
|
||||||
# TODO happy candy:
|
# TODO
|
||||||
- comision 2%
|
## Questions
|
||||||
|
- [ ] Verify if shifts are fixed to set a schedule
|
||||||
|
- [ ] Verify if max 2 people work per day
|
||||||
|
- [ ] Understand how HC products/prices work
|
||||||
|
|
||||||
|
## General
|
||||||
|
- [ ] Generate shopping center registry
|
||||||
|
- [ ] Generate reports and export to Excel
|
||||||
|
- [ ] Monthly sold products table
|
||||||
|
- [ ] Stolen items form
|
||||||
|
- [ ] Implement overtime?
|
||||||
|
- [ ] Implement calendar like Excel
|
||||||
|
- [ ] Fix colors in light/dark mode
|
||||||
|
- [ ] Separate products by store
|
||||||
|
- [ ] Clean up requirements.txt
|
||||||
|
- [ ] Show total sales charts on index
|
||||||
|
- [ ] Show daily sales by module/zone
|
||||||
|
- [ ] Loss report form on dashboard
|
||||||
|
- [ ] Product categories (complementos, etc)
|
||||||
|
- [ ] Product pricing by zone
|
||||||
|
- [ ] Force password change on first login for workers
|
||||||
|
|
||||||
|
## Low Priority
|
||||||
|
- [ ] Polish admin UI layout
|
||||||
|
|
||||||
|
## Peppermint
|
||||||
|
- [ ] Receipt count by payment method
|
||||||
|
- [ ] Allow uploading expense receipt photos
|
||||||
|
|
||||||
|
## Happy Candy
|
||||||
|
- [ ] 2% commission
|
||||||
@@ -17,7 +17,7 @@ services:
|
|||||||
- /home/shironeko/Documents/dockerVols/rendiciones/static/cache:/app/static/cache
|
- /home/shironeko/Documents/dockerVols/rendiciones/static/cache:/app/static/cache
|
||||||
restart: unless-stopped
|
restart: unless-stopped
|
||||||
healthcheck:
|
healthcheck:
|
||||||
test: ["CMD", "curl", "-fsS", "http://localhost:5000/login"]
|
test: ["CMD", "curl", "-fsS", "http://localhost:5000/"]
|
||||||
interval: 30s
|
interval: 30s
|
||||||
timeout: 5s
|
timeout: 5s
|
||||||
retries: 3
|
retries: 3
|
||||||
|
|||||||
Reference in New Issue
Block a user