chore: docker compose dev
TS Lint / Oxlint (push) Successful in 40s
TS Lint / TypeScript (push) Successful in 46s
TS Lint / ESLint (push) Successful in 46s

This commit is contained in:
2026-06-30 23:20:58 +02:00
parent c92f337006
commit deba8a73f9
4 changed files with 70 additions and 7 deletions
+41 -6
View File
@@ -7,18 +7,24 @@ ifeq (,$(shell which uv))
UV ?= python3 -m uv UV ?= python3 -m uv
endif endif
UV ?= uv
RUFF ?= $(UV) run --active ruff
TY ?= $(UV) run --active ty
ifeq (,$(shell which bun)) ifeq (,$(shell which bun))
NPM ?= npm NPM ?= npm
endif endif
UV ?= uv
RUFF ?= $(UV) run --active ruff
TY ?= $(UV) run --active ty
UNITTEST ?= $(UV) run --active -m unittest
COVERAGE ?= $(UV) run --active coverage
OPEN ?= xdg-open
NPM ?= bun NPM ?= bun
ifeq (,$(shell which podman))
DOCKER ?= docker
endif
DOCKER ?= podman
OPEN ?= xdg-open
# DOCS # DOCS
.PHONY: help .PHONY: help
@@ -60,6 +66,15 @@ format: ruff-fix ruff-format npm-run-lint-fix ## format project
.PHONY: lint .PHONY: lint
lint: ruff ruff-format-check ty npm-run-lint npm-run-type-check ## lint project lint: ruff ruff-format-check ty npm-run-lint npm-run-type-check ## lint project
.PHONY: start
start: docker-compose-up
.PHONY: stop
stop: docker-compose-down
.PHONY: logs
logs: docker-compose-logs
# TOOLS # TOOLS
.PHONY: uv-sync .PHONY: uv-sync
@@ -102,6 +117,26 @@ npm-update: ## npm update
npm-run-%: node_modules ## npm run (script) npm-run-%: node_modules ## npm run (script)
$(NPM) run $* $(NPM) run $*
.PHONY: docker-compose-up
docker-compose-up: ## docker compose up
$(DOCKER) compose up -d
.PHONY: docker-compose-up-%
docker-compose-up-%: ## docker compose up (container)
$(DOCKER) compose up -d $*
.PHONY: docker-compose-down
docker-compose-down: ## docker compose down
$(DOCKER) compose down --remove-orphans
.PHONY: docker-compose-down-%
docker-compose-down-%: ## docker compose down (container)
$(DOCKER) compose down --remove-orphans $*
.PHONY: docker-compose-logs
docker-compose-logs: ## docker compose logs
$(DOCKER) compose logs -f || true
.PHONY: release-% .PHONY: release-%
release-%: .venv ## release major/minor/patch release-%: .venv ## release major/minor/patch
$(UV) version --bump=$* $(UV) version --bump=$*
+1
View File
@@ -1,5 +1,6 @@
{ {
"lockfileVersion": 1, "lockfileVersion": 1,
"configVersion": 0,
"workspaces": { "workspaces": {
"": { "": {
"name": "tout-doux", "name": "tout-doux",
+27
View File
@@ -0,0 +1,27 @@
networks:
backend:
services:
app:
image: astral/uv:python3.14-alpine
volumes:
- .:/app
working_dir: /app
environment:
- APP_ENV=dev
- PORT=5000
- BIND=0.0.0.0
command: uv run tout-doux --debug
networks:
- backend
vite:
image: oven/bun:latest
volumes:
- .:/app
working_dir: /app
command: bun run dev
ports:
- "5173:5173"
networks:
- backend
+1 -1
View File
@@ -12,7 +12,7 @@ export default defineConfig({
hmr: true, hmr: true,
proxy: { proxy: {
"/api": { "/api": {
target: "http://localhost:5000", target: "http://app:5000",
changeOrigin: true, changeOrigin: true,
secure: false, secure: false,
}, },