Merge branch 'master' of https://github.com/inventree/inventree-docs into mfa
27
.github/workflows/check_config.yaml
vendored
Normal file
@ -0,0 +1,27 @@
|
||||
name: Config Checks
|
||||
|
||||
on:
|
||||
push:
|
||||
branches-ignore:
|
||||
- l10*
|
||||
|
||||
pull_request:
|
||||
branches-ignore:
|
||||
- l10*
|
||||
|
||||
jobs:
|
||||
|
||||
mkdocs:
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
- name: Checkout Code
|
||||
uses: actions/checkout@v2
|
||||
- name: Setup Python
|
||||
uses: actions/setup-python@v2
|
||||
with:
|
||||
python-version: 3.7
|
||||
- name: Run Checks
|
||||
run: |
|
||||
pip install pyyaml
|
||||
python ci/check_mkdocs_config.py
|
@ -68,19 +68,6 @@ currencies:
|
||||
|
||||
# Email backend configuration
|
||||
# Ref: https://docs.djangoproject.com/en/dev/topics/email/
|
||||
# Available options:
|
||||
# host: Email server host address
|
||||
# port: Email port
|
||||
# username: Account username
|
||||
# password: Account password
|
||||
# prefix: Email subject prefix
|
||||
# tls: Enable TLS support
|
||||
# ssl: Enable SSL support
|
||||
|
||||
# Alternatively, these options can all be set using environment variables,
|
||||
# with the INVENTREE_EMAIL_ prefix:
|
||||
# e.g. INVENTREE_EMAIL_HOST / INVENTREE_EMAIL_PORT / INVENTREE_EMAIL_USERNAME
|
||||
# Refer to the InvenTree documentation for more information
|
||||
|
||||
email:
|
||||
# backend: 'django.core.mail.backends.smtp.EmailBackend'
|
||||
@ -96,33 +83,11 @@ email:
|
||||
# Use the environment variable INVENTREE_DEBUG
|
||||
debug: True
|
||||
|
||||
# Set debug_toolbar to True to enable a debugging toolbar for InvenTree
|
||||
# Note: This will only be displayed if DEBUG mode is enabled,
|
||||
# and only if InvenTree is accessed from a local IP (127.0.0.1)
|
||||
debug_toolbar: False
|
||||
|
||||
# Configure the system logging level
|
||||
# Use environment variable INVENTREE_LOG_LEVEL
|
||||
# Options: DEBUG / INFO / WARNING / ERROR / CRITICAL
|
||||
log_level: WARNING
|
||||
|
||||
# Allowed hosts (see ALLOWED_HOSTS in Django settings documentation)
|
||||
# A list of strings representing the host/domain names that this Django site can serve.
|
||||
# Default behaviour is to allow all hosts (THIS IS NOT SECURE!)
|
||||
allowed_hosts:
|
||||
- '*'
|
||||
|
||||
# Cross Origin Resource Sharing (CORS) settings (see https://github.com/ottoyiu/django-cors-headers)
|
||||
# Following parameters are
|
||||
cors:
|
||||
# CORS_ORIGIN_ALLOW_ALL - If True, the whitelist will not be used and all origins will be accepted.
|
||||
allow_all: True
|
||||
|
||||
# CORS_ORIGIN_WHITELIST - A list of origins that are authorized to make cross-site HTTP requests. Defaults to []
|
||||
# whitelist:
|
||||
# - https://example.com
|
||||
# - https://sub.example.com
|
||||
|
||||
# MEDIA_ROOT is the local filesystem location for storing uploaded files
|
||||
# By default, it is stored under /home/inventree/data/media
|
||||
# Use environment variable INVENTREE_MEDIA_ROOT
|
||||
@ -132,28 +97,3 @@ media_root: '/home/inventree/data/media'
|
||||
# By default, it is stored under /home/inventree/data/static
|
||||
# Use environment variable INVENTREE_STATIC_ROOT
|
||||
static_root: '/home/inventree/data/static'
|
||||
|
||||
# Optional URL schemes to allow in URL fields
|
||||
# By default, only the following schemes are allowed: ['http', 'https', 'ftp', 'ftps']
|
||||
# Uncomment the lines below to allow extra schemes
|
||||
#extra_url_schemes:
|
||||
# - mailto
|
||||
# - git
|
||||
# - ssh
|
||||
|
||||
# Permit custom authentication backends
|
||||
#authentication_backends:
|
||||
# - 'django.contrib.auth.backends.ModelBackend'
|
||||
|
||||
# Custom middleware, sometimes needed alongside an authentication backend change.
|
||||
#middleware:
|
||||
# - 'django.middleware.security.SecurityMiddleware'
|
||||
# - 'django.contrib.sessions.middleware.SessionMiddleware'
|
||||
# - 'django.middleware.locale.LocaleMiddleware'
|
||||
# - 'django.middleware.common.CommonMiddleware'
|
||||
# - 'django.middleware.csrf.CsrfViewMiddleware'
|
||||
# - 'corsheaders.middleware.CorsMiddleware'
|
||||
# - 'django.contrib.auth.middleware.AuthenticationMiddleware'
|
||||
# - 'django.contrib.messages.middleware.MessageMiddleware'
|
||||
# - 'django.middleware.clickjacking.XFrameOptionsMiddleware'
|
||||
# - 'InvenTree.middleware.AuthRequiredMiddleware'
|
||||
|
@ -25,18 +25,21 @@
|
||||
<a href="features" title="InvenTree features" class="md-button md-button">
|
||||
<span class='fas fa-star'></span> Features
|
||||
</a>
|
||||
<a href="demo" title="InvenTree demo" class='md-button'>
|
||||
<span class='fas fa-desktop'></span> Demo
|
||||
</a>
|
||||
<a href="start/intro" title="Install InvenTree" class="md-button md-button">
|
||||
<span class='fas fa-server'></span> Install
|
||||
</a>
|
||||
<a href="https://github.com/inventree/inventree" title="Explore InvenTree source code" class="md-button md-button">
|
||||
<span class='fab fa-github'></span> Source Code
|
||||
</a>
|
||||
<a href="app/app" title="InvenTree mobile app" class="md-button">
|
||||
<span class='fas fa-mobile-alt'></span> Get the App
|
||||
<span class='fas fa-mobile-alt'></span> Mobile App
|
||||
</a>
|
||||
<a href="https://crowdin.com/project/inventree" title="Help translate InvenTree" class="md-button">
|
||||
<span class='fas fa-language'></span> Translate
|
||||
</a>
|
||||
<a href="https://github.com/inventree/inventree" title="Explore InvenTree source code" class="md-button md-button">
|
||||
<span class='fab fa-github'></span> Source Code
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
13
ci/check_mkdocs_config.py
Normal file
@ -0,0 +1,13 @@
|
||||
import os
|
||||
import yaml
|
||||
|
||||
here = os.path.dirname(__file__)
|
||||
|
||||
tld = os.path.abspath(os.path.join(here, '..'))
|
||||
|
||||
config_file = os.path.join(tld, 'mkdocs.yml')
|
||||
|
||||
with open(config_file, 'r') as f:
|
||||
data = yaml.safe_load(f)
|
||||
|
||||
assert data['strict'] == True
|
BIN
docs/assets/images/part/cat_subs.png
Normal file
After Width: | Height: | Size: 35 KiB |
BIN
docs/assets/images/part/category_notification.png
Normal file
After Width: | Height: | Size: 12 KiB |
BIN
docs/assets/images/part/part_subscribe_off.png
Normal file
After Width: | Height: | Size: 8.3 KiB |
BIN
docs/assets/images/part/part_subscribe_on.png
Normal file
After Width: | Height: | Size: 8.5 KiB |
BIN
docs/assets/images/report/report.png
Normal file
After Width: | Height: | Size: 16 KiB |
Before Width: | Height: | Size: 19 KiB |
Before Width: | Height: | Size: 19 KiB |
@ -1,10 +1,37 @@
|
||||
---
|
||||
title: Demo Dataset
|
||||
title: InvenTree Demo
|
||||
---
|
||||
|
||||
## InvenTree Demo
|
||||
|
||||
A working demo of InvenTree is available online at:
|
||||
|
||||
<large><b>[https://demo.inventree.org](https://demo.inventree.org)</b></large>
|
||||
|
||||
### Login Details
|
||||
|
||||
Multiple default accounts are provided, as detailed below. Each account is afforded a different set of permissions, so users can see the InvenTree roles/permission system in action
|
||||
|
||||
| Username | Password | Description |
|
||||
| --- | --- | --- |
|
||||
| allacess | nolimits | View / create / edit all pages and items |
|
||||
| reader | readonly | Can view all pages but cannot create, edit or delete database records |
|
||||
| engineer | partsonly | Can manage parts, view stock, but no access to purchase orders or sales orders |
|
||||
| admin | inventree | Superuser account, access all areas plus administrator actions |
|
||||
|
||||
### Data Persistence
|
||||
|
||||
The InvenTree demo database resets to a known state once per day.
|
||||
|
||||
- Database records are reset to the latest state of the [demo dataset](https://github.com/inventree/demo-dataset)
|
||||
- InvenTree software is kept up to date with the latest `inventree:master` available via docker
|
||||
|
||||
!!! warning "Server Down"
|
||||
During the update period, the demo server may be inaccessible for a few minutes.
|
||||
|
||||
## Demo Dataset
|
||||
|
||||
A demonstration dataset is [available on GitHub](https://github.com/inventree/demo-dataset).
|
||||
The dataset used for the demo instance is [available on GitHub](https://github.com/inventree/demo-dataset).
|
||||
|
||||
This dataset can be used to populate an empty database for demonstration purposes, to test and evaluate various InvenTree features.
|
||||
|
||||
@ -13,16 +40,6 @@ It may also be useful to developers who need a dataset for developing and/or tes
|
||||
!!! warning "Empty Database"
|
||||
Loading demo data will cause errors if the database is not empty. Run `invoke delete-data` prior to importing the demo dataset if there are records existing in the database!
|
||||
|
||||
## Login Details
|
||||
|
||||
The default *superuser* login details for the demo dataset are:
|
||||
|
||||
| Username | Password |
|
||||
| --- | --- |
|
||||
| admin | inventree |
|
||||
|
||||
## Setup
|
||||
|
||||
Follow these instructions to setup an InvenTree instance with the demo data:
|
||||
|
||||
### Download Dataset
|
||||
@ -40,7 +57,7 @@ git clone git@github.com:inventree/demo-dataset.git ~/inventree-data
|
||||
|
||||
You will need to configure an *empty* database before importing the data fixtures.
|
||||
|
||||
Follow the [installation instructions](./intro.md) to initialize a database using your backend of choice.
|
||||
Follow the [installation instructions](./start/intro.md) to initialize a database using your backend of choice.
|
||||
|
||||
### Configure InvenTree Settings
|
||||
|
73
docs/part/notification.md
Normal file
@ -0,0 +1,73 @@
|
||||
---
|
||||
title: Part Notifications
|
||||
---
|
||||
|
||||
## Notification Events
|
||||
|
||||
Users can select to receive email notifications when certain events occur.
|
||||
|
||||
!!! warning "Email Configuration Required"
|
||||
Notifications require correct [email configuration](../../start/config/#email-settings)
|
||||
|
||||
!!! warning "Valid Email Address"
|
||||
Each user must have a valid email address associated with their account to receive email notifications
|
||||
|
||||
### Low Stock Notification
|
||||
|
||||
If the *minimum stock* threshold is set for a *Part*, then a "low stock" notification can be generated when the stock level for that part falls below the configured level.
|
||||
|
||||
Any users who are subscribed to notifications for the part in question will receive a low stock notification via email.
|
||||
|
||||
### Build Order Notification
|
||||
|
||||
When a new [Build Order](../../build/build/) is created, the InvenTree software checks to see if any of the parts required to complete the order are low on stock.
|
||||
|
||||
If there are any parts with low stock, a notification is generated for any users subscribed to notifications for the part being built.
|
||||
|
||||
## Subscribing to Notifications
|
||||
|
||||
Users can "subscribe" to either a *Part* or *Part Category*, to receive notifications.
|
||||
|
||||
### Part
|
||||
|
||||
When subscribed to a *Part*, a user will receive notifications when events occur which pertain to:
|
||||
|
||||
- That particular part
|
||||
- Any parts which are variants of that part
|
||||
|
||||
If a user is subscribed to a particular part, it will be indicated as shown below:
|
||||
|
||||
{% with id="part_sub_on", url="part/part_subscribe_on.png", description="Subscribe" %}
|
||||
{% include 'img.html' %}
|
||||
{% endwith %}
|
||||
|
||||
If the user is not subscibed, the subscription icon is greyed out, as shown here:
|
||||
|
||||
{% with id="part_sub_off", url="part/part_subscribe_off.png", description="Subscribe" %}
|
||||
{% include 'img.html' %}
|
||||
{% endwith %}
|
||||
|
||||
Clicking on this icon will toggle the subscription status for this part.
|
||||
|
||||
### Part Category
|
||||
|
||||
When subscribed to a *Part Category*, a user will receive notifications when particular events occur which pertain to:
|
||||
|
||||
- That particular category
|
||||
- Any sub-categories at lower levels
|
||||
- Any parts contained in the category
|
||||
- Any parts contained in the lower level categories
|
||||
|
||||
Subscribing to a part category operates in the same manner as for a part - simply click on the notification icon:
|
||||
|
||||
{% with id="cat_sub", url="part/category_notification.png", description="Subscribe to part category" %}
|
||||
{% include 'img.html' %}
|
||||
{% endwith %}
|
||||
|
||||
## Subscription List
|
||||
|
||||
Users can view the parts and categories they are subscribed to on the InvenTree home page:
|
||||
|
||||
{% with id="cat_subs", url="part/cat_subs.png", description="Category subscription list" %}
|
||||
{% include 'img.html' %}
|
||||
{% endwith %}
|
@ -57,6 +57,9 @@ PR [#2208](https://github.com/inventree/InvenTree/pull/2208) provides notificati
|
||||
### MFA Support
|
||||
|
||||
PR [#2221](https://github.com/inventree/InvenTree/pull/2221) adds support for MFA (multi factor authentication). This enables admins to require all users to enable MFA as a second auth step. Refer to the [documentation](../settings/mfa) for further information.
|
||||
### Stock Item Forms
|
||||
|
||||
PR [#2198](https://github.com/inventree/InvenTree/pull/2198) provides a major refactor of stock item forms, for creating and editing stock items. These forms have been migrated to the REST API, providing a much more responsive user experience.
|
||||
|
||||
## Major Bug Fixes
|
||||
|
||||
|
@ -63,14 +63,19 @@ The django template system allows for conditional rendering, providing condition
|
||||
|
||||
A number of global reporting options are available for customizing InvenTree reports:
|
||||
|
||||
{% with id="report-options", url="report/report.png", description="Report Options" %}
|
||||
{% include 'img.html' %}
|
||||
{% endwith %}
|
||||
|
||||
### Enable Reports
|
||||
|
||||
By default, the reporting feature is turned off. It must be enabled in the global settings.
|
||||
|
||||
|
||||
### Default Page Size
|
||||
|
||||
The built-in InvenTree report templates (and any reports which are derived from the built-in templates) use the *Page Size* option to set the page size of the generated reports.
|
||||
|
||||
{% with id="report_page_size", url="report/report_default_page_size.png", description="Report Page Size" %}
|
||||
{% include 'img.html' %}
|
||||
{% endwith %}
|
||||
|
||||
!!! info "Override Page Size"
|
||||
Custom report templates do not have to make use of the *Page Size* option, although it is made available to the template context.
|
||||
|
||||
@ -80,10 +85,6 @@ As templates are rendered directly to a PDF object, it can be difficult to debug
|
||||
|
||||
Setting the *Debug Mode* option renders the template as raw HTML instead of PDF, allowing the rendering output to be introspected. This feature allows template designers to understand any issues with the generated HTML (before it is passed to the PDF generation engine).
|
||||
|
||||
{% with id="report_debu_mode", url="report/report_debug_mode.png", description="Report Debug Mode" %}
|
||||
{% include 'img.html' %}
|
||||
{% endwith %}
|
||||
|
||||
!!! warning "HTML Rendering Limitations"
|
||||
When rendered in debug mode, @page attributes (such as size, etc) will **not** be observed. Additionally, any asset files stored on the InvenTree server will not be rendered. Debug mode is not intended to produce "good looking" documents!
|
||||
|
||||
|
@ -19,7 +19,7 @@ The default InvenTree config file is located at `./InvenTree/config.yaml`
|
||||
|
||||
However, the config file can be placed elsewhere, and specified with the `INVENTREE_CONFIG_FILE` environment variable.
|
||||
|
||||
The default configuration file file is shown below:
|
||||
A short snippet from an example configuration file file is shown below. The entire default configuration file can be found on [GitHub](https://github.com/inventree/InvenTree/blob/master/InvenTree/config_template.yaml)
|
||||
|
||||
``` yaml
|
||||
{% include 'config.yaml' %}
|
||||
@ -32,10 +32,10 @@ In addition to specifying InvenTree options via the `config.yaml` file, these op
|
||||
- Environment variable settings use the `INVENTREE_` prefix, and are all uppercase.
|
||||
- Config file settings do not use this prefix, and are all lowercase
|
||||
|
||||
!!! info Priotity
|
||||
!!! info "Configuration Priority"
|
||||
Configuration options set via environment variables will take priority over the values set in the `config.yaml` file.
|
||||
|
||||
!!! warning Available Variables
|
||||
!!! warning "Available Variables"
|
||||
Some configuration options cannot be set via environment variables. Refer to the documentation below.
|
||||
|
||||
## Basic Options
|
||||
@ -101,7 +101,13 @@ The following email settings are available:
|
||||
|
||||
## Allowed Hosts / CORS
|
||||
|
||||
By default, all hosts are allowed, and CORS requests are enabled from any origin. **This is not secure and should be adjusted for your installation**. These options can be changed in the configuration file.
|
||||
By default, all hosts are allowed, and CORS requests are enabled from any origin.
|
||||
|
||||
!!! danger "Not Secure"
|
||||
Allowing access from any host is not secure, and should be adjusted for your installation.
|
||||
|
||||
!!! info "Configuration File"
|
||||
Allowed hosts and CORS options must be changed in the configuration file, and cannot be set via environment variables
|
||||
|
||||
For further information, refer to the following documentation:
|
||||
|
||||
@ -124,13 +130,15 @@ Alternatively this location can be specified with the `INVENTREE_MEDIA_ROOT` env
|
||||
|
||||
## Authentication
|
||||
|
||||
InvenTree provides allowance for additional sign-in options. The following options are not enabled by default, and care must be taken by the system administrator when configuring these settings.
|
||||
|
||||
### Single Sign on
|
||||
|
||||
SSO backends for all wanted providers need to be added to the config file as a list under the key `social_backends`. The correct backend-name can be found in django-allauths [configuration documentation](https://django-allauth.readthedocs.io/en/latest/installation.html#django).
|
||||
SSO backends for all required authentication providers need to be added to the config file as a list under the key `social_backends`. The correct backend-name can be found in django-allauths [configuration documentation](https://django-allauth.readthedocs.io/en/latest/installation.html#django).
|
||||
|
||||
If the selected providers need additional settings they must be added as dicts under the key `social_providers`. The correct settings can be found in the django-allauths [provider documentation](https://django-allauth.readthedocs.io/en/latest/providers.html).
|
||||
|
||||
!!! note "You are not done"
|
||||
!!! warning "You are not done"
|
||||
SSO still needs credentials for all providers and has to be enabled in the [global settings](../settings/global.md)!
|
||||
|
||||
|
||||
|
@ -17,7 +17,7 @@ InvenTree includes a simple server application, suitable for use in a developmen
|
||||
To run the development server on a local machine, run the command:
|
||||
|
||||
```
|
||||
(env) inv server
|
||||
(env) invoke server
|
||||
```
|
||||
|
||||
This will launch the InvenTree web interface at `http://127.0.0.1:8000`.
|
||||
@ -25,7 +25,7 @@ This will launch the InvenTree web interface at `http://127.0.0.1:8000`.
|
||||
A different port can be specified using the `-a` flag:
|
||||
|
||||
```
|
||||
(env) inv server -a 127.0.0.1:8123
|
||||
(env) invoke server -a 127.0.0.1:8123
|
||||
```
|
||||
|
||||
Serving on the address `127.0.0.1` means that InvenTree will only be available *on that computer*. The server will be accessible from a web browser on the same computer, but not from any other computers on the local network.
|
||||
@ -35,7 +35,7 @@ Serving on the address `127.0.0.1` means that InvenTree will only be available *
|
||||
To enable access to the InvenTree server from other computers on a local network, you need to know the IP of the computer running the server. For example, if the server IP address is `192.168.120.1`:
|
||||
|
||||
```
|
||||
(env) inv server -a 192.168.120.1:8000
|
||||
(env) invoke server -a 192.168.120.1:8000
|
||||
```
|
||||
|
||||
## Background Worker
|
||||
|
@ -12,14 +12,17 @@ The InvenTree docker image contains all the required system packages, python mod
|
||||
|
||||
Docker images are available with the following tags:
|
||||
|
||||
- **inventree:stable** - represents the most recent stable release version of InvenTree
|
||||
- **inventree:latest** - represents the most up-to-date *development* version of InvenTree.
|
||||
- **inventree:tag** - specific tagged images are built for each tagged release of InvenTree
|
||||
| Tag | Description |
|
||||
| --- | --- |
|
||||
| **inventree:stable** | The most recent *stable* release version of InvenTree |
|
||||
| **inventree:latest** | The most up-to-date *development* version of InvenTree. |
|
||||
| **inventree:tag** | Specific tagged images are built for each tagged release of InvenTree |
|
||||
|
||||
### Docker Compose
|
||||
|
||||
InvenTree provides sample docker-compose files to get you up and running.
|
||||
|
||||
| Compose File | Target | Description |
|
||||
- A *production* compose file is intended to be used in a production environment, running the web server behind a nginx proxy.
|
||||
- A *development* compose file provides a simple way to spin up a development environment
|
||||
|
||||
|
@ -13,8 +13,13 @@ Using the [InvenTree docker image](./docker.md) streamlines the setup process fo
|
||||
|
||||
It is strongly recommended that you use a [docker-compose](https://docs.docker.com/compose/) script to manage your InvenTree docker image.
|
||||
|
||||
### Example Script
|
||||
|
||||
An example docker compose file can be [found here](https://github.com/inventree/InvenTree/blob/master/docker/docker-compose.yml) - the documentation below will be using this docker compose file.
|
||||
|
||||
!!! info "Stable Version"
|
||||
The example docker-compose file targets `inventree:stable` docker image by default
|
||||
|
||||
### Containers
|
||||
|
||||
The example docker-compose file launches the following containers:
|
||||
@ -46,9 +51,10 @@ Nginx working as a reverse proxy, separating requests for static and media files
|
||||
|
||||
This container uses the official [nginx image](https://hub.docker.com/_/nginx).
|
||||
|
||||
An nginx configuration file must be provided to the image. Use the [example configuration file](https://github.com/inventree/InvenTree/blob/master/docker/nginx.conf) as a starting point.
|
||||
!!! info "Configuration File"
|
||||
An nginx configuration file must be provided to the image. Use the [example configuration file](https://github.com/inventree/InvenTree/blob/master/docker/nginx.conf) as a starting point.
|
||||
|
||||
*__Note__: You must save this conf file in the same directory as your docker-compose.yml file*
|
||||
*__Note__: You must save the `nginx.conf` file in the same directory as your docker-compose.yml file*
|
||||
|
||||
!!! info "Proxy Pass"
|
||||
If you change the name (or port) of the InvenTree web server container, you will need to also adjust the `proxy_pass` setting in the nginx.conf file!
|
||||
|
@ -63,6 +63,9 @@ Download InvenTree source code, into the `./src` directory:
|
||||
git clone https://github.com/inventree/inventree src
|
||||
```
|
||||
|
||||
!!! info "Main Branch = Development"
|
||||
The "main" branch of the InvenTree code base represents the "latest" (development) code. If you would like to use most recent "stable" release, target the `stable` branch.
|
||||
|
||||
### Create Virtual Environment
|
||||
|
||||
Create a python virtual environment for installing required Python packages and binaries:
|
||||
@ -89,24 +92,6 @@ This installs all required Python packages using pip package manager. It also cr
|
||||
|
||||
As part of the initial setup, an empty database needs to be created. Follow the instructions below particular to your database engine of choice:
|
||||
|
||||
### SQLite
|
||||
|
||||
SQLite uses a simple portable database file which is easy to use for debug and testing purposes.
|
||||
|
||||
Install required packages as follows:
|
||||
|
||||
!!! info "Sudo Actions"
|
||||
Perform sudo actions from a separate shell, as 'inventree' user does not have sudo access
|
||||
|
||||
```
|
||||
sudo apt-get install sqlite3
|
||||
```
|
||||
|
||||
A `.sqlite3` database file will be automatically created, at the location specified in the configuration options. No further steps necessary.
|
||||
|
||||
!!! warning "SQLite Case Sensitivity"
|
||||
SQLite has a known [string matching limitation](https://docs.djangoproject.com/en/dev/ref/databases/#substring-matching-and-case-sensitivity) for non ASCII characters. If you are using non ASCII characters (e.g. Cyrillic text), it is recommended that you do not use SQLite, as search functionality will not work correctly.
|
||||
|
||||
### PostgreSQL
|
||||
|
||||
#### Install PostgreSQL
|
||||
@ -205,6 +190,24 @@ mysql> EXIT;
|
||||
!!! info "Username / Password"
|
||||
You should change the username and password from the values specified above. This username and password will also be for the InvenTree database connection configuration.
|
||||
|
||||
### SQLite
|
||||
|
||||
SQLite uses a simple portable database file which is easy to use for debug and testing purposes.
|
||||
|
||||
Install required packages as follows:
|
||||
|
||||
!!! info "Sudo Actions"
|
||||
Perform sudo actions from a separate shell, as 'inventree' user does not have sudo access
|
||||
|
||||
```
|
||||
sudo apt-get install sqlite3
|
||||
```
|
||||
|
||||
A `.sqlite3` database file will be automatically created, at the location specified in the configuration options. No further steps necessary.
|
||||
|
||||
!!! warning "SQLite Case Sensitivity"
|
||||
SQLite has a known [string matching limitation](https://docs.djangoproject.com/en/dev/ref/databases/#substring-matching-and-case-sensitivity) for non ASCII characters. If you are using non ASCII characters (e.g. Cyrillic text), it is recommended that you do not use SQLite, as search functionality will not work correctly.
|
||||
|
||||
## Configure InvenTree Options
|
||||
|
||||
Once the required software packages are installed and the database has been created, the InvenTree server options must be configured.
|
||||
|
@ -10,14 +10,14 @@ The InvenTree server ecosystem consists of the following components:
|
||||
|
||||
### Database
|
||||
|
||||
A persistent database is required to store stock information. The database backend must be installed and configured separately to the InvenTree application.
|
||||
A persistent database is required for data storage. InvenTree can be used with any of the following database backends:
|
||||
|
||||
InvenTree can be used with any of the following database backends:
|
||||
|
||||
* SQLite
|
||||
* PostgreSQL
|
||||
* MariaDB
|
||||
* MySQL
|
||||
* MySQL / MariaDB
|
||||
* SQLite
|
||||
|
||||
!!! warning "SQLite"
|
||||
While SQLite provides a simpler setup and is useful for a development environment, we strongly recommend against using it for a production environment. Use PostgreSQL or MySQL instead
|
||||
|
||||
Database selection should be determined by your particular installation requirements.
|
||||
|
||||
@ -44,6 +44,9 @@ The InvenTree documentation assumes that the operating system is a debian based
|
||||
!!! warning "Installing on Windows"
|
||||
Installation on Windows is *not guaranteed* to work (at all). To install on a Windows system, it is highly recommended that you [install WSL](https://docs.microsoft.com/en-us/windows/wsl/install-win10#manual-installation-steps), and then follow installation procedure from within the WSL environment.
|
||||
|
||||
!!! success "Docker"
|
||||
Installation on any OS is simplified by following the [docker setup guide](../docker).
|
||||
|
||||
## Python Requirements
|
||||
|
||||
InvenTree runs on [Python](https://python.org).
|
||||
|
@ -19,7 +19,7 @@ For example, if you wish to migrate from an SQLite database backend to a MySQL d
|
||||
Export the database contents to a JSON file using the following command:
|
||||
|
||||
```
|
||||
inv export-records -f data.json
|
||||
invoke export-records -f data.json
|
||||
```
|
||||
|
||||
This will create JSON file at the specified location which contains all database records.
|
||||
@ -34,7 +34,7 @@ Configure the new database using the normal processes (see [Configuration](./con
|
||||
Then, ensure that the database schema are correctly initialized in the new database:
|
||||
|
||||
```
|
||||
inv migrate
|
||||
invoke migrate
|
||||
```
|
||||
|
||||
This ensures that the required database tables exist, which must be the case before data can be imported.
|
||||
@ -47,7 +47,7 @@ The new database should now be correctly initialized with the correct table stru
|
||||
If the database is not *empty* (i.e. it contains data records) then the data import process will fail. If errors occur during the import process, run `invoke delete-data` to clear all existing data from the database.
|
||||
|
||||
```
|
||||
inv import-records -f data.json
|
||||
invoke import-records -f data.json
|
||||
```
|
||||
|
||||
!!! info "Import Filename"
|
||||
|
@ -26,12 +26,15 @@ For example, pull down the latest InvenTree sourcecode using Git:
|
||||
git pull origin master
|
||||
```
|
||||
|
||||
!!! info "Release Versions"
|
||||
If you are using a particular version of InvenTree, you may wish to target a specific code branch or tag, instead of just pulling down latest master
|
||||
|
||||
### Perform Database Migrations
|
||||
|
||||
Updating the database is as simple as calling the `update` script:
|
||||
|
||||
```
|
||||
inv update
|
||||
invoke update
|
||||
```
|
||||
|
||||
This command performs the following steps:
|
||||
|
@ -44,8 +44,9 @@ extra_javascript:
|
||||
nav:
|
||||
- InvenTree:
|
||||
- Features: features.md
|
||||
- In Development: upcoming.md
|
||||
- Release Notes: releases/release_notes.md
|
||||
- Upcoming: upcoming.md
|
||||
- Demo: demo.md
|
||||
- FAQ: faq.md
|
||||
- Contribute: contribute.md
|
||||
- Credits: credits.md
|
||||
@ -56,7 +57,6 @@ nav:
|
||||
- Bare Metal Setup: start/install.md
|
||||
- Updating: start/update.md
|
||||
- Migrating: start/migrate.md
|
||||
- Demo Dataset: start/demo.md
|
||||
- Parts:
|
||||
- Parts: part/part.md
|
||||
- Creating Parts: part/create.md
|
||||
@ -66,6 +66,7 @@ nav:
|
||||
- Templates: part/template.md
|
||||
- Tests: part/test.md
|
||||
- Pricing: part/pricing.md
|
||||
- Notifications: part/notification.md
|
||||
- Stock:
|
||||
- Stock Items: stock/stock.md
|
||||
- Stock Status: stock/status.md
|
||||
|