Idea #8014
closed[Deployment] /var/www/arvados-RAILSPKG/config includes symlinks to /etc/arvados/RAILSPKG as appropriate
Description
The SSO package already does this: the postinst script creates symbolic links in /var/www/arvados-sso/config to the corresponding file in /etc/arvados/sso, for files the user is expected to edit: application.yml, database.yml, production.rb.
Follow the same pattern in the process of building the API and Workbench packages. Stop copying files from /etc to /var/www, and instead set up symlinks in the postinst script.
In order to make your changes effective, you'll need to increment the iteration of the two packages, or force a rebuild of the packages by making a noop commit to them in arvados.
Update the install guide to remove references to running arvados-RAILSPKG-update.sh. That will be moot after this change.
Updated by Brett Smith about 9 years ago
- Target version set to Arvados Future Sprints
Updated by Brett Smith about 9 years ago
- Description updated (diff)
- Target version deleted (
Arvados Future Sprints) - Story points set to 0.5
Updated by Brett Smith about 9 years ago
- Target version set to Arvados Future Sprints
Updated by Brett Smith about 9 years ago
- Target version changed from Arvados Future Sprints to 2016-01-06 sprint
Updated by Brett Smith about 9 years ago
- Subject changed from [API] [Workbench] /var/www/arvados-foo/config includes symlinks to /etc/arvados/foo as appropriate to [Deployment] /var/www/arvados-RAILSPKG/config includes symlinks to /etc/arvados/RAILSPKG as appropriate
- Description updated (diff)
Updated by Tom Clegg about 9 years ago
- Category set to Deployment
- Assigned To set to Tom Clegg
Updated by Brett Smith about 9 years ago
- Target version changed from 2016-01-06 sprint to Arvados Future Sprints
Updated by Brett Smith almost 9 years ago
- Status changed from New to In Progress
- Assigned To set to Brett Smith
Updated by Brett Smith almost 9 years ago
8014-rails-postinst-scripts-wip is up for review. It does both this and #8059, and it does them both by DRYing up all the Rails package infrastructure into a single stack. Now run-library.sh has a handle_rails_package function, and it's used to build the API server, Workbench, and SSO server, with just small hooks to account for the differences between them.
First the branch makes several small bugfixes and cleanups to the SSO package postinst to make it ready to handle the other packages. This is a long series of small commits explaining each change.
Then there's the big unifying commit to bring all the Rails package-building infrastructure together. If you run git show -M
on that last commit, you can see the changes in the postinst script that mostly just serve to unify it for all packages, compared to the last version of the SSO postinst script.
handle_rails_package builds postinst/prerm/postrm scripts for all these packages on the fly. See jenkins/rails-package-scripts/README.md for details.
Updated by Brett Smith almost 9 years ago
- Target version changed from Arvados Future Sprints to 2016-01-06 sprint
Updated by Brett Smith almost 9 years ago
Also: for all three packages, I was able to install the modified package, fill in the necessary .yml files, and reconfigure the package and see it finish all the postinst steps. So there's been at least that much testing.
Updated by Nico César almost 9 years ago
I compiled the branch and copy the arvados-api-server to c97qk ... it seems like a successful install .. it did even a database schema change:
c97qk:~# dpkg -i arvados-api-server_0.1.20160104193447.3344f5b-3_amd64.deb (Reading database ... 69923 files and directories currently installed.) Preparing to unpack arvados-api-server_0.1.20160104193447.3344f5b-3_amd64.deb ... Unpacking arvados-api-server (0.1.20160104193447.3344f5b-3) over (0.1.20151223192841.378e6e0-1) ... Setting up arvados-api-server (0.1.20160104193447.3344f5b-3) ... Assumption: nginx is configured to serve Rails from /var/www/arvados-api/current Assumption: nginx and passenger run as www-data:www-data Creating symlinks to configuration in /etc/arvados/api ...... done. Running bundle install... done. Ensuring directory and file permissions ...... done. Running db:migrate...== AddExitCodeToContainers: migrating ======================================== -- add_column(:containers, :exit_code, :integer) -> 0.0009s == AddExitCodeToContainers: migrated (0.0010s) =============================== done. Checking application.yml for completeness...AppVersion (discovered) 378e6e0-1 action_controller.perform_caching true admin_notifier_email_from support@curoverse.com arvados_docsite https://doc.arvados.org (..) sso_app_id c97qk.arvadosapi.com sso_app_secret ********* sso_insecure false sso_provider_url https://auth.curoverse.com user_notifier_email_from support@curoverse.com user_profile_notification_address false uuid_prefix c97qk websocket_address wss://ws.c97qk.arvadosapi.com/websocket workbench_address https://workbench.c97qk.arvadosapi.com done. Precompiling assets... done. * Restarting nginx nginx [ OK ] c97qk:~# echo $? 0
Updated by Nico César almost 9 years ago
I did a mistake and added some comments in the review ticket see https://dev.arvados.org/issues/8036#note-12
but this LGTM. lets merge
Updated by Brett Smith almost 9 years ago
- Target version changed from 2016-01-06 sprint to 2016-01-20 Sprint
Updated by Peter Amstutz almost 9 years ago
_install_rails_reconfigure.liquid
is missing
Updated by Brett Smith almost 9 years ago
Peter Amstutz wrote:
_install_rails_reconfigure.liquid
is missing
Sorry about that. Fixed in 78ae7f1.
Updated by Peter Amstutz almost 9 years ago
Brett Smith wrote:
Peter Amstutz wrote:
_install_rails_reconfigure.liquid
is missingSorry about that. Fixed in 78ae7f1.
With that fix, looks good to me.
Updated by Brett Smith almost 9 years ago
Everything built and deployed successfully last night, so I'm going to call this resolved. I imagine we'll find bugs in the new stuff but those can be new issues.
Updated by Brett Smith almost 9 years ago
- Status changed from In Progress to Resolved