mirror of
https://github.com/inventree/InvenTree
synced 2024-08-30 18:33:04 +00:00
Installer CLI fix (#6049)
* Update heroku procfile - Fix command to run on ubuntu 20.04 - Add "invoke" command (duplicate of "cli") * Update docs for installer * Fix typo * Update root_commands.sh
This commit is contained in:
parent
ca909f9d5a
commit
5b5df279c0
7
Procfile
7
Procfile
@ -1,3 +1,8 @@
|
|||||||
|
# Web process: gunicorn
|
||||||
web: env/bin/gunicorn --chdir $APP_HOME/InvenTree -c InvenTree/gunicorn.conf.py InvenTree.wsgi -b 0.0.0.0:$PORT
|
web: env/bin/gunicorn --chdir $APP_HOME/InvenTree -c InvenTree/gunicorn.conf.py InvenTree.wsgi -b 0.0.0.0:$PORT
|
||||||
|
# Worker process: qcluster
|
||||||
worker: env/bin/python InvenTree/manage.py qcluster
|
worker: env/bin/python InvenTree/manage.py qcluster
|
||||||
cli: echo "" && . env/bin/activate && exec env/bin/python -m invoke
|
# Invoke commands
|
||||||
|
invoke: echo "" | echo "" && . env/bin/activate && invoke
|
||||||
|
# CLI: Provided for backwards compatibility
|
||||||
|
cli: echo "" | echo "" && . env/bin/activate && invoke
|
||||||
|
@ -111,7 +111,7 @@ root_command() {
|
|||||||
done
|
done
|
||||||
|
|
||||||
if [[ $NEEDS_LIBSSL1_1 == "true" ]]; then
|
if [[ $NEEDS_LIBSSL1_1 == "true" ]]; then
|
||||||
echo "### Pathching for libssl1.1"
|
echo "### Installing libssl1.1"
|
||||||
|
|
||||||
echo "deb http://security.ubuntu.com/ubuntu focal-security main" | sudo tee /etc/apt/sources.list.d/focal-security.list
|
echo "deb http://security.ubuntu.com/ubuntu focal-security main" | sudo tee /etc/apt/sources.list.d/focal-security.list
|
||||||
do_call "sudo apt-get update"
|
do_call "sudo apt-get update"
|
||||||
@ -120,7 +120,7 @@ root_command() {
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
echo "### Getting and adding key"
|
echo "### Getting and adding key"
|
||||||
curl -fsSL https://dl.packager.io/srv/$publisher/InvenTree/key | gpg --dearmor | tee /etc/apt/trusted.gpg.d/pkgr-inventree.gpg> /dev/null
|
curl -fsSL https://dl.packager.io/srv/$publisher/InvenTree/key | gpg --dearmor | tee /etc/apt/trusted.gpg.d/pkgr-inventree.gpg > /dev/null
|
||||||
echo "### Adding package source"
|
echo "### Adding package source"
|
||||||
SOURCE_URL="deb [signed-by=/etc/apt/trusted.gpg.d/pkgr-inventree.gpg] https://dl.packager.io/srv/deb/$publisher/InvenTree/$source_url/$DIST_OS $DIST_VER main"
|
SOURCE_URL="deb [signed-by=/etc/apt/trusted.gpg.d/pkgr-inventree.gpg] https://dl.packager.io/srv/deb/$publisher/InvenTree/$source_url/$DIST_OS $DIST_VER main"
|
||||||
echo "$SOURCE_URL" | tee /etc/apt/sources.list.d/inventree.list > /dev/null
|
echo "$SOURCE_URL" | tee /etc/apt/sources.list.d/inventree.list > /dev/null
|
||||||
|
@ -101,7 +101,7 @@ for pkg in $REQS; do
|
|||||||
done
|
done
|
||||||
|
|
||||||
if [[ $NEEDS_LIBSSL1_1 == "true" ]]; then
|
if [[ $NEEDS_LIBSSL1_1 == "true" ]]; then
|
||||||
echo "### Pathching for libssl1.1"
|
echo "### Installing libssl1.1"
|
||||||
|
|
||||||
echo "deb http://security.ubuntu.com/ubuntu focal-security main" | sudo tee /etc/apt/sources.list.d/focal-security.list
|
echo "deb http://security.ubuntu.com/ubuntu focal-security main" | sudo tee /etc/apt/sources.list.d/focal-security.list
|
||||||
do_call "sudo apt-get update"
|
do_call "sudo apt-get update"
|
||||||
@ -110,7 +110,7 @@ if [[ $NEEDS_LIBSSL1_1 == "true" ]]; then
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
echo "### Getting and adding key"
|
echo "### Getting and adding key"
|
||||||
curl -fsSL https://dl.packager.io/srv/$publisher/InvenTree/key | gpg --dearmor | tee /etc/apt/trusted.gpg.d/pkgr-inventree.gpg> /dev/null
|
curl -fsSL https://dl.packager.io/srv/$publisher/InvenTree/key | gpg --dearmor | tee /etc/apt/trusted.gpg.d/pkgr-inventree.gpg > /dev/null
|
||||||
echo "### Adding package source"
|
echo "### Adding package source"
|
||||||
SOURCE_URL="deb [signed-by=/etc/apt/trusted.gpg.d/pkgr-inventree.gpg] https://dl.packager.io/srv/deb/$publisher/InvenTree/$source_url/$DIST_OS $DIST_VER main"
|
SOURCE_URL="deb [signed-by=/etc/apt/trusted.gpg.d/pkgr-inventree.gpg] https://dl.packager.io/srv/deb/$publisher/InvenTree/$source_url/$DIST_OS $DIST_VER main"
|
||||||
echo "$SOURCE_URL" | tee /etc/apt/sources.list.d/inventree.list > /dev/null
|
echo "$SOURCE_URL" | tee /etc/apt/sources.list.d/inventree.list > /dev/null
|
||||||
|
@ -151,6 +151,20 @@ inventree config
|
|||||||
All CLI settings are lost when the package is uninstalled.
|
All CLI settings are lost when the package is uninstalled.
|
||||||
Use the config file where possible as it is kept on uninstall and can easily be synced across instances. Environment variables are a good place for passwords (but not the secret_key).
|
Use the config file where possible as it is kept on uninstall and can easily be synced across instances. Environment variables are a good place for passwords (but not the secret_key).
|
||||||
|
|
||||||
|
### Invoke
|
||||||
|
|
||||||
|
Many InvenTree administration operations run using the `invoke` tool. When installed via the package installer, these commands can be called as follows:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
inventree run invoke <command>
|
||||||
|
```
|
||||||
|
|
||||||
|
For example, to print InvenTree version information:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
inventree run invoke version
|
||||||
|
```
|
||||||
|
|
||||||
## Architecture
|
## Architecture
|
||||||
|
|
||||||
The packages are provided by [packager.io](https://packager.io/). They are built each time updates are pushed to GitHub and released about 10 minutes later. The local package index must be updated to see the new release in the package manager.
|
The packages are provided by [packager.io](https://packager.io/). They are built each time updates are pushed to GitHub and released about 10 minutes later. The local package index must be updated to see the new release in the package manager.
|
||||||
|
Loading…
Reference in New Issue
Block a user