amon
amon copied to clipboard
on premise installation does not work
I have a fresh ubuntu 16.04 installation
i have installed nginx, mongodb and phyton 3.5 (ubuntu shipped) but the manual at https://docs.amon.cx/onpremise/ does not work. i fails at the step: "pip install -r /opt/amon/requirements.tx"
`Collecting greenlet>=0.4.10 (from gevent==1.2.0->-r /opt/amon/requirements.txt (line 18)) Downloading greenlet-0.4.12-cp35-cp35m-manylinux1_x86_64.whl (42kB) 100% |████████████████████████████████| 51kB 10.0MB/s Collecting termcolor (from nose-timer==0.6.0->-r /opt/amon/requirements.txt (line 32)) Downloading termcolor-1.1.0.tar.gz Building wheels for collected packages: django-annoying, django-kronos, django-timezone-field, pycrypto, xmltodict, yanc, nose-exclude, nose-timer, python-crontab, PyYAML, termcolor Running setup.py bdist_wheel for django-annoying ... error Complete output from command /opt/amon/env/bin/python3 -u -c "import setuptools, tokenize;file='/tmp/pip-build-zblw_xwo/django-annoying/setup.py';exec(compile(getattr(tokenize, 'open', open)(file).read().replace('\r\n', '\n'), file, 'exec'))" bdist_wheel -d /tmp/tmp4163ijcgpip-wheel- --python-tag cp35: usage: -c [global_opts] cmd1 [cmd1_opts] [cmd2 [cmd2_opts] ...] or: -c --help [cmd1 cmd2 ...] or: -c --help-commands or: -c cmd --help
error: invalid command 'bdist_wheel'
Failed building wheel for django-annoying Running setup.py clean for django-annoying Running setup.py bdist_wheel for django-kronos ... error Complete output from command /opt/amon/env/bin/python3 -u -c "import setuptools, tokenize;file='/tmp/pip-build-zblw_xwo/django-kronos/setup.py';exec(compile(getattr(tokenize, 'open', open)(file).read().replace('\r\n', '\n'), file, 'exec'))" bdist_wheel -d /tmp/tmpk3_sr_rfpip-wheel- --python-tag cp35: usage: -c [global_opts] cmd1 [cmd1_opts] [cmd2 [cmd2_opts] ...] or: -c --help [cmd1 cmd2 ...] or: -c --help-commands or: -c cmd --help
error: invalid command 'bdist_wheel'
Failed building wheel for django-kronos Running setup.py clean for django-kronos Running setup.py bdist_wheel for django-timezone-field ... error Complete output from command /opt/amon/env/bin/python3 -u -c "import setuptools, tokenize;file='/tmp/pip-build-zblw_xwo/django-timezone-field/setup.py';exec(compile(getattr(tokenize, 'open', open)(file).read().replace('\r\n', '\n'), file, 'exec'))" bdist_wheel -d /tmp/tmprmqebho6pip-wheel- --python-tag cp35: usage: -c [global_opts] cmd1 [cmd1_opts] [cmd2 [cmd2_opts] ...] or: -c --help [cmd1 cmd2 ...] or: -c --help-commands or: -c cmd --help
error: invalid command 'bdist_wheel'
Failed building wheel for django-timezone-field Running setup.py clean for django-timezone-field Running setup.py bdist_wheel for pycrypto ... error Complete output from command /opt/amon/env/bin/python3 -u -c "import setuptools, tokenize;file='/tmp/pip-build-zblw_xwo/pycrypto/setup.py';exec(compile(getattr(tokenize, 'open', open)(file).read().replace('\r\n', '\n'), file, 'exec'))" bdist_wheel -d /tmp/tmpoceq571qpip-wheel- --python-tag cp35: usage: -c [global_opts] cmd1 [cmd1_opts] [cmd2 [cmd2_opts] ...] or: -c --help [cmd1 cmd2 ...] or: -c --help-commands or: -c cmd --help
error: invalid command 'bdist_wheel'
Failed building wheel for pycrypto Running setup.py clean for pycrypto Running setup.py bdist_wheel for xmltodict ... error Complete output from command /opt/amon/env/bin/python3 -u -c "import setuptools, tokenize;file='/tmp/pip-build-zblw_xwo/xmltodict/setup.py';exec(compile(getattr(tokenize, 'open', open)(file).read().replace('\r\n', '\n'), file, 'exec'))" bdist_wheel -d /tmp/tmpjyr178r2pip-wheel- --python-tag cp35: usage: -c [global_opts] cmd1 [cmd1_opts] [cmd2 [cmd2_opts] ...] or: -c --help [cmd1 cmd2 ...] or: -c --help-commands or: -c cmd --help
error: invalid command 'bdist_wheel'
Failed building wheel for xmltodict Running setup.py clean for xmltodict Running setup.py bdist_wheel for yanc ... error Complete output from command /opt/amon/env/bin/python3 -u -c "import setuptools, tokenize;file='/tmp/pip-build-zblw_xwo/yanc/setup.py';exec(compile(getattr(tokenize, 'open', open)(file).read().replace('\r\n', '\n'), file, 'exec'))" bdist_wheel -d /tmp/tmpq19ixg4gpip-wheel- --python-tag cp35: usage: -c [global_opts] cmd1 [cmd1_opts] [cmd2 [cmd2_opts] ...] or: -c --help [cmd1 cmd2 ...] or: -c --help-commands or: -c cmd --help
error: invalid command 'bdist_wheel'
Failed building wheel for yanc Running setup.py clean for yanc Running setup.py bdist_wheel for nose-exclude ... error Complete output from command /opt/amon/env/bin/python3 -u -c "import setuptools, tokenize;file='/tmp/pip-build-zblw_xwo/nose-exclude/setup.py';exec(compile(getattr(tokenize, 'open', open)(file).read().replace('\r\n', '\n'), file, 'exec'))" bdist_wheel -d /tmp/tmpvjzub226pip-wheel- --python-tag cp35: usage: -c [global_opts] cmd1 [cmd1_opts] [cmd2 [cmd2_opts] ...] or: -c --help [cmd1 cmd2 ...] or: -c --help-commands or: -c cmd --help
error: invalid command 'bdist_wheel'
Failed building wheel for nose-exclude Running setup.py clean for nose-exclude Running setup.py bdist_wheel for nose-timer ... error Complete output from command /opt/amon/env/bin/python3 -u -c "import setuptools, tokenize;file='/tmp/pip-build-zblw_xwo/nose-timer/setup.py';exec(compile(getattr(tokenize, 'open', open)(file).read().replace('\r\n', '\n'), file, 'exec'))" bdist_wheel -d /tmp/tmpl2_r9sivpip-wheel- --python-tag cp35: usage: -c [global_opts] cmd1 [cmd1_opts] [cmd2 [cmd2_opts] ...] or: -c --help [cmd1 cmd2 ...] or: -c --help-commands or: -c cmd --help
error: invalid command 'bdist_wheel'
Failed building wheel for nose-timer Running setup.py clean for nose-timer Running setup.py bdist_wheel for python-crontab ... error Complete output from command /opt/amon/env/bin/python3 -u -c "import setuptools, tokenize;file='/tmp/pip-build-zblw_xwo/python-crontab/setup.py';exec(compile(getattr(tokenize, 'open', open)(file).read().replace('\r\n', '\n'), file, 'exec'))" bdist_wheel -d /tmp/tmpthoj8al7pip-wheel- --python-tag cp35: /usr/lib/python3.5/distutils/dist.py:261: UserWarning: Unknown distribution option: 'release' warnings.warn(msg) usage: -c [global_opts] cmd1 [cmd1_opts] [cmd2 [cmd2_opts] ...] or: -c --help [cmd1 cmd2 ...] or: -c --help-commands or: -c cmd --help
error: invalid command 'bdist_wheel'
Failed building wheel for python-crontab Running setup.py clean for python-crontab Running setup.py bdist_wheel for PyYAML ... error Complete output from command /opt/amon/env/bin/python3 -u -c "import setuptools, tokenize;file='/tmp/pip-build-zblw_xwo/PyYAML/setup.py';exec(compile(getattr(tokenize, 'open', open)(file).read().replace('\r\n', '\n'), file, 'exec'))" bdist_wheel -d /tmp/tmpwobfhitgpip-wheel- --python-tag cp35: usage: -c [global_opts] cmd1 [cmd1_opts] [cmd2 [cmd2_opts] ...] or: -c --help [cmd1 cmd2 ...] or: -c --help-commands or: -c cmd --help
error: invalid command 'bdist_wheel'
Failed building wheel for PyYAML Running setup.py clean for PyYAML Running setup.py bdist_wheel for termcolor ... error Complete output from command /opt/amon/env/bin/python3 -u -c "import setuptools, tokenize;file='/tmp/pip-build-zblw_xwo/termcolor/setup.py';exec(compile(getattr(tokenize, 'open', open)(file).read().replace('\r\n', '\n'), file, 'exec'))" bdist_wheel -d /tmp/tmpcbuk58uvpip-wheel- --python-tag cp35: usage: -c [global_opts] cmd1 [cmd1_opts] [cmd2 [cmd2_opts] ...] or: -c --help [cmd1 cmd2 ...] or: -c --help-commands or: -c cmd --help
error: invalid command 'bdist_wheel'
Failed building wheel for termcolor
Running setup.py clean for termcolor
Failed to build django-annoying django-kronos django-timezone-field pycrypto xmltodict yanc nose-exclude nose-timer python-crontab PyYAML termcolor
Installing collected packages: beautifulsoup4, pytz, Django, django-annoying, six, python-dateutil, python-crontab, django-kronos, django-timezone-field, djangorestframework, PyYAML, pyaml, pymongo, requests, pycrypto, gunicorn, greenlet, gevent, wheel, xmltodict, boto, apache-libcloud, django-storages, pip, yanc, nose, nose-exclude, termcolor, nose-timer, Faker, django-nose
Running setup.py install for django-annoying ... done
Running setup.py install for python-crontab ... done
Running setup.py install for django-kronos ... done
Running setup.py install for django-timezone-field ... done
Running setup.py install for PyYAML ... done
Running setup.py install for pycrypto ... done
Running setup.py install for xmltodict ... done
Found existing installation: pip 8.1.1
Uninstalling pip-8.1.1:
Successfully uninstalled pip-8.1.1
Running setup.py install for yanc ... done
Running setup.py install for nose-exclude ... done
Running setup.py install for termcolor ... done
Running setup.py install for nose-timer ... done
Successfully installed Django-1.11 Faker-0.7.7 PyYAML-3.12 apache-libcloud-1.5.0 beautifulsoup4-4.5.1 boto-2.45.0 django-annoying-0.10.3 django-kronos-1.0 django-nose-1.4.4 django-storages-1.5.1 django-timezone-field-2.0 djangorestframework-3.5.3 gevent-1.2.0 greenlet-0.4.12 gunicorn-19.6.0 nose-1.3.7 nose-exclude-0.5.0 nose-timer-0.6.0 pip-9.0.1 pyaml-16.12.2 pycrypto-2.6.1 pymongo-3.4.0 python-crontab-2.2.2 python-dateutil-2.6.0 pytz-2017.2 requests-2.12.4 six-1.10.0 termcolor-1.1.0 wheel-0.29.0 xmltodict-0.10.2 yanc-0.3.3
(env) root@server:/# touch /etc/opt/amon/amon.yml
(env) root@server:/# cd /opt/amon
(env) root@server:/opt/amon# python manage.py migrate
Traceback (most recent call last):
File "manage.py", line 10, in
cp /opt/amon/amon.yml /etc/opt/amon/amon.yml
fixes this issue (note the /etc
).
Of course you should also update the settings in that file.
After a lot of debugging and manual changes I cannot put this to work. Can anyone help me out there?
amonserver_1 | WARNING Not Found: /static/css/screen.css amonserver_1 | WARNING Not Found: /static/images/logo.png amonserver_1 | WARNING Not Found: /static/js/libs/libs.min.js mongo_1 | 2017-09-22T15:00:12.189+0000 I NETWORK [thread1] connection accepted from 172.20.0.3:41140 #115 (115 connections now open) mongo_1 | 2017-09-22T15:00:12.190+0000 I NETWORK [thread1] connection accepted from 172.20.0.3:41142 #116 (116 connections now open) mongo_1 | 2017-09-22T15:00:12.192+0000 I NETWORK [conn116] received client metadata from 172.20.0.3:41142 conn116: { driver: { name: "PyMongo", version: "3.4.0" }, os: { type: "Linux", name: "Ubuntu 16.04 xenial", architecture: "x86_64", version: "4.9.41-moby" }, platform: "CPython 3.5.2.final.0" } mongo_1 | 2017-09-22T15:00:12.192+0000 I NETWORK [thread1] connection accepted from 172.20.0.3:41144 #117 (117 connections now open) mongo_1 | 2017-09-22T15:00:12.193+0000 I NETWORK [thread1] connection accepted from 172.20.0.3:41146 #118 (118 connections now open) mongo_1 | 2017-09-22T15:00:12.193+0000 I NETWORK [thread1] connection accepted from 172.20.0.3:41148 #119 (119 connections now open) mongo_1 | 2017-09-22T15:00:12.193+0000 I NETWORK [conn115] received client metadata from 172.20.0.3:41140 conn115: { driver: { name: "PyMongo", version: "3.4.0" }, os: { type: "Linux", name: "Ubuntu 16.04 xenial", architecture: "x86_64", version: "4.9.41-moby" }, platform: "CPython 3.5.2.final.0" }
- Amon can connect to Mongo 👍
- ERROR: Gunicorn cannot find the static files. I have no idea what's going on
@knokio the static files are served by nginx. Gunicorn is a python/wsgi server only
Thank you @martinrusev . Indeed I got too excited and stopped in the middle of the install doc page 🙏 Static files are in but I and things are moving :D Thank you so much.
I'm launching Amon (and it's dependencies) in a Docker. I didn't find any online. Should I share it?
@knokio Sure, you can share. I am very glad it worked
@alexanderhofstaetter to address your original issue...
The wheel
package is missing, causing a lot of the requirements to fail.
I found that adding pip install wheel
just prior to pip install -r /opt/amon/requirements.txt
allowed the rest of the packages to install correctly.
adding pip install wheel just prior to pip install -r /opt/amon/requirements.txt allowed the rest of the packages to install correctly.
We should be adding this to the manual for others to find.
I ended up documenting my own experience in getting amon working: http://myrant.net/2017/11/25/setting-up-an-on-premise-instance-of-amon/ & https://github.com/bigcalm/amon-server
@bigcalm Your bash scripts look good, maybe we can wrap them in an official Ansible playbook?
@martinrusev feel free to work with the scripts. Attribution would be welcomed :)