No description
  • JavaScript 54.8%
  • Python 27.8%
  • HTML 9.5%
  • Shell 3%
  • Just 2%
  • Other 2.9%
Find a file
Augspies 3ef19f6805
All checks were successful
deploy / staging (push) Successful in 1m58s
deploy / production (push) Has been skipped
Merge pull request 'fix(bugs): lets see if this builds' (#30) from fix/bugs into dev
Reviewed-on: #30
2026-07-20 15:34:15 +02:00
.forgejo/workflows fix(ci): add registry login 2026-07-03 07:49:17 +02:00
apps fix(bugs): lets see if this builds 2026-07-19 19:43:32 +02:00
deploy fix(bugs): lets see if this builds 2026-07-19 19:43:32 +02:00
virtual_attorney fix(bugs): lets see if this builds 2026-07-19 19:43:32 +02:00
.coveragerc feat(initial): first commit. main app structure 2026-05-11 15:31:03 +02:00
.dockerignore fix(bugs): lets see if this builds 2026-07-19 19:43:32 +02:00
.gitignore chore(fonts): Add site fonts 2026-07-18 08:51:06 +02:00
.isort.cfg feat(init): initial commit 2026-05-11 13:43:56 +02:00
.pre-commit-config.yaml feat(init): initial commit 2026-05-11 13:43:56 +02:00
ansible.cfg feat(ansible): adds new ansible roles for deployment 2026-07-12 13:41:34 +02:00
build.config.js feat(initial): first commit. main app structure 2026-05-11 15:31:03 +02:00
bun.lock feat(init): initial commit 2026-05-11 13:43:56 +02:00
docker-compose-deploy.yml chore(deploy): all deploy issues sorted 2026-07-12 16:57:19 +02:00
docker-compose.yml feat(init): initial commit 2026-05-11 13:43:56 +02:00
docker-entrypoint.sh feat(init): initial commit 2026-05-11 13:43:56 +02:00
Dockerfile fix(dockerfile): add gettext 2026-07-14 16:51:49 +02:00
justfile fix(bugs): lets see if this builds 2026-07-19 19:43:32 +02:00
manage.py feat(initial): first commit. main app structure 2026-05-11 15:31:03 +02:00
package.json feat(init): initial commit 2026-05-11 13:43:56 +02:00
pyproject.toml fix(bugs): lets see if this builds 2026-07-19 19:43:32 +02:00
pytest.ini feat(initial): first commit. main app structure 2026-05-11 15:31:03 +02:00
README.md feat(initial): first commit. main app structure 2026-05-11 15:31:03 +02:00
uv.lock chore(cleanup): random cleanup. big change is language routing works now 2026-07-12 18:02:59 +02:00

Virtual Attorney

✏️ Develop

To begin you should have the following applications installed on your local development system:

💪 Setup Manually

1. Get the project

First clone the repository from Github and switch to the new directory:

    $ git clone git@github.com:caktus/virtual_attorney.git
    $ cd virtual_attorney

2. Set up virtual environment

Next, set up your virtual environment with python3. For example, virtual_attorney.

You will note the distinct lack of opinion on how you should manage your virtual environment. This is by design.

3. Install dependencies

nvm is preferred for managing Node versions and .nvmrc contains the specific Node version for this project. To install the correct (and latest) Node version run:

    (virtual_attorney)$ nvm install

Now install the project Node packages with npm:

    (virtual_attorney)$ npm install

Install Python dependencies with:

    (virtual_attorney)$ just setup

NOTE: This project uses uv for Python dependency management. To update dependencies:

    (virtual_attorney)$ just update-requirements

To add or modify dependencies, edit the pyproject.toml file and run just update-requirements.

4. Pre-commit

pre-commit is used to enforce a variety of community standards. CI runs it, so it's useful to setup the pre-commit hook to catch any issues before pushing to GitHub and reset your pre-commit cache to make sure that you're starting fresh.

To install, run:

    (virtual_attorney)$ pre-commit clean
    (virtual_attorney)$ pre-commit install

5. Set up local env variables

Next, we'll set up our local environment variables. We use django-dotenv to automatically read environment variables located in a file named .env in the top level directory of the project (but you may use any other way of setting environment variables, like direnv or manually setting them). The only variable we need to start is DJANGO_SETTINGS_MODULE:

    (virtual_attorney)$ cp virtual_attorney/settings/local.example.py virtual_attorney/settings/local.py
    (virtual_attorney)$ echo "DJANGO_SETTINGS_MODULE=virtual_attorney.settings.local" > .env

6. Database

The setup for local development assumes that you will be working with dockerized services.

First add the following line to your .env file:

(virtual_attorney)$ echo "DATABASE_URL=postgres://postgres@127.0.0.1:5435/virtual_attorney" >> .env

The docker-compose.yml sets up environment variables in a file, .postgres. To use the Docker setup, add these lines to that file:

    POSTGRES_DB=virtual_attorney
    POSTGRES_HOST_AUTH_METHOD=trust

If you want to connect to the database from your host machine, export the following shell environment variables:

    export PGHOST=127.0.0.1
    export PGPORT=5435
    export PGUSER=postgres
    export PGDATABASE=virtual_attorney

7. Migrate and create a superuser

    (virtual_attorney)$ docker-compose up -d
    (virtual_attorney)$ just migrate
    (virtual_attorney)$ just createsuperuser

8. Run the server

    (virtual_attorney)$ just run-dev

After initial setup the development server should be run using just run-dev this will remove any deployment containers hanging around and setup using local sources and database.

9. Access the server

The Django admin is at /admin and the Wagtail admin is at /cms.

10. Run tests

virtual_attorney uses pytest as a test runner.

    (virtual_attorney)$ just run-tests