Merge "Update Horizon translation check using DevStack"
This commit is contained in:
commit
2c74d5516f
12
checksite/horizon-reload.sh
Normal file
12
checksite/horizon-reload.sh
Normal file
@ -0,0 +1,12 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
# Target branch: master, stable/newton, ...
|
||||||
|
BRANCH=master
|
||||||
|
|
||||||
|
cd /opt/stack/horizon
|
||||||
|
git remote update origin
|
||||||
|
git merge origin/$BRANCH
|
||||||
|
./run_tests.sh --compilemessages -N
|
||||||
|
DJANGO_SETTINGS_MODULE=openstack_dashboard.settings python manage.py collectstatic --noinput
|
||||||
|
DJANGO_SETTINGS_MODULE=openstack_dashboard.settings python manage.py compress --force
|
||||||
|
sudo service apache2 reload
|
29
checksite/local.conf
Normal file
29
checksite/local.conf
Normal file
@ -0,0 +1,29 @@
|
|||||||
|
[[local|localrc]]
|
||||||
|
BRANCH=master
|
||||||
|
|
||||||
|
# When OS_CLOUD envvar is set, DevStack will be confused.
|
||||||
|
unset OS_CLOUD
|
||||||
|
|
||||||
|
# Ensure to fetch the latest repository when rerunning DevStack
|
||||||
|
RECLONE=True
|
||||||
|
|
||||||
|
# Translation check site usually does not use tempest.
|
||||||
|
disable_service tempest
|
||||||
|
|
||||||
|
enable_service heat h-api h-api-cfn h-api-cw h-eng
|
||||||
|
enable_service s-proxy s-object s-container s-account
|
||||||
|
|
||||||
|
enable_plugin neutron https://git.openstack.org/openstack/neutron $BRANCH
|
||||||
|
enable_service q-qos
|
||||||
|
|
||||||
|
enable_plugin neutron-vpnaas https://git.openstack.org/openstack/neutron-vpnaas $BRANCH
|
||||||
|
|
||||||
|
LOGFILE=$DEST/logs/devstack.log
|
||||||
|
SCREEN_HARDSTATUS="%{= rw} %H %{= wk} %L=%-w%{= bw}%30L> %n%f %t*%{= wk}%+Lw%-17< %-=%{= gk} %y/%m /%d %c"
|
||||||
|
LOGDAYS=2
|
||||||
|
IDENTITY_API_VERSION=3
|
||||||
|
|
||||||
|
ADMIN_PASSWORD=change_me
|
||||||
|
MYSQL_PASSWORD=change_me
|
||||||
|
RABBIT_PASSWORD=change_me
|
||||||
|
SERVICE_PASSWORD=change_me
|
@ -64,30 +64,70 @@ Translation check site
|
|||||||
The infra and i18n teams are preparing the translation check site
|
The infra and i18n teams are preparing the translation check site
|
||||||
to check dashboard translations. It is under preparation.
|
to check dashboard translations. It is under preparation.
|
||||||
|
|
||||||
|
.. note::
|
||||||
|
|
||||||
|
Currently there is no solid plan when the check site is provided.
|
||||||
|
|
||||||
Running DevStack
|
Running DevStack
|
||||||
~~~~~~~~~~~~~~~~
|
~~~~~~~~~~~~~~~~
|
||||||
|
|
||||||
Another convenient way is to check dashboard translations is to run
|
Another convenient way is to check dashboard translations is to run DevStack in
|
||||||
DevStack in your local environment. To run DevStack, you need to
|
your local environment. To run DevStack, you need to prepare ``local.conf``
|
||||||
prepare ``local.conf`` file, but no worries. Several ``local.conf``
|
file, but no worries. Several ``local.conf`` files are shared on the Internet
|
||||||
files are shared, for example [#]_. From our experience, you need a
|
and an minimum example is shown below. From our experience, you need a machine
|
||||||
machine with two or four CPU core, 8 GB memory and 20 GB disk to run
|
with two or four CPU cores, 8 GB memory and 20 GB disk to run DevStack
|
||||||
DevStack comfortablely. If you enable just major OpenStack projects,
|
comfortablely. If you enable just major OpenStack projects, the machine
|
||||||
the machine requirement would be much smaller like 2~4GB memory.
|
requirement would be much smaller like 2~4GB memory.
|
||||||
|
|
||||||
.. code-block:: console
|
.. code-block:: console
|
||||||
|
|
||||||
|
$ BRANCH=master
|
||||||
$ git clone http://git.openstack.org/openstack-dev/devstack.git
|
$ git clone http://git.openstack.org/openstack-dev/devstack.git
|
||||||
$ cd devstack
|
$ cd devstack
|
||||||
|
$ git checkout $BRANCH
|
||||||
<prepare local.conf>
|
<prepare local.conf>
|
||||||
$ ./stack.sh
|
$ ./stack.sh
|
||||||
<wait and wait... it takes 20 or 30 minutes>
|
<wait and wait... it takes 20 or 30 minutes>
|
||||||
|
|
||||||
|
Replace ``$BRANCH`` with an appropriate branch such as ``master``,
|
||||||
|
``stable/newton`` or ``stable/mitaka``.
|
||||||
|
|
||||||
|
The following is an example of ``local.conf`` for Newton release which runs
|
||||||
|
core components (keystone, nova, glance, neutron, cinder), horizon, swift and
|
||||||
|
heat. The components which the main horizon code supports are chosen.
|
||||||
|
|
||||||
|
.. literalinclude:: ../../checksite/local.conf
|
||||||
|
:language: ini
|
||||||
|
|
||||||
|
Import latest translations
|
||||||
|
++++++++++++++++++++++++++
|
||||||
|
|
||||||
Translations are being imported into a project repository daily,
|
Translations are being imported into a project repository daily,
|
||||||
so in most cases you do not need to pull translations from Zanata
|
so in most cases you do not need to pull translations from Zanata
|
||||||
manually.
|
manually. What you need is to pull the latest horizon code.
|
||||||
|
|
||||||
.. [#] https://gist.github.com/amotoki/b5ca4affd768177ed911
|
If you have a machine running DevStack, there are two ways.
|
||||||
|
|
||||||
|
One way is to update the horizon code only.
|
||||||
|
The following shell script fetches the latest horizon code,
|
||||||
|
compiles translation message catalogs and reloads the apache httpd server.
|
||||||
|
Replace ``$BRANCH`` with an appropriate branch such as ``master``,
|
||||||
|
``stable/newton`` or ``stable/mitaka``.
|
||||||
|
|
||||||
|
.. literalinclude:: ../../checksite/horizon-reload.sh
|
||||||
|
:language: bash
|
||||||
|
|
||||||
|
Another way is to rerun DevStack. Ensure to include ``RECLONE=True`` in
|
||||||
|
your ``local.conf`` before running ``stack.sh`` again so that DevStack
|
||||||
|
retrieve the latest codes of horizon and other projects.
|
||||||
|
|
||||||
|
.. code-block:: console
|
||||||
|
|
||||||
|
$ cd devstack
|
||||||
|
$ ./unstack.sh
|
||||||
|
<Ensure RECLONE=True in your local.conf>
|
||||||
|
$ ./stack.sh
|
||||||
|
<It takes 10 or 15 minutes>
|
||||||
|
|
||||||
CLI (command line interface)
|
CLI (command line interface)
|
||||||
----------------------------
|
----------------------------
|
||||||
|
Loading…
x
Reference in New Issue
Block a user