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
04f918de
Commit
04f918de
authored
Aug 11, 2015
by
Feanil Patel
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #2205 from edx/feanil/merge_cypress_into_master
Feanil/merge cypress into master
parents
ffd28db5
66026481
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
54 additions
and
6 deletions
+54
-6
playbooks/edx_sandbox.yml
+0
-1
playbooks/roles/edx_ansible/defaults/main.yml
+4
-0
playbooks/roles/edx_ansible/tasks/deploy.yml
+1
-0
playbooks/vagrant-fullstack.yml
+1
-1
util/vagrant/migrate.sh
+44
-4
vagrant/base/devstack/Vagrantfile
+1
-0
vagrant/release/fullstack/Vagrantfile
+3
-0
No files found.
playbooks/edx_sandbox.yml
View file @
04f918de
...
...
@@ -45,7 +45,6 @@
-
forum
-
{
role
:
notifier
,
NOTIFIER_DIGEST_TASK_INTERVAL
:
"
5"
}
-
{
role
:
"
xqueue"
,
update_users
:
True
}
-
xqwatcher
-
role
:
ora
when
:
ENABLE_LEGACY_ORA
-
certs
...
...
playbooks/roles/edx_ansible/defaults/main.yml
View file @
04f918de
...
...
@@ -39,6 +39,10 @@ edx_ansible_venv_bin: "{{ edx_ansible_venv_dir }}/bin"
edx_ansible_user
:
"
edx-ansible"
edx_ansible_source_repo
:
https://github.com/edx/configuration.git
edx_ansible_requirements_file
:
"
{{
edx_ansible_code_dir
}}/requirements.txt"
edx_ansible_requirements_files
:
-
"
{{
edx_ansible_code_dir
}}/pre-requirements.txt"
-
"
{{
edx_ansible_code_dir
}}/requirements.txt"
# edX configuration repo
configuration_version
:
release
edx_ansible_var_file
:
"
{{
edx_ansible_app_dir
}}/server-vars.yml"
playbooks/roles/edx_ansible/tasks/deploy.yml
View file @
04f918de
...
...
@@ -10,6 +10,7 @@
requirements="{{ edx_ansible_requirements_file }}" virtualenv="{{ edx_ansible_venv_dir }}" state=present
extra_args="-i {{ COMMON_PYPI_MIRROR_URL }}"
sudo_user
:
"
{{
edx_ansible_user
}}"
with_items
:
"
{{
edx_ansible_requirements_files
}}"
-
name
:
create update script
template
:
>
...
...
playbooks/vagrant-fullstack.yml
View file @
04f918de
...
...
@@ -29,8 +29,8 @@
-
cms
-
edxlocal
-
mongo
-
{
role
:
'
edxapp'
,
celery_worker
:
True
}
-
edxapp
-
{
role
:
'
edxapp'
,
celery_worker
:
True
}
-
demo
-
{
role
:
'
rabbitmq'
,
rabbitmq_ip
:
'
127.0.0.1'
}
-
oraclejdk
...
...
util/vagrant/migrate.sh
View file @
04f918de
...
...
@@ -2,8 +2,9 @@
# defaults
CONFIGURATION
=
"fullstack"
TARGET
=
"named-release/
birch.2
"
TARGET
=
"named-release/
cypress.rc
"
INTERACTIVE
=
true
OPENEDX_ROOT
=
"/edx"
read
-d
''
HELP_TEXT
<<-
EOM
Attempts to migrate your Open edX installation to a different release.
...
...
@@ -15,6 +16,9 @@ Attempts to migrate your Open edX installation to a different release.
Migrate to the given git ref. Defaults to \"
$TARGET
\"
-y
Run in non-interactive mode (reply \"yes\" to all questions)
-r OPENEDX_ROOT
The root directory under which all Open edX applications are installed.
Defaults to \"
$OPENEDX_ROOT
\"
-h
Show this help and exit.
EOM
...
...
@@ -35,6 +39,9 @@ while getopts "hc:t:y" opt; do
y
)
INTERACTIVE
=
false
;;
r
)
OPENEDX_ROOT
=
$OPTARG
;;
esac
done
...
...
@@ -70,21 +77,54 @@ EOM
fi
fi
if
[[
$TARGET
==
*
cypress
*
&&
$INTERACTIVE
==
true
]]
;
then
cat
<<
"EOM"
WARNING WARNING WARNING WARNING WARNING
Due to the changes introduced between Birch and Cypress, you may encounter
some problems
in
this migration. If so, check this webpage
for
solutions:
https://openedx.atlassian.net/wiki/display/OpenOPS/Potential+Problems+Migrating+from+Birch+to+Cypress
Do you wish to proceed?
EOM
read
input
if
[
"
$input
"
!=
"yes"
-a
"
$input
"
!=
"y"
]
;
then
echo
"Quitting"
exit
1
else
echo
"Killing all celery worker processes."
sudo
${
OPENEDX_ROOT
}
/bin/supervisorctl stop edxapp_worker:
*
&
sleep 3
# Supervisor restarts the process a couple of times so we have to kill it multiple times.
sudo
pgrep
-lf
celery |
grep
worker | awk
'{ print $1}'
|
sudo
xargs
-I
{}
kill
-9
{}
sleep 3
sudo
pgrep
-lf
celery |
grep
worker | awk
'{ print $1}'
|
sudo
xargs
-I
{}
kill
-9
{}
sleep 3
sudo
pgrep
-lf
celery |
grep
worker | awk
'{ print $1}'
|
sudo
xargs
-I
{}
kill
-9
{}
sleep 3
sudo
pgrep
-lf
celery |
grep
worker | awk
'{ print $1}'
|
sudo
xargs
-I
{}
kill
-9
{}
sudo
-u
forum git
-C
${
OPENEDX_ROOT
}
/app/forum/.rbenv reset
--hard
fi
fi
if
[
-f
/edx/app/edx_ansible/server-vars.yml
]
;
then
SERVER_VARS
=
"--extra-vars=
\"
@
/edx
/app/edx_ansible/server-vars.yml
\"
"
SERVER_VARS
=
"--extra-vars=
\"
@
${
OPENEDX_ROOT
}
/app/edx_ansible/server-vars.yml
\"
"
fi
TEMPDIR
=
`
mktemp -d
`
chmod 777
$TEMPDIR
cd
$TEMPDIR
git clone https://github.com/edx/configuration.git
--depth
=
1
--single-branch
--branch
=
$TARGET
virtualenv venv
source
venv/bin/activate
pip install
-r
configuration/requirements.txt
echo
"edx_platform_version:
$TARGET
"
>>
vars.yml
echo
"ora2_version:
$TARGET
"
>>
vars.yml
echo
"certs_version:
$TARGET
"
>>
vars.yml
echo
"forum_version:
$TARGET
"
>>
vars.yml
echo
"xqueue_version:
$TARGET
"
>>
vars.yml
cd
configuration/playbooks
sudo
/edx/app/edx_ansible/venvs/edx_ansible/bin/
ansible-playbook
\
sudo
ansible-playbook
\
--inventory-file
=
localhost,
\
--connection
=
local
\
--extra-vars
=
\"
@../../vars.yml
\"
\
...
...
@@ -96,5 +136,5 @@ if [ $exitcode != 0 ]; then
exit
$exitcode
;
fi
cd
/
rm
-rf
$TEMPDIR
sudo
rm
-rf
$TEMPDIR
echo
"Migration complete. Please reboot your machine."
vagrant/base/devstack/Vagrantfile
View file @
04f918de
...
...
@@ -119,6 +119,7 @@ Vagrant.configure(VAGRANTFILE_API_VERSION) do |config|
if
ENV
[
'OPENEDX_RELEASE'
]
ansible
.
extra_vars
=
{
edx_platform_version:
ENV
[
'OPENEDX_RELEASE'
],
configuration_version:
ENV
[
'OPENEDX_RELEASE'
],
certs_version:
ENV
[
'OPENEDX_RELEASE'
],
forum_version:
ENV
[
'OPENEDX_RELEASE'
],
xqueue_version:
ENV
[
'OPENEDX_RELEASE'
],
...
...
vagrant/release/fullstack/Vagrantfile
View file @
04f918de
...
...
@@ -36,6 +36,9 @@ openedx_releases = {
"named-release/birch.2"
=>
{
:name
=>
"birch-fullstack-2"
,
:file
=>
"birch-2-fullstack.box"
,
},
"named-release/cypress.rc2"
=>
{
:name
=>
"cypress-fullstack-rc2"
,
:file
=>
"20150720-cypress-fullstack-rc2.box"
,
},
"named-release/cypress.rc3"
=>
{
:name
=>
"cypress-fullstack-rc3"
,
:file
=>
"20150724-cypress-fullstack-rc3.box"
,
},
...
...
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