• Recent
    • Unsolved
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    • Register
    • Login

    Automating FOG installfog.sh – setting interface, IP, and hostname

    Scheduled Pinned Locked Moved General Problems
    6 Posts 3 Posters 301 Views
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • raulR
      raul
      last edited by

      I’m using Ansible to provision a machine and fully configure and install a FOG server automatically.

      I’m looking for a way to automate installfog.sh, because so far I haven’t found a way to do it other than manually. The only way I’ve seen to run it automatically is with the -Y / --autoaccept option, which just auto-accepts defaults.

      I’ve checked the ‘FOG installer command line options’, but none seem to allow setting the network interface, IP, or hostname directly.

      The goal is to provide these three values (interface, IP, and hostname) as parameters so the IPXE server is fully set up automatically.

      Any suggestions or possible solutions would be greatly appreciated.

      Tom ElliottT K 2 Replies Last reply Reply Quote 0
      • Tom ElliottT
        Tom Elliott @raul
        last edited by Tom Elliott

        @raul You can set all the variables before you call the installfog.sh file

        for example if you need to set the IP/Interface you can run:

        ipaddress="10.255.20.1" interface="eno2" ./installfog.sh -y
        

        I would take a look at the .fogsettings file to know what variables are checked during install.

        There’s likely more that could be set as well, but this is one method you can perform what you want automatedly.

        Please help us build the FOG community with everyone involved. It's not just about coding - way more we need people to test things, update documentation and most importantly work on uniting the community of people enjoying and working on FOG! Get in contact with me (chat bubble in the top right corner) if you want to join in.

        Web GUI issue? Please check apache error (debian/ubuntu: /var/log/apache2/error.log, centos/fedora/rhel: /var/log/httpd/error_log) and php-fpm log (/var/log/php*-fpm.log)

        Please support FOG if you like it: https://wiki.fogproject.org/wiki/index.php/Support_FOG

        raulR 1 Reply Last reply Reply Quote 0
        • K
          KMEH @raul
          last edited by

          @raul I have an Ansible role which does something akin to what you’re trying to do here:
          https://forgejo.cwavs.xyz/Cwavs/ansible-role-fog it might be worth taking a look and seeing if it helps give you any ideas on how to solve your problem. Happy to answer questions about it.

          1 Reply Last reply Reply Quote 0
          • raulR
            raul @Tom Elliott
            last edited by

            @Tom-Elliott I’ve managed to automate the initial part of FOG installation by passing the parameters(IP, interface, hostname, etc) before running installfog.sh, and that part works fine.

            But when the installation reaches the web interface step where you have to click “Install/Update Now”, it seems that still needs to be done manually. I haven’t found any way to automate the process completely beyond this point.

            Has anyone been able to fully automate this step?

            Tom ElliottT 1 Reply Last reply Reply Quote 0
            • Tom ElliottT
              Tom Elliott @raul
              last edited by

              @raul The -y parameter will allow that to go through. I use it all the time specifically for this one piece.

              Please help us build the FOG community with everyone involved. It's not just about coding - way more we need people to test things, update documentation and most importantly work on uniting the community of people enjoying and working on FOG! Get in contact with me (chat bubble in the top right corner) if you want to join in.

              Web GUI issue? Please check apache error (debian/ubuntu: /var/log/apache2/error.log, centos/fedora/rhel: /var/log/httpd/error_log) and php-fpm log (/var/log/php*-fpm.log)

              Please support FOG if you like it: https://wiki.fogproject.org/wiki/index.php/Support_FOG

              raulR 1 Reply Last reply Reply Quote 0
              • raulR
                raul @Tom Elliott
                last edited by

                @Tom-Elliott Do the values in .fogsettings get applied only the first time installfog.sh is executed, or are they supposed to be applied on every subsequent run as well?
                In my case, updating .fogsettings after the initial installation doesn’t seem to change anything, so I want to confirm whether this is expected behavior or if I’m missing something.

                1 Reply Last reply Reply Quote 0
                • 1 / 1
                • First post
                  Last post

                150

                Online

                12.5k

                Users

                17.5k

                Topics

                156.2k

                Posts
                Copyright © 2012-2026 FOG Project