Project

General

Profile

Update Netbox » History » Version 1

Ahmed Bilal, 05/08/2020 09:07 AM

1 1 Ahmed Bilal
h1. Update Netbox
2
3
4
@/etc/supervisor.d/netbox.ini@
5
6
<pre>
7
[program:netbox]
8
command = /home/app/netbox/venv/bin/gunicorn -c /home/app/netbox/gunicorn_config.py netbox.wsgi
9
directory = /home/app/netbox/netbox/
10
user = app
11
12
[program:netbox-rqworker]
13
command = /home/app/netbox/venv/bin/python3 /home/app/netbox/netbox/manage.py rqworker
14
directory = /home/app/netbox/netbox/
15
user = app
16
</pre>
17
18
19
REDIS configuration in @/home/app/netbox/netbox/netbox/configuration.py@ should be like below
20
21
<pre>
22
REDIS = {
23
    'tasks': {
24
        'HOST': 'localhost',
25
        'PORT': 6379,
26
        'PASSWORD': '',
27
        'DATABASE': 0,
28
        'DEFAULT_TIMEOUT': 300,
29
        'SSL': False,
30
    },
31
    'caching': {
32
        'HOST': 'localhost',
33
        'PORT': 6379,
34
        'PASSWORD': '',
35
        'DATABASE': 1,
36
        'DEFAULT_TIMEOUT': 300,
37
        'SSL': False,
38
    }
39
}
40
</pre>
41
42
<pre><code class="shell">
43
cd /home/app/netbox
44
git checkout master
45
git reset --hard
46
git pull origin master
47
chown -R app:app .
48
echo django-auth-ldap >> requirements.txt
49
echo python-decouple >> requirements.txt
50
./upgrade.sh
51
supervisorctl reread
52
supervisorctl reload
53
supervisorctl restart all
54
</code></pre>