changing layout
This commit is contained in:
parent
17b5f751e2
commit
b1c6aa659b
37 changed files with 695 additions and 1018 deletions
3
Makefile
3
Makefile
|
|
@ -3,7 +3,6 @@ SHELL := /bin/sh
|
|||
COMPOSE ?= docker compose
|
||||
GOOSE ?= go run github.com/pressly/goose/v3/cmd/goose@v3.24.3
|
||||
POSTGRES_URL ?= postgres://cms:cms@localhost:5432/cms?sslmode=disable
|
||||
ADMIN_DATABASE_URL ?= ./cms-admin.db
|
||||
|
||||
.PHONY: up down migrate seed backend frontend dev
|
||||
|
||||
|
|
@ -15,14 +14,12 @@ down:
|
|||
|
||||
migrate:
|
||||
$(GOOSE) -dir cmd/server/migrations/postgres postgres "$(POSTGRES_URL)" up
|
||||
$(GOOSE) -dir cmd/server/migrations/admin sqlite3 "$(ADMIN_DATABASE_URL)" up
|
||||
|
||||
seed:
|
||||
psql "$(POSTGRES_URL)" -v ON_ERROR_STOP=1 -f scripts/seed_content.sql
|
||||
|
||||
backend:
|
||||
set -a; [ ! -f .env ] || . ./.env; set +a; \
|
||||
CMS_ADMIN_DATABASE_URL="$${CMS_ADMIN_DATABASE_URL:-$(ADMIN_DATABASE_URL)}" \
|
||||
CMS_APPLICATION_DATABASE_URL="$${CMS_APPLICATION_DATABASE_URL:-host=localhost user=cms password=cms dbname=cms port=5432 sslmode=disable}" \
|
||||
go run ./cmd/server
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue