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
894c20bb
Commit
894c20bb
authored
Nov 16, 2015
by
Edward Zarecor
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #2076 from edx/e0d/common-refactor
E0d/common refactor
parents
8f4e73e7
c5a986f2
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
154 additions
and
141 deletions
+154
-141
playbooks/roles/common/defaults/main.yml
+6
-141
playbooks/roles/common/meta/main.yml
+1
-0
playbooks/roles/common_vars/defaults/main.yml
+142
-0
playbooks/roles/common_vars/tasks/main.yml
+5
-0
No files found.
playbooks/roles/common/defaults/main.yml
View file @
894c20bb
---
# Override these variables
# Common variables are defined in the common_vars role on which this
# to change the base directory
# role depends. This is to allow sharing vars without creating
# where edX is installed
# side-effects. Any vars requred by this role should be added to
# common_vars/defaults/main.yml
# Set global htpasswd credentials
\ No newline at end of file
COMMON_ENABLE_BASIC_AUTH
:
False
COMMON_HTPASSWD_USER
:
edx
COMMON_HTPASSWD_PASS
:
edx
# Turn on syncing logs on rotation for edx
# application and tracking logs, must also
# have the AWS role installed
COMMON_AWS_SYNC
:
False
COMMON_AWS_SYNC_BUCKET
:
"
edx-{{
COMMON_ENVIRONMENT
}}-{{
COMMON_DEPLOYMENT
}}"
COMMON_AWS_S3_SYNC_SCRIPT
:
"
{{
COMMON_BIN_DIR
}}/send-logs-to-s3"
COMMON_BASE_DIR
:
/edx
COMMON_DATA_DIR
:
"
{{
COMMON_BASE_DIR}}/var"
COMMON_APP_DIR
:
"
{{
COMMON_BASE_DIR}}/app"
COMMON_LOG_DIR
:
"
{{
COMMON_DATA_DIR
}}/log"
# Override this to create
# common users in all roles
COMMON_USER_INFO
:
[]
# these directories contain
# symlinks for convenience
COMMON_BIN_DIR
:
"
{{
COMMON_BASE_DIR
}}/bin"
COMMON_CFG_DIR
:
"
{{
COMMON_BASE_DIR
}}/etc"
common_directories
:
-
path
:
"
{{
COMMON_DATA_DIR
}}"
-
path
:
"
{{
COMMON_APP_DIR
}}"
-
path
:
"
{{
COMMON_BIN_DIR
}}"
-
path
:
"
{{
COMMON_CFG_DIR
}}"
-
path
:
"
{{
COMMON_LOG_DIR
}}"
owner
:
"
{{
common_log_user
}}"
group
:
"
{{
common_log_user
}}"
-
path
:
"
/etc/logrotate.d/hourly"
-
path
:
"
/etc/rsyslog.d/50-default.conf"
state
:
absent
COMMON_ENVIRONMENT
:
'
default_env'
COMMON_DEPLOYMENT
:
'
default_deployment'
COMMON_PYPI_MIRROR_URL
:
'
https://pypi.python.org/simple'
COMMON_NPM_MIRROR_URL
:
'
http://registry.npmjs.org'
COMMON_UBUNTU_APT_KEYSERVER
:
"
http://keyserver.ubuntu.com/pks/lookup?op=get&fingerprint=on&search="
#The git checkout url in most roles is constructed from these values
#e.g. https://{{COMMON_GIT_MIRROR}}/{{COMMON_GIT_PATH}}/repo.git
COMMON_GIT_PROTOCOL
:
'
https'
# https|ssh
COMMON_GIT_MIRROR
:
'
github.com'
# git server hostname
COMMON_GIT_PATH
:
'
edx'
# git path prefix
# override this var to set a different hostname
COMMON_HOSTNAME
:
"
"
# Set to true to customize DNS search domains
COMMON_CUSTOM_DHCLIENT_CONFIG
:
false
# uncomment and specifity your domains.
# COMMON_DHCLIENT_DNS_SEARCH: ["ec2.internal","example.com"]
COMMON_MOTD_TEMPLATE
:
"
motd.tail.j2"
COMMON_SSH_PASSWORD_AUTH
:
"
no"
COMMON_SECURITY_UPDATES
:
no
# These are three maintenance accounts across all databases
# the read only user is is granted select privs on all dbs
# the admin user is granted create user privs on all dbs
# the migrate user is granted table alter privs on all dbs
COMMON_MYSQL_READ_ONLY_USER
:
'
read_only'
COMMON_MYSQL_READ_ONLY_PASS
:
'
password'
COMMON_MYSQL_ADMIN_USER
:
'
admin'
COMMON_MYSQL_ADMIN_PASS
:
'
password'
COMMON_MYSQL_MIGRATE_USER
:
'
migrate'
COMMON_MYSQL_MIGRATE_PASS
:
'
password'
COMMON_MONGO_READ_ONLY_USER
:
'
read_only'
COMMON_MONGO_READ_ONLY_PASS
:
!!null
COMMON_ENABLE_DATADOG
:
False
COMMON_ENABLE_NGINXTRA
:
False
COMMON_ENABLE_SPLUNKFORWARDER
:
False
COMMON_ENABLE_NEWRELIC
:
False
# enables app reporting, you must enable newrelic
# as well
COMMON_ENABLE_NEWRELIC_APP
:
False
COMMON_ENABLE_MINOS
:
False
COMMON_TAG_EC2_INSTANCE
:
False
common_boto_version
:
'
2.34.0'
common_debian_pkgs
:
-
ntp
-
ack-grep
-
lynx-cur
-
logrotate
-
mosh
-
rsyslog
-
screen
-
tmux
-
tree
-
git
-
unzip
-
python2.7
-
python-pip
-
python2.7-dev
# Not installed by default on vagrant ubuntu
# boxes
-
curl
common_pip_pkgs
:
-
pip==7.1.2
-
setuptools==18.3.2
-
virtualenv==13.1.2
-
virtualenvwrapper
common_web_user
:
www-data
common_web_group
:
www-data
common_log_user
:
syslog
common_git_ppa
:
"
ppa:git-core/ppa"
# Skip supervisor tasks
# When set to true this flag will allow you to install everything but keep
# supervisor from starting any of the services.
# Service files will be placed in supervisor's conf.available.d but not linked
# to supervisors 'conf.d' directory.
disable_edx_services
:
False
# Some apps run differently in dev mode(forums)
# so different start scripts are generated in dev mode.
devstack
:
False
# Some cluster apps need special settings when in vagrant
# due to eth0 always being the same IP address
vagrant_cluster
:
False
common_debian_variants
:
-
Ubuntu
-
Debian
common_redhat_variants
:
-
CentOS
-
Red Hat Enterprise Linux
-
Amazon
playbooks/roles/common/meta/main.yml
View file @
894c20bb
---
---
dependencies
:
dependencies
:
-
common_vars
-
role
:
user
-
role
:
user
user_info
:
"
{{
COMMON_USER_INFO
}}"
user_info
:
"
{{
COMMON_USER_INFO
}}"
-
role
:
security
-
role
:
security
...
...
playbooks/roles/common_vars/defaults/main.yml
0 → 100644
View file @
894c20bb
# Override these variables
# to change the base directory
# where edX is installed
# Set global htpasswd credentials
COMMON_ENABLE_BASIC_AUTH
:
False
COMMON_HTPASSWD_USER
:
edx
COMMON_HTPASSWD_PASS
:
edx
# Turn on syncing logs on rotation for edx
# application and tracking logs, must also
# have the AWS role installed
COMMON_AWS_SYNC
:
False
COMMON_AWS_SYNC_BUCKET
:
"
edx-{{
COMMON_ENVIRONMENT
}}-{{
COMMON_DEPLOYMENT
}}"
COMMON_AWS_S3_SYNC_SCRIPT
:
"
{{
COMMON_BIN_DIR
}}/send-logs-to-s3"
COMMON_BASE_DIR
:
/edx
COMMON_DATA_DIR
:
"
{{
COMMON_BASE_DIR}}/var"
COMMON_APP_DIR
:
"
{{
COMMON_BASE_DIR}}/app"
COMMON_LOG_DIR
:
"
{{
COMMON_DATA_DIR
}}/log"
# Override this to create
# common users in all roles
COMMON_USER_INFO
:
[]
# these directories contain
# symlinks for convenience
COMMON_BIN_DIR
:
"
{{
COMMON_BASE_DIR
}}/bin"
COMMON_CFG_DIR
:
"
{{
COMMON_BASE_DIR
}}/etc"
common_directories
:
-
path
:
"
{{
COMMON_DATA_DIR
}}"
-
path
:
"
{{
COMMON_APP_DIR
}}"
-
path
:
"
{{
COMMON_BIN_DIR
}}"
-
path
:
"
{{
COMMON_CFG_DIR
}}"
-
path
:
"
{{
COMMON_LOG_DIR
}}"
owner
:
"
{{
common_log_user
}}"
group
:
"
{{
common_log_user
}}"
-
path
:
"
/etc/logrotate.d/hourly"
-
path
:
"
/etc/rsyslog.d/50-default.conf"
state
:
absent
COMMON_ENVIRONMENT
:
'
default_env'
COMMON_DEPLOYMENT
:
'
default_deployment'
COMMON_PYPI_MIRROR_URL
:
'
https://pypi.python.org/simple'
COMMON_NPM_MIRROR_URL
:
'
http://registry.npmjs.org'
COMMON_UBUNTU_APT_KEYSERVER
:
"
http://keyserver.ubuntu.com/pks/lookup?op=get&fingerprint=on&search="
#The git checkout url in most roles is constructed from these values
#e.g. https://{{COMMON_GIT_MIRROR}}/{{COMMON_GIT_PATH}}/repo.git
COMMON_GIT_PROTOCOL
:
'
https'
# https|ssh
COMMON_GIT_MIRROR
:
'
github.com'
# git server hostname
COMMON_GIT_PATH
:
'
edx'
# git path prefix
# override this var to set a different hostname
COMMON_HOSTNAME
:
"
"
# Set to true to customize DNS search domains
COMMON_CUSTOM_DHCLIENT_CONFIG
:
false
# uncomment and specifity your domains.
# COMMON_DHCLIENT_DNS_SEARCH: ["ec2.internal","example.com"]
COMMON_MOTD_TEMPLATE
:
"
motd.tail.j2"
COMMON_SSH_PASSWORD_AUTH
:
"
no"
COMMON_SECURITY_UPDATES
:
no
# These are three maintenance accounts across all databases
# the read only user is is granted select privs on all dbs
# the admin user is granted create user privs on all dbs
# the migrate user is granted table alter privs on all dbs
COMMON_MYSQL_READ_ONLY_USER
:
'
read_only'
COMMON_MYSQL_READ_ONLY_PASS
:
'
password'
COMMON_MYSQL_ADMIN_USER
:
'
admin'
COMMON_MYSQL_ADMIN_PASS
:
'
password'
COMMON_MYSQL_MIGRATE_USER
:
'
migrate'
COMMON_MYSQL_MIGRATE_PASS
:
'
password'
COMMON_MONGO_READ_ONLY_USER
:
'
read_only'
COMMON_MONGO_READ_ONLY_PASS
:
!!null
COMMON_ENABLE_DATADOG
:
False
COMMON_ENABLE_NGINXTRA
:
False
COMMON_ENABLE_SPLUNKFORWARDER
:
False
COMMON_ENABLE_NEWRELIC
:
False
# enables app reporting, you must enable newrelic
# as well
COMMON_ENABLE_NEWRELIC_APP
:
False
COMMON_ENABLE_MINOS
:
False
COMMON_TAG_EC2_INSTANCE
:
False
common_boto_version
:
'
2.34.0'
common_debian_pkgs
:
-
ntp
-
ack-grep
-
lynx-cur
-
logrotate
-
mosh
-
rsyslog
-
screen
-
tmux
-
tree
-
git
-
unzip
-
python2.7
-
python-pip
-
python2.7-dev
# Not installed by default on vagrant ubuntu
# boxes
-
curl
common_pip_pkgs
:
-
pip==7.1.2
-
setuptools==18.3.2
-
virtualenv==13.1.2
-
virtualenvwrapper
common_web_user
:
www-data
common_web_group
:
www-data
common_log_user
:
syslog
common_git_ppa
:
"
ppa:git-core/ppa"
# Skip supervisor tasks
# When set to true this flag will allow you to install everything but keep
# supervisor from starting any of the services.
# Service files will be placed in supervisor's conf.available.d but not linked
# to supervisors 'conf.d' directory.
disable_edx_services
:
False
# Some apps run differently in dev mode(forums)
# so different start scripts are generated in dev mode.
devstack
:
False
# Some cluster apps need special settings when in vagrant
# due to eth0 always being the same IP address
vagrant_cluster
:
False
common_debian_variants
:
-
Ubuntu
-
Debian
common_redhat_variants
:
-
CentOS
-
Red Hat Enterprise Linux
-
Amazon
playbooks/roles/common_vars/tasks/main.yml
0 → 100644
View file @
894c20bb
---
# There should never be any side-effecting tasks included in this role.
# It is used solely for making shared variables available across roles.
\ No newline at end of file
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