CSS error after IcingaWeb2 2.10.1 upgrade

Hello all,

I read here multiple topics, but without any solution. We have problem after upgrade of IcingaWeb2 - CSS not working. Did anyone have some idea how to fix it? Thank you for any idea.

Only error: Someone messed up our responsiveness hacks, html font-family is Times New Roman

  • Icinga Web 2 version
    2.10.1

  • Used modules and their versions (System - About)
    director 1.6.2
    monitoring 2.10.1

  • Web browser used
    Google Chrome

  • Icinga 2 version used (icinga2 --version)
    version: r2.13.3-1

  • PHP version used (php --version)
    PHP 7.3.33

  • Server operating system and version
    CentOS 7

  • icinga.css

Operation on an invalid type
#0 /usr/share/icingaweb2/library/vendor/lessphp/lib/Less/Tree/Expression.php(51): Less_Tree_Operation->compile(Object(Less_Environment))
#1 /usr/share/icingaweb2/library/vendor/lessphp/lib/Less/Tree/Call.php(44): Less_Tree_Expression->compile(Object(Less_Environment))
#2 /usr/share/icingaweb2/library/vendor/lessphp/lib/Less/Tree/Expression.php(51): Less_Tree_Call->compile(Object(Less_Environment))
#3 /usr/share/icingaweb2/library/vendor/lessphp/lib/Less/Tree/Value.php(26): Less_Tree_Expression->compile(Object(Less_Environment))
#4 /usr/share/icingaweb2/library/vendor/lessphp/lib/Less/Tree/Rule.php(73): Less_Tree_Value->compile(Object(Less_Environment))
#5 /usr/share/icingaweb2/library/vendor/lessphp/lib/Less/Tree/Ruleset.php(91): Less_Tree_Rule->compile(Object(Less_Environment))
#6 /usr/share/icingaweb2/library/vendor/lessphp/lib/Less/Tree/Ruleset.php(91): Less_Tree_Ruleset->compile(Object(Less_Environment))
#7 /usr/share/icingaweb2/library/vendor/lessphp/lib/Less/Parser.php(185): Less_Tree_Ruleset->compile(Object(Less_Environment))
#8 /usr/share/icingaweb2/library/vendor/lessphp/lessc.inc.php(130): Less_Parser->getCss()
#9 /usr/share/php/Icinga/Web/LessCompiler.php(230): lessc->compile(’\n\n:root, :host …’)
#10 /usr/share/php/Icinga/Web/StyleSheet.php(218): Icinga\Web\LessCompiler->render()
#11 /usr/share/php/Icinga/Web/StyleSheet.php(258): Icinga\Web\StyleSheet->render(false)
#12 /usr/share/php/Icinga/Application/webrouter.php(60): Icinga\Web\StyleSheet::send(false, false)
#13 /usr/share/icingaweb2/public/index.php(4): require_once(’/usr/share/php/…’)
#14 {main}

… 07143em;
vertical-align: 0.05357em; }

  • icinga-php-library.noarch
    0.9.0.3.g7d42148-0.20220617.1704.el7.icinga

  • icinga-php-thirdparty.noarch
    0.10.0.17.g529bb2a-0.20220617.1708.el7.icinga

try to deactivate icinga director for moment → this verison is most likely not compatible with icingaweb2 2.10.
If the error is gone make a backup of your director database/ files or whatever you need to undo what will happen next:
Update Icinga Director to the latest version, update incubator to the latest version.

After disabling director module - everything act same.

I was also trying to switch to some other themes in WebUI, but all themes have same issue.

I found my issue:

/usr/share/icinga-php/ipl/asset/css/fontawesome.css line 104:
left: calc(var(–fa-li-width, 2em) * -1);

icingaweb2-vendor-lessphp.noarch can’t go through this line with “*”

You seem to not use the master of icingaweb2, but you’re installing icinga-php-library off of a Github release.

Have you just looked whether there is a Github release for icingaweb2 as well and expected icinga-php-library to work just fine since there was none?

Or have you installed icingaweb2 by package, but icinga-php-library not. Why not?

I am using standard icingaweb2-vendor-lessphp.noarch package for CentOS7 from Icinga official repository.

That’s a sub-package of icingaweb2 itself, not the icinga-php-library.

OK, I check it and I have icinga-php-library.noarch installed also from official repo in version: 0.9.0.3.g7d42148-0.20220617.1704.el7.icinga

Aaah, that’s a snapshot build. I guess you’ve mixed stable and snapshot repositories but installed icingaweb2 from the stable repository?

You are absolutely right, my coworker added (by mistake) both repository in same iginga channel in our Spacewalk. Thank you very much for help.

I have the same problem, fixed by doing what @silhano said (hacking fontawesome.css).

# dpkg-query -S /usr/share/icinga-php/ipl/asset/css/fontawesome.css
icinga-php-library: /usr/share/icinga-php/ipl/asset/css/fontawesome.css

# aptitude show icinga-php-library
Package: icinga-php-library              
Version: 0.9.0-1.focal
New: yes
State: installed
Automatically installed: yes
Priority: extra
Section: admin
Maintainer: Henrik Triem <henrik.triem@icinga.com>
Architecture: amd64
Uncompressed Size: 7.247 k
Depends: icinga-php-common, icinga-php-thirdparty
Recommends: php (>= 7.2), php (< 8.2), php-json, php-intl, php-pdo
Description: Icinga PHP Library for Icinga Web 2
 This project bundles all Icinga PHP libraries into one piece and can be integrated as library into Icinga Web 2.
# aptitude show icingaweb2
Package: icingaweb2                      
Version: 2.10.1-1.focal
New: yes
State: installed
Automatically installed: no
Priority: optional
Section: admin
Maintainer: Debian Nagios Maintainer Group <pkg-nagios-devel@lists.alioth.debian.org>
Architecture: all
Uncompressed Size: 18,5 M
Depends: icingaweb2-common (= 2.10.1-1.focal), php-xml | php5 (>= 5.6)
Recommends: apache2 | httpd, php | php5 (>= 5.6), php-cli | php5-cli (>= 5.6), php-curl | php5-curl (>= 5.6), php-ldap | php5-ldap (>= 5.6), php-json | php5 (>= 5.6), php-intl | php5-intl (>= 5.6), php-dom, php-mbstring, php-gd,
            php-imagick, icingacli, icinga-l10n (>= 1.1.0), icingaweb2-module-monitoring, icingaweb2-module-doc
Description: simple and responsive web interface for Icinga
 Icinga Web 2 is a very modular, fast and simple web interface for your Icinga monitoring environment. 
 
 The software will give you a web frontend for your monitoring solution, and can run additional modules, extending monitoring data, or even supplying something new to the webinterface. 
 
 This package installs the web interface with all needed dependencies.
Homepage: https://www.icinga.com

That’s the last thing you should do. We’re in the process of releasing multiple updates today. Downgrade to icinga-php-library 0.8.1 and wait with the upgrade until tomorrow or next week.