Benutzer-Werkzeuge

Webseiten-Werkzeuge


public:automated


CAUTION: This manipulates system files! USAGE AT OWN RISK!

Fully automated custom logo and removal of the subscription warning after upgrade


Here you go:
Click on code to copy to clipboard

Create a folder custom in your /root directory. Copy your custom logo.png (size 170x30px) in /root/custom/.
Login as root to your Proxmox VE via SSH
Write a script /root/custom/post-update.sh:

| post-update.sh
#!/bin/sh
 
#optional backup original logo
cp /usr/share/pve-manager/images/proxmox_logo.png /usr/share/pve-manager/images/proxmox_logo.png.bak &
#copy custom logo
cp /root/custom/logo.png /usr/share/pve-manager/images/proxmox_logo.png &
#backup original proxmoxlib.js
cp /usr/share/javascript/proxmox-widget-toolkit/proxmoxlib.js /usr/share/javascript/proxmox-widget-toolkit/proxmoxlib.js.bak &
#modify existing proxmoxlib.js
sed -i 's|Ext\.Msg\.show({|void({ //Ext\.Msg\.show({|' /usr/share/javascript/proxmox-widget-toolkit/proxmoxlib.js;
 
exit 0

Make it executable with chmod +x /root/custom/post-update.sh

Create an APT update-hook /etc/apt/apt.conf.d/99postupdate

| 99postupdate
DPkg::Post-Invoke {"sh /root/custom/post-update.sh";};


Custom logo will be in place and subscription warning will be disbaled after every upgrade.

Reference:
Manpage "sed"
Manpage APT.CONF


Enjoy!

public/automated.txt · Zuletzt geändert: 2024/12/07 10:51 von gerson

Seiten-Werkzeuge