Introduce Regioning
Overview
With GitLab's product being used in multiple countries and regions around the world, we need to ensure we maintain compliance across all of the respective countries and regions where we operate or license our software. Recently both the GitLab Inc and JiHu teams have started discussing this across several MRs/issues: gitlab-org/gitlab!65230 (merged) !42 (merged) gitlab-org/gitlab!65148 (merged) #120 (closed).
The purpose of this issue is to outline the approach our companies will take to regioning.
Proposal
We'd like to introduce the concept of regioning where different text / content can be shown / hidden depending on a user's region.
Region
Regions defines a geographic location (i.e. USA, Canada) where you will be using GitLab.
There should be two types of regioning:
- Instance-level regioning
- User-level regioning.
Instance-level regioning will define the default experience used across the entire GitLab Instance, including for logged out users or for users who have not set a region. Once a user has set their region, their User-level region should override the Instance-level region.
Regions should be set when a new GitLab instance is setup or when a new user registers for a GitLab account.
- Instance-level regions should be configurable in an Instance's Admin Settings page: https://docs.gitlab.com/ee/user/admin_area/settings/index.html
- User-level regions should be configuration in a User Preference's page: https://gitlab.com/-/profile/preferences or
Language Internationalization (i18n)
Language defines the language translation (i.e. English, French) you'd like to use for GitLab.
Language can currently be set in a User Preference's page: https://gitlab.com/-/profile/preferences.
GitLab currently supports many languages, for details on how Internationalization (i18n) works, please read: https://docs.gitlab.com/ee/development/i18n/. Language translates are kept in
Edition (CE / EE / JH)
We currently have three editions of GitLab: CE, EE, and JH.
- CE and EE are maintained by GitLab Inc. Proprietary code and EE specific overrides are kept in /ee.
- JH is maintained by JiHu. Proprietary code and JH specific overrides are kept in /jh.
Implementation
- JiHu Edition will be responsible for the regions of China, Hong Kong, Macau available. JiHu edition can be set to any language including English, Chinese, Spanish, etc.
- Community Edition and Enterprise Edition will be responsible for the regions of everywhere aside from China, Hong Kong, Macau. CE/EE can be set to any language including English, Chinese, Spanish, etc.
- The same language, can be translated differently between JH and CE/EE. JH can have it's own region specific i18n files which override the CE/EE defaults.
- All contents related to region specific changes go to the edition specifically, meaning that JH contents should go to jh/ directory.
Next Steps
-
Solicit feedback -
Move forward with implementation