RhodeCodeのインストーラが更新されたので適用する。
https://rhodecode.com/blog/43/a-strongly-improved-installation-experience
<既存環境>
ユーザ:rhodecode
既存のインストーラを実行。
# python rhodecode-installer.py RhodeCode Installer 0.4.1 ------------------------------------ I am your assistant for installing, upgrading & removing of RhodeCode Enterprise under Linux. You can always quit me by typing 'q' on the prompt. ... running command: whoami
インストーラの新しいバージョンをチェック。
RhodeCode Installer 0.4.1 ------------------------------------ Please select an option: [1] Install RhodeCode Enterprise [2] Show the start command [3] Check for new RhodeCode Enterprise version [4] Change the settings [5] Perform advanced actions [0] Check for new Installer version [q] Quit installer > 0
更新する。
RhodeCode Installer 0.4.1 ------------------------------------ A new installer version 0.6.0 is available! What’s new in the version? - Pre-compiled system folder under Windows Can I download and install the new installer for you? [y]es [n]o > y I downloaded and installed the latest installer version. Please re-open me to see it in action. Thanks, it was a pleasure to be your assistant!
新しいインストーラになったようなので、実行。
# python rhodecode-installer.py As root please! You need to run me with root / sudo privileges. Please type 'sudo python linux-installer.py'. If you can not fix the error by yourself then please contact us: 1. Go to https://rhodecode.com/help 2. Start a new discussion 3. Tell us about your system and the versions of the installed RhodeCode applications 4. Attach to the discussion the Installer log file located at /tmp/rhodecode-installer.log
rootで実行したのに、sudo で実行するように怒られる。
sudoで実行する。
# sudo python rhodecode-installer.py RhodeCode Installer 0.6.0 ------------------------- I am your assistant for installing, upgrading & adjusting of RhodeCode Enterprise.You can always quit me by typing 'q' on the prompt. RhodeCode Installer 0.6.0 ------------------------- Do you already have RhodeCode or RhodeCode Enterprise installed on this server? [y]es [n]o > y RhodeCode Installer 0.6.0 ------------------------- Under which Linux user did you install RhodeCode Enterprise? > rhodecode Please move me into the folder /home/rhodecode/rhodecode and run me again. Thanks!
指示のあったように、インストーラを配置する。
# ls rhodecode/ rhodecode-installer.py rhodecode-venv/ # mv rhodecode-installer.py rhodecode
再び実行。
# cd rhodecode # sudo python rhodecode-installer.py RhodeCode Installer 0.6.0 ------------------------- I am your assistant for installing, upgrading & adjusting of RhodeCode Enterprise.You can always quit me by typing 'q' on the prompt. RhodeCode Installer 0.6.0 ------------------------- Do you already have RhodeCode or RhodeCode Enterprise installed on this server? [y]es [n]o > y RhodeCode Installer 0.6.0 ------------------------- Under which Linux user did you install RhodeCode Enterprise? > rhodecode RhodeCode Installer 0.6.0 ------------------------- From Installer version 0.5.0 on, we are introducing a more standardized folder structure in the format: /home/rhodecode/rhodecode /home/rhodecode/rhodecode/data - for ini files and SQLite /home/rhodecode/rhodecode/system - for virtualenv or pre-built app code /home/rhodecode/rhodecode/data - for repositories (can be a symlink!) In the following steps I will create this folder structure and move or copy existing files. Reading your former folder structure from /home/rhodecode/.rhodecode_config ... RhodeCode Installer 0.6.0 ------------------------- From Installer version 0.5.0 on, we are introducing a more standardized folder structure in the format: /home/rhodecode/rhodecode /home/rhodecode/rhodecode/data - for ini files and SQLite /home/rhodecode/rhodecode/system - for virtualenv or pre-built app code /home/rhodecode/rhodecode/data - for repositories (can be a symlink!) In the following steps I will create this folder structure and move or copy existing files. Moving /home/rhodecode/rhodecode/production.ini to /home/rhodecode/rhodecode/data/production.ini ... Moving /home/rhodecode/rhodecode/rhodecode.db to /home/rhodecode/rhodecode/data/rhodecode.db ... Copying /home/rhodecode/rhodecode-venv to /home/rhodecode/rhodecode/system ... Moving /home/rhodecode/.rhodecode_config to /home/rhodecode/rhodecode/data/installer.ini ... Deleting old folder /home/rhodecode/rhodecode-venv ...
データ移行に関する設定がある。
RhodeCode Installer 0.6.0 ------------------------- What database do you use? [s]qlite (built-in, no server needed) [m]ysql [p]ostgresql > s I am starting to fix possible issues ... I am fixing folder relationships in system folder ... I am fixing folder relationships in config files ... Trying to get the application version ... Found version 2.2.3 Trying to (re)install service ... Please wait, I am downloading the init.d file for your operating system ... Please wait, I am customizing the init.d file for your installation ... I create the log folder /var/log/rhodecode if not existing, yet ... ... running command: sudo mkdir /var/log/rhodecode I create the log file /var/log/rhodecode/rhodecode.log if not existing, yet ... ... running command: sudo touch /var/log/rhodecode/rhodecode.log I set the proper write permissions for the log file ... ... running command: sudo chmod 0666 /var/log/rhodecode/rhodecode.log I copy the init.d file to /etc/init.d/rhodecode ... ... running command: sudo cp /tmp/rhodecode-initd-template /etc/init.d/rhodecode I make the file /etc/init.d/rhodecode executable ... ... running command: sudo chmod +x /etc/init.d/rhodecode I am verifying the correct installation of the init.d file ... I am trying to restart the new service ... ... running command: sudo /etc/init.d/rhodecode restart I (re)installed RhodeCode Enterprise as a service. I finished with fixing issues. Please select an option: [b] Back to menu [q] Quit Installer > q
サービスを開始して動作確認。
# /etc/init.d/rhodecode start Starting RhodeCode Enterprise: Changing user to rhodecode:rhodecode (510:511) Entering daemon mode [ OK ]