hsato03 opened a new pull request, #13415:
URL: https://github.com/apache/cloudstack/pull/13415
### Description
The GUI whitelabel management system has been extended with the
`customLabelsPath` parameter to allow customization of UI labels. This
parameter accepts the path to a directory containing the label files, which
must be named according to their language code (e.g., `en.json` for English).
If files are stored directly on the Management Servers, the base path is
`/usr/share/cloudstack-management/webapp/`, so only the relative path needs to
be specified. Alternatively, a full URL to the directory hosting the JSON files
can be provided.
**Note:** The path or URL where the custom language files are located must
be accessible by the user.
### Types of changes
- [ ] Breaking change (fix or feature that would cause existing
functionality to change)
- [ ] New feature (non-breaking change which adds functionality)
- [ ] Bug fix (non-breaking change which fixes an issue)
- [X] Enhancement (improves an existing feature and functionality)
- [ ] Cleanup (Code refactoring and cleanup, that may add test cases)
- [ ] Build/CI
- [ ] Test (unit or integration test code)
### Feature/Enhancement Scale or Bug Severity
#### Feature/Enhancement Scale
- [ ] Major
- [X] Minor
#### Bug Severity
- [ ] BLOCKER
- [ ] Critical
- [ ] Major
- [ ] Minor
- [ ] Trivial
### Screenshots (if appropriate):
### How Has This Been Tested?
1. I created the `en.json` file in the
`/usr/share/cloudstack-management/webapp/locales/custom_labels` directory with
the following content:
```json
{
"label.name": "Nome custom"
}
```
I created the theme specifying the directory where the `en.json` file was
created:
```bash
(local) 👻 > create guitheme name="test"
customlabelspath="locales/custom_labels" css='.layout.ant-layout .header
{background: orange;}'
{
"guiThemes": {
"created": "2026-06-12T21:38:03+0000",
"css": ".layout.ant-layout .header {background: orange;}",
"customlabelspath": "locales/custom_labels",
"id": "69e6e38b-8a56-442c-9ff4-141138a37b2f",
"ispublic": true,
"name": "test",
"recursivedomains": false
}
}
```
Navigating through the ACS GUI, I verified that the label was correctly
applied:
<img width="1159" height="361" alt="label-local"
src="https://github.com/user-attachments/assets/41057b6c-020c-48cd-a51c-b7437aba4073"
/>
2. I updated the theme to use the endpoint
`http://192.168.103.1:8001/custom-labels/`:
```bash
(local) 👻 > update guitheme id=69e6e38b-8a56-442c-9ff4-141138a37b2f
customlabelspath="http://192.168.103.1:8001/custom-labels/"
{
"guiThemes": {
"created": "2026-06-12T21:38:03+0000",
"css": ".layout.ant-layout .header {background: orange;}",
"customlabelspath": "http://192.168.103.1:8001/custom-labels/",
"id": "69e6e38b-8a56-442c-9ff4-141138a37b2f",
"ispublic": true,
"name": "test",
"recursivedomains": false
}
}
```
In this endpoint, there was an `en.json` file with the following content:
```json
{
"label.name": "Server name",
"label.state": "Server state"
}
```
Navigating through the ACS GUI, I verified that the labels were also applied:
<img width="1159" height="361" alt="label-server"
src="https://github.com/user-attachments/assets/3c45d49e-32e5-41c9-a233-822a5a119b7c"
/>
#### How did you try to break this feature and the system with this change?
<!-- see how your change affects other areas of the code, etc. -->
<!-- Please read the
[CONTRIBUTING](https://github.com/apache/cloudstack/blob/main/CONTRIBUTING.md)
document -->
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]