Skip to content

Web application to manage Leihladen, also known as Borrow Stores.

Notifications You must be signed in to change notification settings

ArcoMul/leihbase

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Leihbase

Web application to manage Leihladen, also known as Borrow Stores.

Important

This software is still in active development. It is being used in production for the Leihbar in Cologne, but might be lacking some (for you) critical features.

Features

  • 🏪 A webshop front-end showing borrowable products
  • 🏙️ Manage multiple borrow locations
  • 🏷️ Product category filtering
  • 🧑‍🤝‍🧑 User sign-up/login
  • 🎫 Product reservations

Screenshots

Tech

  • Back-end and API using PocketBase
  • Front-end with server-side rendering using NuxtJS

Deployment

The repository contains fly.toml files to deploy the service as fly.io applications, but can be deployed to any server where Docker containers can run.

Development

Setup

Requirements: Docker

  • $ docker compose build
  • $ docker compose up

Initial content

After starting the service using the setup steps above. Enter some initial data to be able to use the application:

  1. Browse to http://localhost:8080/\_/ to visit the Pocketbase admin interface
  2. Create an admin account
  3. Create a location in the locations collection (make sure to set the location to as 'active')
  4. Create a product in the products collection (make sure to set the product to as 'active')
  5. Now you should be able to visit http://localhost:3000 to visit the front-end

E-mail

When starting the service with docker-compose, a mailhog container starts as well. In Pocketbase (http://localhost:8080/\_/ > Settings > Mail settings) the following SMTP values can be configured:

  • SMTP server host: mailhog
  • Port: 1025
  • Username: <empty>
  • Password: <empty>

Any sent e-mail can then be viewed in the mailhog web interface at http://localhost:8025.

Tests

Tests are configured and run using Playwright.

Setup

  • $ cd tests
  • $ pnpm install
  • pnpm exec playwright install

Run

  • pnpm run test