-
Notifications
You must be signed in to change notification settings - Fork 14
dsf okd customize v3 7
This is a guide to customize Openshift cluster. For more information read the next:
-
Openshift docs customization for the version 3.7.
The icons for templates must measure the same as below or the images don’t show right:
-
Openshift logo
: 230px x 40px. -
Template logo
: 50px x 50px. -
Category logo
: 110px x 36px.
This is a quick example to add custom icons and categories inside openshift.
To modify the icons inside openshift, we must to modify our master-config.yaml of our openshift cluster. This file is inside the openshift container and to obtain a copy of it, we must to know what’s our openshift container name.
To obtain it, we can know it executing the next:
$ docker container ls
CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES
83a4e3acda5b openshift/origin:v3.7.0 "/usr/bin/openshift …" 6 days ago Up 6 days origin
Here we can see that the name of the container is origin. Normaly the container it’s called as origin.
This file is inside the openshift container in the next directory: /var/lib/origin/openshift.local.config/master/master-config.yaml
and we can copy it with the next command:
$ docker cp origin:/var/lib/origin/openshift.local.config/master/master-config.yaml ./
Now we have a file with the configuration of our openshift cluster.
To use our customization of devonfw Openshift, we need to copy our files inside the openshift container.
To do this we need to copy the images, scripts and stylesheets from here inside openshift
container, for example, we could put it all inside a folder called openshift.local.devonfw. On the step one we obtain the name of this container, for this example we assume that it’s called origin. Then our images are located inside openshift container and we can see an access it in /var/lib/origin/openshift.local.devonfw/images
.
$ docker cp ./openshift.local.devonfw origin:/var/lib/origin/
The master-config.yaml have a sections to charge our custom files. All these sections are inside the assetConfig
and their names are the next:
-
The custom stylessheets are into
extensionStylesheets
. -
The custom scripts are into
extensionScripts
. -
The custom images are into
extensions
.
To use all our custom elements only need to add the directory routes of each element in their appropriate section of the master-config.yaml
...
assetConfig:
...
extensionScripts:
- /var/lib/origin/openshift.local.devonfw/scripts/catalog-categories.js
extensionStylesheets:
- /var/lib/origin/openshift.local.devonfw/stylesheet/icons.css
extensions:
- name: images
sourceDirectory: /var/lib/origin/openshift.local.devonfw/images
...
...
Now we only need to copy that master-config.yaml inside openshift, and restart it to load the new configuration. To do that execute the next:
$ docker cp ./master-config.yaml origin:/var/lib/origin/openshift.local.config/master/master-config.yaml
To re-start openshift do oc cluster down
and start again your persistent openshift cluster.
-
Customize icons for Openshift.
-
Customize catalog for Openshift.
-
Openshift docs about customization.
This documentation is licensed under the Creative Commons License (Attribution-NoDerivatives 4.0 International).
-
cicd configuration
-
Manual configuration
-
Automatic configuration
-
-
Custom Services
-
Azure DevOps