Postdownloadscripts Requirements



  • Server
    • FOG Version: RC37
    • OS: CentOS 7.2.1511
    Client
    • Service Version: 0.11.7
    • OS: Windows
    Description

    When exactly do Postdownloadscripts run?

    What is required on a Windows host / FOG server for Postdownloadscripts to work?


  • Moderator

    @Quazz yeah, I just use snapins because it’s easier. Click click click and the exact group I’m targeting has the needed snapin assigned.


  • Moderator

    If you want certain things to run on only certain hosts, you need to either create a very intelligent script or use snapins which are already designed for that.


  • Moderator

    To build your scripts, you would work in debug mode and get them pieced together in there, then save them to the server from there. While in debug mode, you can get a listing of all variables with printenv and also George worked hard to get some more data exposed to the FOS engine.

    Even though fog.postdownload runs for every deploy, you can within your script create conditionals for only this computer or that model and so on.

    A popular use is to place driver files in the needed spot.

    Other uses might include - putting specific installers onto the c: volume, placing configuration files for software, or as George does, modifying existing files on the disk like the unattend.xml file to set within it the proper computer name among other things.


  • Senior Developer

    As I think the main information has been discussed and the originating question has been solved, I’ve gone ahead and done that to the “status”.


  • Moderator

    @sudburr To repeat what Tom said.

    The fog.postdownload script gets called on each deployment. This is the master script where the deployment admin can choose what happens, its a bit of an external hook into the deployment process. The important thing to remember here is the fog.postdownload script runs from the FOS engine (from the perspective of the target computer). If you need access to resources you need to mount them in your fog post install script. Be it local disk or nfs mounts back to the fog server. The post download scripts must be programmed in bash to execute on the target computer. This is linux so you may not run any windows commands in the post install scripts like DISM.exe.


  • Senior Developer

    @sudburr It’s only referenced in the inits. The control is only handled by the person who creates the scripts.

    It is called on EVERY deploy tasking.



  • Looking at the FOG Wiki for more answers, but it has only three pages that use the word ‘Postdownloadscripts’ and only one of those, ‘Auto driver install’, is actually about using it.

    Unfortunately that page, ‘Auto driver install’, says it requires two files at a login-barred external site to work.



  • Is there any control on which Postdownloadscripts the FOS init engine runs post-imaging or does it simply and only run the script ‘fog.postdownload’ universally after any imaging on any host?

    Is the Postdownloadscripts (fog.postdownload) run by a ‘Deploy Image’ action that is invoked locally at the host or is it just referenced when imaging through the FOG Web GUI?


  • Senior Developer

    There’s 0 requirement on WIndows Hosts. Post download scripts from from the “fos” init engine. They’re nothing more than shell scripts that perform actions.

    What you do with them is totally up to you.

    Requirement on the server, I suppose, is just to have the postdownloadscripts folder and call them how you require them within the fog.postdownload script.

    Really, you can just code everything you want directly in the fog.postdownload script (but that can be messy if you are doing a lot of things with these scripts.)


Log in to reply
 

765
Online

39.3k
Users

11.0k
Topics

104.4k
Posts

Looks like your connection to FOG Project was lost, please wait while we try to reconnect.