acnl

Animal Crossing New Leaf themed Django learning project

Active Pure Nim score 65/100 · last commit 2026-08-17 · 1 stars · tests present · no docs generated

Summary

Latest Version Unknown
License Unknown
CI Status Failing
Stars 1
Forks 0
Open Issues 0
Last Commit 2026-08-17
Downloads 0
Last Indexed 2026-09-06 07:40

Installation

nimble install acnl
choosenim install acnl
git clone https://gitlab.com/alexmitroff/acnl

OS Compatibility

Platform Linux macOS Windows FreeBSD OpenBSD NetBSD Android iOS WASM Embedded
acnl - - - - - - -

Source

Repository https://gitlab.com/alexmitroff/acnl
Homepage https://gitlab.com/alexmitroff/acnl
Registry Source gitlab

README

Animal Crossing New Leaf Encyclopedia

This is simple django project which I use to learn markup, caching, REST & etc.

Table of content - Animal Crossing New Leaf Encyclopedia - Local deploy without docker - Create python env and clone project - Restore database from sql backup - Install requirements, compile styles and run development server - Local deploy with docker compose - Restore database from sql backup - Run development server - Run production server

Local deploy without docker

Create python env and clone project

python3.x -m venv .acnl
source .acnl/bin/activate

git clone git@gitlab.com:alexmitroff/acnl.git

Restore database from sql backup

terminal:

# Install postgres any way you wanted
# log in as postgres user
su - postgres
# enter the postgres shell
psql
# in postgres shell:
CREATE DATABASE acnl_db;
CREATE USER acnl WITH PASSWORD 'password1234';
GRANT ALL PRIVILEGES ON DATABASE acnl_db TO acnl;
ALTER DATABASE acnl_db OWNER TO acnl;
\q # or Ctrl+d
# restore from sql file
psql acnl < ./acnl/database.sql

settings.py:

DATABASES = {
    'default': {
        'ENGINE': 'django.db.backends.postgresql',
        'NAME': 'acnl_db',
        'USER': 'acnl',
        'PASSWORD': 'password1234',
        'HOST': 'localhost',
        'PORT': '',
        }
}

Install requirements, compile styles and run development server

cd acnl
pip install -r requirements.txt

# We need to generate CSS
python manage.py compilesass # it will generate /static/css/acnl.gen.css (minimized)
python manage.py runserver 0.0.0.0:8000

Local deploy with docker compose

Restore database from sql backup

part of docker-compose:

services:
  postgres:
    image: "postgres:11"
    container_name: "acnl_postgres"
    ports:
      - "54320:5432"
    volumes:
      - "dbdata:/var/lib/postgresql/data"

volumes:
  dbdata:

terminal:

docker-compose -f local.yml up
# enter the postgres shell
docker exec -it acnl_postgres psql -U postgres

# in postgres shell:
CREATE DATABASE acnl_db;
CREATE USER acnl WITH PASSWORD 'password1234';
GRANT ALL PRIVILEGES ON DATABASE acnl_db TO acnl;
ALTER DATABASE acnl_db OWNER TO acnl;
\q # or Ctrl+d

# restore from sql file
cat ./database.sql | docker exec -i acnl_postgres psql -U acnl -d acnl_db
docker-compose down

settings.py:

DATABASES = {
    'default': {
        'ENGINE': 'django.db.backends.postgresql',
        'NAME': 'acnl_db',
        'USER': 'acnl',
        'PASSWORD': 'password1234',
        'HOST': 'postgres',
        'PORT': '5432',
        }
}

Run development server

docker compose -f local.yml up

Run production server

Specify acnl/settings/prod.py:

from acnl.settings.base import *

DEBUG = False

ALLOWED_HOSTS = ['mydomain.here']

DATABASES = {
    'default': {
        'ENGINE': 'django.db.backends.postgresql',
        'NAME': 'acnl_db',
        'USER': 'acnl',
        'PASSWORD': 'password1234',
        'HOST': 'postgres',
        'PORT': '5432',
        }
}

STATIC_ROOT = "/var/www/django/acnl/static"
MEDIA_ROOT = "/var/www/django/acnl/media"
docker compose -f prodaction.yaml up