OPNsense Forum

English Forums => Development and Code Review => Topic started by: phx on December 21, 2020, 02:48:22 am

Title: How to persist changes to core and then distribute via ISO?
Post by: phx on December 21, 2020, 02:48:22 am
This has taken me days, and I'm still not sure that I have it figured out.  I went from developing on OPNsense to developing on FreeBSD, thinking maybe that would help, but I am still not sure of where to go from here.  I cannot find all of the pieces of this documented anywhere and have been Googling and searching the forum for days.

Let me try to make this as simple and straightforward as possible...  I have a custom theme that I want to package with a full ISO build.  Do I need to actually fork the core repo and/or all of the other repos in order to get this to work?  This is my current process on a brand new system, which is currently in the process of building and taking forever because since it's a new system, I had to pull the distfiles again, but here is the process (all factory options with repos pointing to normal locations):


[upload theme to /usr/core/opnsense/www/themes]
cd /usr/core
make plist-fix
git add opnsense/www/themes/mytheme
git add plist
git commit -m 'added my own theme'
cd /usr/tools
make dvd


Should this create an ISO in make print-IMAGESDIR containing the updated files in core?  Am I missing anything?
Title: Re: How to persist changes to core and then distribute via ISO?
Post by: mimugmail on December 21, 2020, 05:55:03 am
First in tools, then make update, after this change files and plist fix and now make dvd should do it
Title: Re: How to persist changes to core and then distribute via ISO?
Post by: phx on December 21, 2020, 09:51:22 pm
This worked.  Thank you so much!
Title: Re: How to persist changes to core and then distribute via ISO?
Post by: mimugmail on December 22, 2020, 02:44:01 pm
But I'm not sure if it will survive an update, usually you build a plugin around it, like the other themes, and then include it in the Makefile to be added to the iso.