It is important to check your translations by using a real situation where your translation is used. This page describes how to check your translations.
Translated documents are available at the OpenStack Documentation site. It is updated daily. Most contents are linked from either of:
To build a translated document, you need to update the file
doc-tools-check-languages.conf
in each repository, and
add an entry to BOOKS
like ["ja"]="install-guide"
.
Also, to build as a draft, you need to add an entry to DRAFTS
.
For a document in a stable branch, such as the installation guide for
Liberty, you need to update the file doc-tools-check-languages.conf
in the target stable branch directly.
You must add an entry to DRAFTS
, which is used as a special flag
for a stable branch.
You can check a generated document for a specified branch on http://docs.openstack.org/<branch>/<language>/<document>. For example, the link of Ubuntu Installation Guide for Liberty is http://docs.openstack.org/liberty/ja/install-guide-ubuntu/.
To add a link to a generated document, you need to update the file
www/<lang>/index.html
in the master
branch of
the openstack-manuals
repository.
Note that the web pages are published from master
branch,
which contains the pages for all releases, such as Liberty.
Therefore, you don’t need to update the file www/<lang>/index.html
in the stable branch.
We can translate the application developer documentations,
such as API Guide, as api-site
resources in Zanata.
Currently, we do not support translations for OpenStack developer documents: http://docs.openstack.org/developer/<project>
The Infrastructure and I18n teams are preparing the translation check site to check dashboard translations. It is under preparation.
Note
Currently there is no solid plan when the check site is provided.
Another convenient way is to check dashboard translations is to run DevStack in
your local environment. To run DevStack, you need to prepare local.conf
file, but no worries. Several local.conf
files are shared on the Internet
and a minimum example is shown below. From our experience, you need a machine
with two or four CPU cores, 8 GB memory and 20 GB disk to run DevStack
comfortably. If you enable just major OpenStack projects, the machine
requirement would be much smaller like 2~4GB memory.
$ BRANCH=master
$ git clone http://git.openstack.org/openstack-dev/devstack.git
$ cd devstack
$ git checkout $BRANCH
<prepare local.conf>
$ ./stack.sh
<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.
[[local|localrc]]
BRANCH=stable/newton
# NOTE: We need to specify a branch explicitly until DevStack stable branch
# is prepared. At now, swift has no stable/newton branch.
CINDER_BRANCH=$BRANCH
GLANCE_BRANCH=$BRANCH
HEAT_BRANCH=$BRANCH
HORIZON_BRANCH=$BRANCH
KEYSTONE_BRANCH=$BRANCH
NEUTRON_BRANCH=$BRANCH
NOVA_BRANCH=$BRANCH
SWIFT_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
Translations are being imported into a project repository daily, so in most cases you do not need to pull translations from Zanata manually. What you need is to pull the latest horizon code.
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
.
#!/bin/bash
# Target branch: master, stable/newton, ...
BRANCH=stable/newton
cd /opt/stack/horizon
git checkout $BRANCH
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
The other 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.
$ cd devstack
$ ./unstack.sh
<Ensure RECLONE=True in your local.conf>
$ ./stack.sh
<It takes 10 or 15 minutes>
TBD
TBD
Except where otherwise noted, this document is licensed under Creative Commons Attribution 3.0 License. See all OpenStack Legal Documents.