Skip to content

Teamdur/DeviceManager

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

86 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

DeviceManager

Development Setup

Prerequisites

Mise installation

The latest mise installation can be found at the official mise website

For short version, you can run the following commands:

$ curl https://mise.run | sh
$ echo 'export PATH="$HOME/.mise/bin:$PATH"' >> ~/.bashrc; echo 'export PATH="$HOME/.mise/bin:$PATH"' >> ~/.zshrc

Restart your terminal

  • Restart Bash
$ exec bash
  • Restart Zsh
$ exec zsh

Verify the installation by running the following command:

$ mise version
2024.4.5 linux-arm64 (d60d850 2024-04-15)

System dependencies

  • Debian/Ubuntu
sudo apt install build-essential gdb lcov pkg-config \
      libbz2-dev libffi-dev libgdbm-dev libgdbm-compat-dev liblzma-dev \
      libncurses5-dev libreadline6-dev libsqlite3-dev libssl-dev \
      lzma lzma-dev tk-dev uuid-dev zlib1g-dev libmariadb-dev

Up-to-date dependencies can be found at python developer's guide

Setting up the project

  1. Clone the repository
$ git clone https://github.com/Teamdur/DeviceManager.git
  1. Change directory to the project
$ cd DeviceManager
  1. Initialize mise
$ mise trust
$ mise settings set experimental true
$ mise install
  1. Run setup task
$ mise run setup-dev
  1. Run the development server
$ mise run dev

Production setup

App environment variables

The following environment variables are required to run the app in production:

  • SECRET_KEY: A secret key for the app
  • MARIADB_USER: The database user
  • MARIADB_PASSWORD: The database password
  • MARIADB_DATABASE: The database host
  • MARIADB_HOST: The database host address
  • MARIADB_PORT: The database port

For email sending, the following environment variables are required:

  • EMAIL_BACKEND should be set to django.core.mail.backends.smtp.EmailBackend
  • EMAIL_HOST: The email host
  • EMAIL_PORT: The email port
  • EMAIL_HOST_USER: The email host user
  • EMAIL_HOST_PASSWORD: The email host password
  • EMAIL_USE_SSL: Should be set to True if the email host uses SSL
  • EMAIL_USE_TLS: Should be set to True if the email host uses TLS

For OIDC Authentication, the following environment variables should be provided however default values are provided:

  • GOOGLE_CLIENT_ID: The Google client ID
  • GOOGLE_CLIENT_SECRET: The Google client secret
  • GITHUB_CLIENT_ID: The Github client ID
  • GITHUB_CLIENT_SECRET: The Github client secret
  • AUTHENTIK_CLIENT_ID: The Authentik client ID
  • AUTHENTIK_CLIENT_SECRET: The Authentik client secret

About

Device Manager web application

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages