ログってなんぼ

エンジニアのメモです

AWS EC2でRedash 2.0.0を入れて3.0.0にアップグレード

AWSのAMIからRedashを立ち上げて、その後3.0.0にアップグレードしたメモです

起動

Setting up a Redash instance · Redash Help Center

このリストのap-northeast-1のところにあるAMIを使わせてもらいます。 リンクになっているのでマネジメントコンソールにログインした状態でポチッと押せばEC2起動ウィザードが立ち上がります。

2.0.0 から 3.0.0へのアップグレード

インスタンスへログインして、アップグレードスクリプトを叩くだけなのですがちょっとハマりました

$ cd /opt/redash/current

$ sudo bin/upgrade
Starting Redash upgrade:
Found version: 3.0.0
Current version: 2.0.0+b2990
・
・
・
AttributeError: 'module' object has no attribute 'SSL_ST_INIT'

エラーでアップグレード失敗してしまいました

SSL_ST_INITでググると、いろいろなプロダクトのissueでOpenSSLを16.20に上げろという情報が出てくるので、アップデートします

$ sudo pip install pyOpenSSL -U
Collecting pyOpenSSL
  Downloading pyOpenSSL-17.5.0-py2.py3-none-any.whl (53kB)
    100% |████████████████████████████████| 61kB 2.8MB/s

再度トライ

$ sudo bin/upgrade
Starting Redash upgrade:
Found version: 3.0.0
Current version: 2.0.0+b2990
* Before doing an upgrade, please make sure you have a backup.
* If you have any issues, please refer to the troubleshooting section in the upgrade guide:
  https://redash.io/help-onpremise/maintenance/how-to-upgrade-redash.html
* If the upgrade guide doesn't help, you can ask for help on the forum (https://discuss.redash.io).

Full CHANGELOG for this release: https://github.com/getredash/redash/blob/master/CHANGELOG.md
Continue with upgrade? (y/n): y
Downloading release tarball...
Unpacking to: redash.3.0.0.b3134...
Changing ownership to redash...
Linking .env file...
Installing new Python packages (if needed)...
Running migrations (if needed)...
Linking to current version...
Restarting...
Done! Enjoy.

ε-(´∀`*)ホッ