Skip to content

Commit

Permalink
Merge pull request #30 from UtrechtUniversity/YDA-3872
Browse files Browse the repository at this point in the history
Yda 3872 - Upgrade from 1.5 installs iRODS 4.2.8 packages instead of 4.2.7
  • Loading branch information
reavdhoef authored Feb 9, 2021
2 parents 200e7e5 + e0b5cdd commit 7933263
Show file tree
Hide file tree
Showing 6 changed files with 76 additions and 29 deletions.
41 changes: 27 additions & 14 deletions docs/release-notes/release-1.6.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,19 +21,21 @@ Upgrade is supported by Ansible (2.9.x).
Requires Yoda external user service to be on version 1.5.x or higher.
Requires Yoda public server to be on version 1.6.x or higher.

1. Set Yoda release to `release-1.6` in configuration.
```yaml
yoda_version: release-1.6
```
1. Backup/copy custom configurations made to Yoda version 1.5.
To view what files were changed from the defaults, run `git diff`.

2. After making sure the configurations are stored safely in another folder, reset the Yoda folder using `git stash` or when you want to delete all changes made: `git reset --hard`.

2. Set the default schema to `default-1` in configuration.
```yaml
default_yoda_schema: default-1
3. Checkout branch `release-1.6` of the Yoda Git repository
```bash
git checkout release-1.6
```
This will set Yoda release to `release-1.6` in configuration as well as the default schema to `default-1`.

3. The core modules (`research`, `vault`, `statistics`, `group-manager`) are enabled by default in Yoda 1.6.
4. The core modules (`research`, `vault`, `statistics`, `group-manager`) are enabled by default in Yoda 1.6.
Only extra modules have to be enabled in the configuration.
So `modules` becomes `extra_modules` and all core modules should be removed from the `extra_modules` list.
Update the configuration according to your specifications.
For example:
```yaml
# Yoda modules
Expand All @@ -44,11 +46,12 @@ default_yoda_schema: default-1
version: "{{ yoda_version }}"
```
4. The core rulesets (`core` and `irods-ruleset-uu`) are enabled by default in Yoda 1.6.
5. The core rulesets (`core` and `irods-ruleset-uu`) are enabled by default in Yoda 1.6.
Only extra modules have to be enabled in the configuration.
Furthermore, the research ruleset (`irods-ruleset-research`) has been merged with the UU ruleset
(`irods-ruleset-uu`). So `rulesets` becomes `extra_rulesets`;
`core`, `irods-ruleset-research` and `irods-ruleset-uu` should be removed from the `extra_rulesets` list.
Update the configuration according to your specifications.
For example:
```yaml
# iRODS rulesets
Expand All @@ -60,21 +63,31 @@ default_yoda_schema: default-1
install_scripts: no
```

5. Run the Ansible upgrade in check mode.
6. Run the Ansible playbook in check mode.
```bash
ansible-playbook -i <path-to-your-environment> playbook.yml --check
### EXAMPLE ###
ansible-playbook -i /environments/development/allinone playbook.yml --check
```

6. Run the Ansible upgrade.
7. If the playbook has finished succesfully in check mode, run the Ansible playbook normally.
```bash
ansible-playbook -i <path-to-your-environment> playbook.yml
### EXAMPLE ###
ansible-playbook -i /environments/development/allinone playbook.yml
```

7. Convert all metadata XML in the vault to JSON (`default-0` XML to `default-0` JSON).
8. Convert all metadata XML in the vault to JSON (`default-0` XML to `default-0` JSON).
```bash
irule -r irods_rule_engine_plugin-irods_rule_language-instance -F /etc/irods/irods-ruleset-uu/tools/check-vault-metadata-xml-for-transformation-to-json.r
```

8. Update all metadata JSON in the vault to latest metadata JSON version (`default-0` to `default-1`).
9. Update all metadata JSON in the vault to latest metadata JSON version (`default-0` to `default-1`).
```bash
irule -r irods_rule_engine_plugin-irods_rule_language-instance -F /etc/irods/irods-ruleset-uu/tools/check-metadata-for-schema-updates.r
```

9. Update publication endpoints if there are published packages (landingpages and OAI-PMH)):
10. Update publication endpoints if there are published packages (landingpages and OAI-PMH)):
```bash
irule -r irods_rule_engine_plugin-irods_rule_language-instance -F /etc/irods/irods-ruleset-uu/tools/update-publications.r
```
20 changes: 17 additions & 3 deletions roles/irods_icat/tasks/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,14 @@
- name: Ensure iRODS 4.2.6 packages are absent
package:
name:
- irods-uu-microservices-4.2.6_0.8.0-1
- irods-sudo-microservices-4.2.6_1.0.0-1
- davrods-4.2.6_1.4.2-1
- irods-uu-microservices-4.2.6_0.8.0
- irods-sudo-microservices-4.2.6_1.0.0
- davrods-4.2.6_1.4.2
- irods-runtime-4.2.6
- irods-server-4.2.6
- irods-rule-engine-plugin-python-4.2.6
- irods-icommands-4.2.6
- irods-database-plugin-postgres-4.2.6
state: absent


Expand All @@ -19,6 +24,14 @@
- irods-rule-engine-plugin-python-4.2.7-1
state: present
when: not ansible_check_mode
register: irods_uninstalled


- name: Restart the iRODS server
become_user: '{{ irods_service_account }}'
become: yes
command: '/var/lib/irods/irodsctl restart'
when: irods_uninstalled is defined and irods_uninstalled.changed


- name: Ensure default msiExecCmd binaries are absent
Expand Down Expand Up @@ -199,6 +212,7 @@
become: yes
command: '/var/lib/irods/irodsctl start'
when: ils is failed
check_mode: false


- name: Wait until iRODS server is ready to receive requests
Expand Down
11 changes: 8 additions & 3 deletions roles/irods_icommands/tasks/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,14 @@
- name: Ensure iRODS 4.2.6 packages are absent
package:
name:
- irods-uu-microservices-4.2.6_0.8.0-1
- irods-sudo-microservices-4.2.6_1.0.0-1
- davrods-4.2.6_1.4.2-1
- irods-uu-microservices-4.2.6_0.8.0
- irods-sudo-microservices-4.2.6_1.0.0
- davrods-4.2.6_1.4.2
- irods-runtime-4.2.6
- irods-server-4.2.6
- irods-rule-engine-plugin-python-4.2.6
- irods-icommands-4.2.6
- irods-database-plugin-postgres-4.2.6
state: absent


Expand Down
11 changes: 8 additions & 3 deletions roles/irods_microservices/tasks/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,14 @@
- name: Ensure iRODS 4.2.6 packages are absent
package:
name:
- irods-uu-microservices-4.2.6_0.8.0-1
- irods-sudo-microservices-4.2.6_1.0.0-1
- davrods-4.2.6_1.4.2-1
- irods-uu-microservices-4.2.6_0.8.0
- irods-sudo-microservices-4.2.6_1.0.0
- davrods-4.2.6_1.4.2
- irods-runtime-4.2.6
- irods-server-4.2.6
- irods-rule-engine-plugin-python-4.2.6
- irods-icommands-4.2.6
- irods-database-plugin-postgres-4.2.6
state: absent


Expand Down
11 changes: 8 additions & 3 deletions roles/irods_resource/tasks/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,14 @@
- name: Ensure iRODS 4.2.6 packages are absent
package:
name:
- irods-uu-microservices-4.2.6_0.8.0-1
- irods-sudo-microservices-4.2.6_1.0.0-1
- davrods-4.2.6_1.4.2-1
- irods-uu-microservices-4.2.6_0.8.0
- irods-sudo-microservices-4.2.6_1.0.0
- davrods-4.2.6_1.4.2
- irods-runtime-4.2.6
- irods-server-4.2.6
- irods-rule-engine-plugin-python-4.2.6
- irods-icommands-4.2.6
- irods-database-plugin-postgres-4.2.6
state: absent


Expand Down
11 changes: 8 additions & 3 deletions roles/irods_runtime/tasks/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,14 @@
- name: Ensure iRODS 4.2.6 packages are absent
package:
name:
- irods-uu-microservices-4.2.6_0.8.0-1
- irods-sudo-microservices-4.2.6_1.0.0-1
- davrods-4.2.6_1.4.2-1
- irods-uu-microservices-4.2.6_0.8.0
- irods-sudo-microservices-4.2.6_1.0.0
- davrods-4.2.6_1.4.2
- irods-runtime-4.2.6
- irods-server-4.2.6
- irods-rule-engine-plugin-python-4.2.6
- irods-icommands-4.2.6
- irods-database-plugin-postgres-4.2.6
state: absent


Expand Down

0 comments on commit 7933263

Please sign in to comment.