Skip to content

Commit d62917d

Browse files
Rename db.backend to db.artifact_store.backend
1 parent fb2aada commit d62917d

File tree

6 files changed

+9
-8
lines changed

6 files changed

+9
-8
lines changed

ansible/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -215,7 +215,7 @@ cd <openwhisk_home>
215215
cd ansible
216216
ansible-playbook -i environments/<environment> initMongodb.yml -e mongodb_connect_string="mongodb://172.17.0.1:27017"
217217
ansible-playbook -i environments/<environment> apigateway.yml -e mongodb_connect_string="mongodb://172.17.0.1:27017"
218-
ansible-playbook -i environments/<environment> openwhisk.yml -e mongodb_connect_string="mongodb://172.17.0.1:27017" -e database_backend="MongoDB"
218+
ansible-playbook -i environments/<environment> openwhisk.yml -e mongodb_connect_string="mongodb://172.17.0.1:27017" -e db_artifact_backend="MongoDB"
219219
220220
# installs a catalog of public packages and actions
221221
ansible-playbook -i environments/<environment> postdeploy.yml

ansible/group_vars/all

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -256,7 +256,6 @@ db:
256256
port: "{{ db_port | default(lookup('ini', 'db_port section=db_creds file={{ playbook_dir }}/db_local.ini')) }}"
257257
host: "{{ db_host | default(lookup('ini', 'db_host section=db_creds file={{ playbook_dir }}/db_local.ini')) }}"
258258
persist_path: "{{ db_persist_path | default(false) }}"
259-
backend: "{{ database_backend | default('CouchDB') }}"
260259
instances: "{{ groups['db'] | length }}"
261260
authkeys:
262261
- guest
@@ -275,6 +274,8 @@ db:
275274
invoker:
276275
user: "{{ db_invoker_user | default(lookup('ini', 'db_username section=invoker file={{ playbook_dir }}/db_local.ini')) }}"
277276
pass: "{{ db_invoker_pass | default(lookup('ini', 'db_password section=invoker file={{ playbook_dir }}/db_local.ini')) }}"
277+
artifact_store:
278+
backend: "{{ db_artifact_backend | default('CouchDB') }}"
278279
activation_store:
279280
backend: "{{ db_activation_backend | default('CouchDB') }}"
280281
elasticsearch:

ansible/roles/controller/tasks/deploy.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -298,12 +298,12 @@
298298
"CONFIG_whisk_mongodb_uri": "{{ db.mongodb.connect_string }}"
299299
"CONFIG_whisk_mongodb_database": "{{ db.mongodb.database }}"
300300
"CONFIG_whisk_spi_ArtifactStoreProvider": "org.apache.openwhisk.core.database.mongodb.MongoDBArtifactStoreProvider"
301-
when: db.backend == "MongoDB"
301+
when: db.artifact_store.backend == "MongoDB"
302302

303303
- name: merge mongodb artifact store env
304304
set_fact:
305305
env: "{{ env | combine(mongodb_env) }}"
306-
when: db.backend == "MongoDB"
306+
when: db.artifact_store.backend == "MongoDB"
307307

308308
- name: populate volumes for controller
309309
set_fact:

ansible/roles/invoker/tasks/deploy.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -313,12 +313,12 @@
313313
"CONFIG_whisk_mongodb_uri": "{{ db.mongodb.connect_string }}"
314314
"CONFIG_whisk_mongodb_database": "{{ db.mongodb.database }}"
315315
"CONFIG_whisk_spi_ArtifactStoreProvider": "org.apache.openwhisk.core.database.mongodb.MongoDBArtifactStoreProvider"
316-
when: db.backend == "MongoDB"
316+
when: db.artifact_store.backend == "MongoDB"
317317

318318
- name: merge mongodb artifact store env
319319
set_fact:
320320
env: "{{ env | combine(mongodb_env) }}"
321-
when: db.backend == "MongoDB"
321+
when: db.artifact_store.backend == "MongoDB"
322322

323323
- name: include plugins
324324
include_tasks: "{{ inv_item }}.yml"

ansible/tasks/db/checkDb.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@
2828
user: "{{ dbUser }}"
2929
password: "{{ dbPass }}"
3030
force_basic_auth: yes
31-
when: db.backend == "CouchDB"
31+
when: db.artifact_store.backend == "CouchDB"
3232

3333
# the collection in MongoDB doesn't need to be created in advance, so just skip it
3434
# - name: check if {{ dbName }} on MongoDB exists

ansible/templates/whisk.conf.j2

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ whisk {
1414
WhiskActivation = "{{ db.whisk.activations }}"
1515
}
1616
}
17-
{% if db.backend == 'MongoDB' %}
17+
{% if db.artifact_store.backend == 'MongoDB' %}
1818
mongodb {
1919
uri = "{{ db.mongodb.connect_string }}"
2020
database = "{{ db.mongodb.database }}"

0 commit comments

Comments
 (0)