--- /dev/null
+Now that all your configuration is in place, rerun the {{railspkg}} package configuration to install necessary Ruby Gems and other server dependencies. On Debian-based systems:
+
+<notextile><pre><code>~$ <span class="userinput">sudo dpkg-reconfigure {{railspkg}}</span>
+</code></pre></notextile>
+
+On Red Hat-based systems:
+
+<notextile><pre><code>~$ <span class="userinput">sudo yum reinstall {{railspkg}}</span>
+</code></pre></notextile>
+
+You only need to do this manual step once, after initial configuration. When you make configuration changes in the future, you just need to restart Nginx for them to take effect.
\ No newline at end of file
h2. Prepare the API server deployment
-Now that all your configuration is in place, run @/usr/local/bin/arvados-api-server-upgrade.sh@. This will install and check your configuration, install necessary gems, and run any necessary database setup.
+{% assign railspkg = "arvados-api-server" %}
+{% include 'install_rails_reconfigure' %}
{% include 'notebox_begin' %}
-You can safely ignore the following messages if they appear while this script runs:
+You can safely ignore the following messages if they appear while this command runs:
<pre>Don't run Bundler as root. Bundler can ask for sudo if it is needed, and installing your bundle as root will
break this application for all non-root users on this machine.</pre>
<pre>fatal: Not a git repository (or any of the parent directories): .git</pre>
{% include 'notebox_end' %}
-
-This command aborts when it encounters an error. It's safe to rerun multiple times, so if there's a problem with your configuration, you can fix that and try again.
-
Enter it again: <span class="userinput">paste-database-password-you-generated</span>
</code></pre></notextile>
-Rails will take care of creating the database, based on the information from @/etc/arvados/sso/database.yml@.
+Rails will take care of creating the database, based on the information from @/etc/arvados/sso/database.yml@.
Alternatively, if the database user you intend to use for the SSO server should not be allowed to create new databases, the user and the database can be created like this:
h2(#reconfigure_package). Reconfigure the package
-Now that the @/etc/arvados/sso/application.yml@ and @/etc/arvados/sso/database.yml@ files have been updated, we need to reconfigure our installed package. Doing so will create and/or initialize the database and precompile the assets.
-
-On a Debian-based system:
-
-<notextile>
-<pre><code>~$ <span class="userinput">sudo dpkg-reconfigure arvados-sso-server</span>
-</code></pre>
-</notextile>
-
-On a Red Hat-based system, we need to reinstall the package instead:
-
-<notextile>
-<pre><code>~$ <span class="userinput">sudo yum reinstall arvados-sso-server</span>
-</code></pre>
-</notextile>
+{% assign railspkg = "arvados-sso-server" %}
+{% include 'install_rails_reconfigure' %}
h2(#client). Create arvados-server client
<pre><code> # Google API tokens required for OAuth2 login.
google_oauth2_client_id: <span class="userinput">"---YOUR---CLIENT---ID---HERE--"-</span>
google_oauth2_client_secret: <span class="userinput">"---YOUR---CLIENT---SECRET---HERE--"-</span></code></pre></notextile>
-
-
h2. Prepare the Workbench deployment
-Now that all your configuration is in place, run @/usr/local/bin/arvados-workbench-upgrade.sh@. This will install and check your configuration, and install necessary gems.
+{% assign railspkg = "arvados-workbench" %}
+{% include 'install_rails_reconfigure' %}
{% include 'notebox_begin' %}
-You can safely ignore the following error message you may see when installing gems:
+You can safely ignore the following error message you may see when Ruby Gems are installed:
<notextile>
<pre><code>themes_for_rails at /usr/local/rvm/gems/ruby-2.1.1/bundler/gems/themes_for_rails-1fd2d7897d75 did not have a valid gemspec.
This prevents bundler from installing bins or native extensions, but that may not affect its functionality.
</notextile>
{% include 'notebox_end' %}
-This command aborts when it encounters an error. It's safe to rerun multiple times, so if there's a problem with your configuration, you can fix that and try again.
-
h2. Trusted client setting
Log in to Workbench once to ensure that the Arvados API server has a record of the Workbench client. (It's OK if Workbench says your account hasn't been activated yet. We'll deal with that next.)