Difference between revisions of "Project Configuration Files"

From Lingoport Wiki
Jump to: navigation, search
Line 20: Line 20:
   
 
This section describes the main configuration files for each project. Other configuration files are self-explanatory.
 
This section describes the main configuration files for each project. Other configuration files are self-explanatory.
== config_vcs.properties ==
 
This file tells what Version Control System to use and the URL of the repository project for check-in and checkout.
 
A typical file looks like this:
 
<pre>
 
# Choices for VCS_TYPE are:
 
# - git
 
# - svn
 
VCS_TYPE=svn
 
 
# For GIT:
 
# Uncomment the following and fill in the properties
 
#VCS_GIT_URL=git@github.com:githubUser/gitprojectname.git
 
#VCS_GIT_BRANCH=origin/master
 
 
# For SVN
 
VCS_SVN_URL=https://svns.company.com/project/.../trunk/com.company.project
 
 
</pre>
 
 
Please note that this file <b>must</b> be a good <b>Unix</b> file: If the file was copied from a Windows system, <code>dos2unix</code> should first be run on the file. Otherwise the bash scripts may misread the attributes.
 
 
   
 
== config_email_recipients.xml ==
 
== config_email_recipients.xml ==
Line 69: Line 48:
   
 
</pre>
 
</pre>
  +
  +
== config_vcs.properties ==
  +
This file tells what Version Control System to use and the URL of the repository project for check-in and checkout.
  +
A typical file looks like this:
  +
<pre>
  +
# Choices for VCS_TYPE are:
  +
# - git
  +
# - svn
  +
VCS_TYPE=svn
  +
  +
# For GIT:
  +
# Uncomment the following and fill in the properties
  +
#VCS_GIT_URL=git@github.com:githubUser/gitprojectname.git
  +
#VCS_GIT_BRANCH=origin/master
  +
  +
# For SVN
  +
VCS_SVN_URL=https://svns.company.com/project/.../trunk/com.company.project
  +
  +
</pre>
  +
  +
Please note that this file <b>must</b> be a good <b>Unix</b> file: If the file was copied from a Windows system, <code>dos2unix</code> should first be run on the file. Otherwise the bash scripts may misread the attributes.
  +
   
   

Revision as of 21:52, 24 September 2015

Under the L10n Streamlining directory (typically ~jenkins/Lingoport_Data/L10nStreamlining), each group file structure follows this pattern:

<group_name>
├── config
│   ├── config_due_dates.xml
│   ├── config_file_cherry_picker.xml
│   ├── config_l10n_vendor.properties
│   ├── config_lingotek_locale_mapping.properties
│   ├── config_lrm_info.properties
│   └── config_pseudo_loc.xml
└── projects
    └── <project 1>
        ├── config
        │   ├── config_email_recipients.xml
        │   └── config_vcs.properties
        ...

Each of the group configuration files can be copied to the project 'config' directory if a project has a configuration different from other projects in that group. For more information on the group configuration files, visit the Group Configuration Files page.

This section describes the main configuration files for each project. Other configuration files are self-explanatory.

config_email_recipients.xml

The notification (email) mechanism uses this file to determine which emails are sent to what recipients.

The file is formatted this way:

<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<email-recipients>
        <notify-changes>
                <recipient>name1@company.com</recipient>
                <recipient>name2@company.com</recipient>
        </notify-changes>
        <prep-kit>
                <recipient>name@company.com</recipient>
        </prep-kit>
        <import-kit>
                <recipient>name1@company.com</recipient>
                <recipient>name2@company.com</recipient>
        </import-kit>
        <translators>
                <translator>name@company.com</translator>
        </translators>
        <l10nvendoradmins>
                <l10nvendoradmin>name@company.com</l10nvendoradmin>
        </l10nvendoradmins>
</email-recipients>

config_vcs.properties

This file tells what Version Control System to use and the URL of the repository project for check-in and checkout. A typical file looks like this:

# Choices for VCS_TYPE are:
#    - git
#    - svn
VCS_TYPE=svn

# For GIT:
# Uncomment the following and fill in the properties
#VCS_GIT_URL=git@github.com:githubUser/gitprojectname.git
#VCS_GIT_BRANCH=origin/master

# For SVN
VCS_SVN_URL=https://svns.company.com/project/.../trunk/com.company.project

Please note that this file must be a good Unix file: If the file was copied from a Windows system, dos2unix should first be run on the file. Otherwise the bash scripts may misread the attributes.


config_l10n_vendor.xml

This file is typically located at the Group level. However, if one project in the group needs a different way to move files back and forth with the translation team, it can be overwritten here.

When sending files for translation or getting files back from translation, the system uses config_l10n_vendor.xml. It can be set to use Lingotek or FTP out of the box. More end points can be added for a custom implementation. The following attributes have been set for an example FTP configuration (the values are for illustrative purposes only):

l10n.vendor=ftp
#FTP Attributes
## FTP inbound attributes for import kit files
ftp.in.host=company.net
ftp.in.location.path=translated_kits
ftp.in.password=strongpassword
ftp.in.port=22
#SSH, SSL or empty
ftp.in.protocol=SSH
ftp.in.username=username

# FTP outbound attributes for prep kit files
ftp.out.host=company.net
ftp.out.location.path=prep_kits
ftp.out.password=strongpassword
ftp.out.port=22
ftp.out.protocol=SSH
ftp.out.username=username


For a Lingotek configuration, the attributes would look like the following (the values are for illustrative purposes only):

#Default to lingotek but don't have any attributes. Send kit will fail and force the user to set up file
#l10n.vendor=lingotek

#Lingotek Attributes
#Contains the ids for community, workflow and access token
lingotek.api.id.access.token=293048.2034980928
lingotek.api.id.community=0219384.329084
lingotek.api.id.workflow=0923.234098
#Example callbackURL - replace job name (lingotek) with actual Jenkins job name
lingotek.api.callbackurl=http://jenkins.company.net/buildByToken/buildWithParameters?job=lingotek&token=LINGOSQUARE&
#{0} is the access.token
lingotek.api.bearer=Bearer {0}