[Solved][Question]Custom background on login page

Started by faisalusuf, May 03, 2016, 07:15:59 AM

Previous topic - Next topic
May 03, 2016, 07:15:59 AM Last Edit: May 11, 2016, 08:58:42 AM by faisalusuf
Hello,
Is this possible to add a background image for login screen? Is this in accordance with the Licence terms?


Thanks
Faisal.

Hi Faisal,

You should be able to do so with a custom theme css, I haven't tried it yet, but it should work.
For the licence it doesn't matter, the bsd license we use is pretty open, all license information is available here https://opnsense.org/about/legal-notices/

Best regards,

Ad

May 03, 2016, 10:37:29 AM #2 Last Edit: May 03, 2016, 10:43:36 AM by faisalusuf
Hi Ad,
Thanks for your response. This is the beauty of OSS indeed. Can you please guide me a little further on theme path and files For login screen only? Please note i dont have programming background i know networks/sysadmin only :) .

Cheers
F.

Hi Faisal,

I don't have a lot of time at hand to guide you trough the process, but I can provide you with some handles to dig into.

When you want to create your own theme, its probably easiest to first make a copy of ours and adjust that one.

The location of the themes is:
/usr/local/opnsense/www/themes/

Then you need to change the sass file to your needs and compile it into the main.css file, more information on sass is available no their site: http://sass-lang.com/documentation/

(source) /usr/local/opnsense/www/themes/[your theme]/assets/stylesheets/main.scss
(target) /usr/local/opnsense/www/themes/[your theme]/build/css/main.css

For customers that need custom branding we offer professional services, which also include packaging for easy installation, but with some css skills you should be able to do the basics yourself.

Best regards,

Ad

Thanks Ad. Let me try to experiment on theme :)

Hi Ad,
I tried but could not get where to start the CSS are just code while i want to change either background of login screen or add text "DEMO Firewall Deployment" and warning text in the login page footer.

Thanks

You may want to change "/usr/local/etc/inc/authgui.inc".
Keep in mind that this file will be rewritten when you install updates.