diff --git a/charts/stable/redmine/docs/custom-theme.md b/charts/stable/redmine/docs/custom-theme.md index a25ab84feee..49441ca3f45 100644 --- a/charts/stable/redmine/docs/custom-theme.md +++ b/charts/stable/redmine/docs/custom-theme.md @@ -2,112 +2,91 @@ title: Custom theme for Redmine --- -This tutorial explains installing the [PurpleMine2 theme](https://github.com/mrliptontea/PurpleMine2) for the Redmine app installed from the TrueCharts catalog. +This tutorial explains installing some themes for Redmine. -## Setup configuration +## Chart deploy configuration -Default configuration with PVC storage +- Add ingress with [codeserver](https://truecharts.org/guides/addons/code-server/) addon. +- Add additional `themes` PVC persistence with `mountPath: "/usr/src/redmine/themes"` Since Redmine v6 location is changed to ./redmine/themes instead of /redmine/public/themes. +- Optional add `plugins` PVC persistence with `mountPath: "/usr/src/redmine/plugins"` This is the folder where you need to unzip your plugins if you want to use some. -Add additional app storage as PVC with Mount path `/usr/src/redmine/public/themes` +Example deployment: +```yaml +// Values.yaml +ingress: + main: + enabled: true + hosts: + - host: redmine.${BASE_DOMAIN} + integrations: + traefik: + enabled: true + certManager: + enabled: true + certificateIssuer: cloudflare -![image](./img/image1.png) +persistence: + themes: + enabled: true + mountPath: "/usr/src/redmine/themes" + plugins: + enabled: true + mountPath: "/usr/src/redmine/plugins" -You might also want to add `/usr/src/redmine/plugins` folder as PVC mount. This is the folder where you need to unzip your plugins if you want to use some. +addons: + codeserver: + enabled: true + ingress: + enabled: true + hosts: + - host: cs-redmine.${BASE_DOMAIN} + integrations: + certManager: + enabled: true + certificateIssuer: cloudflare + traefik: + enabled: true +``` -As of the time of writing the app is not running normally when created with settings RunAsUser 568 RunAsGroup 568 +## Check the application -![image](./img/image2.png) - -Changing the configuration to RunAsUser 999 RunAsGroup 999 solves the issue. -Check this [issue](https://github.com/truecharts/charts/issues/15079) for details - -Click on Save. Wait for the app to deploy. - -Open the app. Login with default credentials (see below). You will be prompted to change the password. +Check if you can open the application in your browser. Login with default credentials and you will be prompted to change the password. - User: `admin` - Password: `admin` -Go to `Administration->Settings->Display`. See that the only available theme is Default. +Go to `Administration -> Settings -> Display`. See that there are three available themes which are Default, Alternate and Classic. -## Mount PVC volumes using HeavyScript +## Add themes via codeserver addon to Redmine -Now you can close the Redmine webpage and open the TrueNAS shell. +- Browse to your codeserver addon. +- Add the themes in the `redmine\themes` folder. +- Per theme it can be different how to achive this. -We will need to mount the PVC volumes using the HeavyScript. -If you don't have [HeavyScript](https://github.com/Heavybullets8/heavy_script) installed simply run this command to install it +For example `redmine_theme_farend_bleuclair`: +- Open integrated terminal in `redmine\themes` +- `git clone https://github.com/farend/redmine_theme_farend_bleuclair.git themes/bleuclair` +- Restart Redmine for example, via add the `.Values` + ```yaml + global: + stopAll: false + ``` +- and set it back to true. -```shell -sudo curl -s https://raw.githubusercontent.com/Heavybullets8/heavy_script/main/functions/deploy.sh | bash && source "$HOME/.bashrc" 2>/dev/null && source "$HOME/.zshrc" 2>/dev/null -``` +For example `PurpleMine2`: +- Open integrated terminal in `redmine\themes` +- `wget https://github.com/mrliptontea/PurpleMine2/archive/master.zip` +- Install extension `VSCode Archive` in codeserver +- Decrompress +- Remove `master.zip` +- Move `PurpleMine2-master` directly in `themes` folder -then run +Some images from codeserver: -```shell -sudo heavyscript +![image1](./img/image1.png) -# Move on the menu to -# Application Options -> Mount Unmount PVC storage -> Mount -> Redmine +![image2](./img/image2.png) -Would you like to mount anything else? (y/N): n -``` - -## Use Moonlight Commander to copy the themes into the mounted volume - -Now the redmine themes folder is available as the system path and we need to copy the theme files there. - -I have already SMB Share setup so I copy the files into the SMB share. You can use Filebrowser app to upload the theme as well. - -So I'm downloading the theme from the [upstream repository](https://github.com/mrliptontea/PurpleMine2) - -And Unzip it to my SMB share folder. - -Now in TrueNas shell I use - -```shell -sudo mc - -``` - -To launch the moonlight commander app. I navigate to my SMB share and to the mounted PVC path and copy the files over - -![image](./img/image3.png) - -## Change permissions of the themes files - -Now we need to exit moonlight commander and navigate to the mounted themes folder in console using - -```shell -cd /mnt/mounted_pvc/redmine/redmine-persist-list-0 -ls - la -``` - -![image](./img/image4.png) - -I also copied the standard Redmine themes alternate and classic to this folder - -But you can see that all of the copied files are owned by my user and the group root. This means the Redmine will not be able to access the files. - -Change the owner of the files with the following command - -```shell -sudo chown -R root:apps PurpleMine2-master -sudo chmod -R 775 PurpleMine2-master -``` - -Repeat this commands for every theme folder you copied. And double check that owner have been changed and the permissions applied - -![image](./img/image5.png) - -## Unmount volumes and launch the app - -Now you can unmount the volume using HeavyScript command - -```shell -sudo heavyscript pvc --unmount redmine -``` - -Now run the application using `sudo heavyscript` Application Options -> Start Application -> Redmine ## Apply the theme @@ -115,4 +94,4 @@ Open the Redmine web page. Sign in with your new password for Admin. Go to `Administration` -> `Settings` -> `Display`. Pick the newly added theme -![image](./img/image6.png) +![image3](./img/image3.png) diff --git a/charts/stable/redmine/docs/img/image1.png b/charts/stable/redmine/docs/img/image1.png index 3396413fc0d..d9d5f0137f4 100644 Binary files a/charts/stable/redmine/docs/img/image1.png and b/charts/stable/redmine/docs/img/image1.png differ diff --git a/charts/stable/redmine/docs/img/image2.png b/charts/stable/redmine/docs/img/image2.png index 8cfc08ac1f3..a11e875739d 100644 Binary files a/charts/stable/redmine/docs/img/image2.png and b/charts/stable/redmine/docs/img/image2.png differ diff --git a/charts/stable/redmine/docs/img/image3.png b/charts/stable/redmine/docs/img/image3.png index a978f7b9064..4fa019220f1 100644 Binary files a/charts/stable/redmine/docs/img/image3.png and b/charts/stable/redmine/docs/img/image3.png differ diff --git a/charts/stable/redmine/docs/img/image4.png b/charts/stable/redmine/docs/img/image4.png deleted file mode 100644 index bccf686301c..00000000000 Binary files a/charts/stable/redmine/docs/img/image4.png and /dev/null differ diff --git a/charts/stable/redmine/docs/img/image5.png b/charts/stable/redmine/docs/img/image5.png deleted file mode 100644 index 6149cee05bf..00000000000 Binary files a/charts/stable/redmine/docs/img/image5.png and /dev/null differ diff --git a/charts/stable/redmine/docs/img/image6.png b/charts/stable/redmine/docs/img/image6.png deleted file mode 100644 index 92ca441ebd5..00000000000 Binary files a/charts/stable/redmine/docs/img/image6.png and /dev/null differ