Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
C
configuration
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
OpenEdx
configuration
Commits
cb391060
Commit
cb391060
authored
11 years ago
by
e0d
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Building the mongo url dynamically.
parent
357f8ce9
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
15 additions
and
5 deletions
+15
-5
playbooks/roles/forum/defaults/main.yml
+7
-5
playbooks/roles/forum/tasks/test.yml
+8
-0
No files found.
playbooks/roles/forum/defaults/main.yml
View file @
cb391060
...
...
@@ -13,10 +13,13 @@ forum_path: "{{ forum_code_dir }}/bin:{{ forum_rbenv_bin }}:{{ forum_rbenv_shims
FORUM_MONGO_USER
:
"
cs_comments_service"
FORUM_MONGO_PASSWORD
:
"
password"
FORUM_MONGO_HOST
:
"
localhost"
FORUM_MONGO_HOSTS
:
-
"
localhost"
FORUM_MONGO_PORT
:
"
27017"
FORUM_MONGO_DATABASE
:
"
cs_comments_service"
FORUM_MONGO_URL
:
"
mongodb://{{
FORUM_MONGO_USER
}}:{{
FORUM_MONGO_PASSWORD
}}@{{
FORUM_MONGO_HOST
}}:{{
FORUM_MONGO_PORT
}}/{{
FORUM_MONGO_DATABASE
}}"
FORUM_MONGO_URL
:
"
mongodb://{{
FORUM_MONGO_USER
}}:{{
FORUM_MONGO_PASSWORD
}}@{%-
for
host
in
FORUM_MONGO_HOSTS
-%}
{{host}}:{{
FORUM_MONGO_PORT
}}{%-
if
not
loop.last
-%},{%-
endif
-%}
{%-
endfor
-%}/{{
FORUM_MONGO_DATABASE
}}"
FORUM_SINATRA_ENV
:
"
development"
FORUM_RACK_ENV
:
"
development"
FORUM_NGINX_PORT
:
"
18080"
...
...
@@ -49,9 +52,9 @@ forum_unicorn_port: "4567"
#
# The following services should be listening on the associated
# ports when the role has been successfully created.
# ports when the role has been successfully created. Note that
# connectivity to Mongo is also tested, but separately.
#
forum_services
:
-
{
service
:
"
sinatra"
,
host
:
"
localhost"
,
port
:
"
{{
forum_unicorn_port
}}"
}
-
{
service
:
"
mongo"
,
host
:
"
{{
FORUM_MONGO_HOST
}}"
,
port
:
"
{{
FORUM_MONGO_PORT
}}"
}
-
{
service
:
"
elasticsearch"
,
host
:
"
{{
FORUM_ELASTICSEARCH_HOST
}}"
,
port
:
"
{{
FORUM_ELASTICSEARCH_PORT
}}"
}
\ No newline at end of file
This diff is collapsed.
Click to expand it.
playbooks/roles/forum/tasks/test.yml
View file @
cb391060
...
...
@@ -7,3 +7,11 @@
tags
:
-
forum
-
test
-
name
:
forum | test that mongo replica set members are listing
wait_for
:
port={{ FORUM_MONGO_PORT }} host={{ item }} timeout=30
with_items
:
"
{{
FORUM_MONGO_HOSTS
}}"
when
:
not devstack
tags
:
-
forum
-
test
This diff is collapsed.
Click to expand it.
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment