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

    FOG API Question

    Scheduled Pinned Locked Moved
    FOG Problems
    3
    9
    894
    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.
    • Chris WhiteleyC
      Chris Whiteley
      last edited by

      I am trying to image with a task ID of 1 and while it does set the job to deploy, it is also supposed to include the snapins. For whatever reason, it is not pushing the snapin and I am having to do it manually. Am I missing something?

      id              : 1
      name            : Deploy
      description     : Deploy action will send an image saved on the FOG server to the client computer with all included snapins.
      icon            : download
      kernel          : 
      kernelArgs      : type=down
      type            : fog
      isAdvanced      : 0
      access          : both
      initrd          : 
      isSnapinTasking : False
      
      Tom ElliottT Chris WhiteleyC 2 Replies Last reply Reply Quote 0
      • Tom ElliottT
        Tom Elliott @Chris Whiteley
        last edited by

        @chris-whiteley
        Task Type ID 1 = Deploy? (I’m guessing that’s what you meant)

        The snapins associated to the host should be setup to automatically be deployed once the imaging task completes.

        The “isSnapinTasking” is meaning one of the 2 Snapin Only type of taskings (12 or 13)

        The host you’re trying to set the tasking with has snapins associated to it?

        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

        Chris WhiteleyC 2 Replies Last reply Reply Quote 0
        • Chris WhiteleyC
          Chris Whiteley @Tom Elliott
          last edited by

          @tom-elliott Yes, sorry Tom, I meant Task Type ID of 1. It has a snapin associated and when I set it directly from the “Tasks” Menu, it includes the Snapin.

          78b401cb-5e5d-4d25-82b2-8ebbb6596a50-image.png

          1 Reply Last reply Reply Quote 0
          • Chris WhiteleyC
            Chris Whiteley @Tom Elliott
            last edited by

            @tom-elliott Just checking back in on this one. I know you guys are busy. Thanks!

            1 Reply Last reply Reply Quote 0
            • Chris WhiteleyC
              Chris Whiteley @Chris Whiteley
              last edited by

              I am curious if anyone else knows why it doesn’t queue the Snapin?

              1 Reply Last reply Reply Quote 0
              • S
                Sebastian Roth Moderator
                last edited by Sebastian Roth

                @Chris-Whiteley Hi, found some time to play with this and I was able to create a deploy task (ID 1) with snapins as well adding "deploySnapins":true as POST paremeter:

                curl -H 'fog-api-token: ...' -H 'fog-user-token: ...' -H 'Content-Type: application/json' -X POST \
                   -d '{"taskTypeID":1, "taskName":"Deploy Task", "deploySnapins":true, "wol":true}' \
                   http://fogserver/fog/host/1/task
                

                Search for “deploySnapins” in the API doc page to find the parameters you can use and an example - though just a specific snapin tasking (ID 13) example.

                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

                Tom ElliottT Chris WhiteleyC 2 Replies Last reply Reply Quote 0
                • Tom ElliottT
                  Tom Elliott @Sebastian Roth
                  last edited by Tom Elliott

                  @sebastian-roth @Chris-Whiteley setting deploySnapins: -1 will tell the system to deploy all snapins associated with the host. If deploySnapins: true as well, it will set the value to -1 automatically. I forgot about that portion sorry.

                  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

                  Chris WhiteleyC 1 Reply Last reply Reply Quote 1
                  • Chris WhiteleyC
                    Chris Whiteley @Sebastian Roth
                    last edited by

                    @sebastian-roth I was able to add this and it worked! Thank you so much!

                    1 Reply Last reply Reply Quote 0
                    • Chris WhiteleyC
                      Chris Whiteley @Tom Elliott
                      last edited by

                      @tom-elliott Thanks Tom!

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

                      176

                      Online

                      12.0k

                      Users

                      17.3k

                      Topics

                      155.2k

                      Posts
                      Copyright © 2012-2024 FOG Project