|
1 year ago | |
---|---|---|
contrib | 1 year ago | |
locale | 1 year ago | |
media | 1 year ago | |
omnomnomnom | 1 year ago | |
shelf | 1 year ago | |
static | 1 year ago | |
.gitignore | 1 year ago | |
LICENSE | 1 year ago | |
README.md | 1 year ago | |
manage.py | 1 year ago | |
requirements.txt | 1 year ago |
Omnomnomnom helps you manage your products and expiry times.
A good point is to install this on a dedicated user, using VirtualEnv too.
sudo su - youruser
cd ~/
git clone https://dev.sigpipe.me/dashie/omnomnomnom
cd omnomnomnom
as root : pip3 install virtualenv
then under the user, youruser:
virtualenv --python=python3 ~/venv/
source ~/venv/bin/activate
source ~/venv/bin/activate
cd ~/omnomnomnom/
pip install -r requirements.txt
cp omnomnomnom/settings.py.sample omnomnomnom/settings.py
$EDITOR omnomnomnom/settings.py
Edit settings.py according to your setup
python manage.py migrate
python manage.py createsuperuser
django-admin compilemessages
as user omnomnomnom
cd omnomnomnom
python managepy collectstatic
pip install gunicorn
cp contrib/gunicorn.conf gunicorn.conf
$EDITOR gunicorn.conf
edit as you wish
as root
mkdir /var/log/omnomnomnom
chown -R omnomnomnom: /var/log/omnomnomnom
apt install supervisor # or whatever package manager you use
cp ~omnomnomnom/omnomnomnom/contrib/omnomnomnom.supervisor.conf /etc/supervisor/conf.d/omnomnomnom.conf
$EDITOR /etc/supervisor/conf.d/omnomnomnom.conf
edit as you wish
then start supervisor using your system, like for debian:
/etc/init.d/supervisor start
view status with:
supervisorctl status
You can setup the crons with:
In file /etc/cron.d/omnomnomnom:
# Reminder every days, for next 3 days
0 1 * * * /home/omnomnomnom/venv/bin/python /home/omnomnomnom/manage.py reminders --email --expires 3
# Reminder every monday, for next 6 days
0 1 * * */1 /home/omnomnomnom/venv/bin/python /home/omnomnomnom/manage.py reminders --email --expires 6
# Reminder every first day of month, for the next 30 days
0 1 * */1 * /home/omnomnomnom/venv/bin/python /home/omnomnomnom/manage.py reminders --email --expires 30
Remember to restart cron daemon after edit of this file
/etc/init.d/crond restart
Omnomnomnom use the MIT license, however we use Django-Suit which is under “Creative Commons Attribution-NonCommercial 3.0” which means you will probably take a look at http://djangosuit.com/pricing/ to get a paid license for it if you use Omnomnomnom in any kind of business.
The Free license of Django-Suit is only applicable for personnal use.