Skip to content

🐳 Installation (User)

This guide explains how to deploy LibreFolio for regular use using Docker. This is the recommended method for users who do not intend to modify the source code.

βœ… Prerequisites

  • πŸ‹ Docker: Install Docker
  • πŸ”— Docker Compose: Usually included with Docker Desktop.

πŸ“₯ 1. Download the Project

Download the latest release from the GitHub Releases page. Unzip the folder.

Alternatively, you can clone the repository:

git clone https://github.com/ea-enel/LibreFolio.git
cd LibreFolio

βš™οΈ 2. Configure Environment

The project uses a .env file for configuration. A sample file is provided.

  1. Copy the example file:

    cp .env.example .env
    

  2. Edit .env (Optional):

    • πŸ”Œ PORT: Change the port if 8000 is already in use.
    • πŸ“ LIBREFOLIO_DATA_DIR: Change where data is stored (default: ./backend/data/prod).

πŸš€ 3. Run with Docker Compose

This single command will build the images and start the application.

docker-compose up -d
  • πŸ”„ -d runs the application in detached mode (in the background).
  • ⏳ The first time you run this, Docker will download the necessary base images and build the application, which may take a few minutes.

πŸ‘€ 4. Create a Superuser

To log in, you need to create an administrator account. The first user created automatically becomes the superuser.

docker-compose exec backend ./dev.py user create <username> <email> <password>

Replace <username>, <email>, and <password> with your credentials.

🌐 5. Access LibreFolio

The application is now running! Open your browser and go to:

http://localhost:8000

(Or use the port you configured in .env).

πŸ”„ Updating LibreFolio

To update to a new version:

  1. Download the latest code:

    git pull
    

  2. Rebuild and restart the containers:

    docker-compose up -d --build
    

  3. Apply database migrations (if any):

    docker-compose exec backend pipenv run alembic upgrade head