automated push from the terminal

This commit is contained in:
Software Shinobi
2026-02-19 00:37:10 -05:00
parent d83faa7a34
commit 3e65788ffd
9 changed files with 447 additions and 194 deletions

19
.recycle/database.bash Executable file
View File

@@ -0,0 +1,19 @@
#!/bin/bash
##
reset
clear
##
set -e
set -x
##
docker compose -f database.yaml down --remove-orphans
docker compose -f database.yaml up -d --build

55
.recycle/database.yaml Normal file
View File

@@ -0,0 +1,55 @@
services:
##########################################
##
## hosting / relational data
##
##########################################
card-players-unite-postgres:
container_name: card-players-unite-postgres
image: postgres:14.1-alpine
restart: unless-stopped
ports:
- 5432:5432
environment:
- POSTGRES_DB=maverickdb
- POSTGRES_USER=maverickdb
- POSTGRES_PASSWORD=maverickdb
volumes:
- /tmp/volumes/postgres:/var/lib/postgresql/data
card-players-unite-pgadmin:
container_name: card-players-unite-pgadmin
image: dpage/pgadmin4
depends_on:
- card-players-unite-postgres
ports:
- "5480:80"
environment:
PGADMIN_DEFAULT_EMAIL: lorem@loremipsum.com
PGADMIN_DEFAULT_PASSWORD: maverickdb
volumes:
- /tmp/volumes/pgadmin4:/var/lib/pgadmin

38
.recycle/django.bash Executable file
View File

@@ -0,0 +1,38 @@
#!/bin/bash
##
set -e
set -x
##
reset
clear
##
#python3 manage.py dumpdata
## This will IRREVERSIBLY DESTROY all data currently in the "maverickdb" database, and return each table to an empty state.
### python3 manage.py flush
### python3 manage.py sqlflush
#python3 manage.py sqlmigrate
##python3 manage.py sqlsequencereset
#python3 manage.py generateschema
python3 manage.py makemigrations
python3 manage.py migrate
#python3 manage.py squashmigrations bikes
#python3 manage.py optimizemigration
python3 manage.py runserver 0.0.0.0:8888

25
.recycle/provision.bash Executable file
View File

@@ -0,0 +1,25 @@
#!/bin/bash
# 1. Setup/Re-setup Virtual Environment
python3 -m venv venv
source venv/bin/activate
# 2. Downgrade pip to bypass the invalid metadata error in django-rest-auth-forked
pip install "pip<24.1"
# 3. Install requirements (now it will ignore the parenthesis error)
if [ -f "requirements.txt" ]; then
pip install -r requirements.txt
else
pip install django
fi
echo "Setup complete. Run 'source venv/bin/activate' to start working."