-
-
Save Remember2015/a1157d6be05d239fb6b8286aae94aa34 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Rootユーザに変更 | |
sudo su - | |
# virtualenvインストール | |
pip install -U virtualenv | |
virtualenv /www/sentry/ | |
source /www/sentry/bin/activate | |
# posgre版sentryインストール | |
pip install -U sentry[mysql] | |
# sentry初期configファイル作成 | |
sentry init /etc/sentry.conf.py | |
# 作成されていることを確認 | |
ls -al /etc/sentry.conf.py | |
-rw-r--r--. 1 root root 5743 Apr 6 23:17 /etc/sentry.conf.py | |
# djangoプロジェクトの設定ファイルですが、デフォルトはSQLiteが設定されています。 | |
vim /etc/sentry.conf.py | |
#--- /etc/sentry.conf.py 編集 start ----------------------------------------------- | |
DATABASES = { | |
'default': { | |
# You can swap out the engine for MySQL easily by changing this value | |
# to ``django.db.backends.mysql`` or to PostgreSQL with | |
# ``django.db.backends.postgresql_psycopg2`` | |
# If you change this, you'll also need to install the appropriate python | |
# package: psycopg2 (Postgres) or mysql-python | |
#'ENGINE': 'django.db.backends.sqlite3', | |
'ENGINE': 'django.db.backends.mysql', | |
#'NAME': os.path.join(CONF_ROOT, 'sentry.db'), | |
'NAME': 'sentry', | |
'USER': 'sentry', | |
'PASSWORD': 'sentry', | |
'HOST': 'localhost', | |
'PORT': '3306', | |
} | |
} | |
... | |
SENTRY_URL_PREFIX = 'http://192.168.33.10' | |
SENTRY_WEB_HOST = '192.168.33.10' | |
SENTRY_WEB_OPTIONS = { | |
'workers': 3, # the number of gunicorn workers | |
'secure_scheme_headers': {'X-FORWARDED-PROTO': 'https'}, # detect HTTPS mode from X-Forwarded-Proto header | |
} | |
#--- /etc/sentry.conf.py 編集 end ------------------------------------------------- | |
# sentry起動 | |
sentry --config=/etc/sentry.conf.py start |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment