Uploaded image for project: 'Puppet'
  1. Puppet
  2. PUP-9358

Setting Windows group gid fails on second run

    Details

    • Type: Bug
    • Status: Ready for Engineering
    • Priority: Normal
    • Resolution: Unresolved
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: None
    • Labels:
    • Template:
      PUP Bug Template
    • Acceptance Criteria:
      Hide

      Report an error when the user tries to set a gid initially.
      Unit test
      Code change

      Show
      Report an error when the user tries to set a gid initially. Unit test Code change
    • Team:
      Windows
    • Story Points:
      1
    • Sprint:
      Windows Hopper
    • Method Found:
      Needs Assessment
    • QA Risk Assessment:
      Needs Assessment

      Description

      Puppet Version: 6.0.2
      Puppet Server Version: 2019.0.0
      OS Name/Version: Windows Server 2012 R2

      group { gid => 1000 } works fine when creating the group, but fails on the second run.

      PS C:\Program Files\Puppet Labs> .\Puppet\bin\puppet.bat resource group foobar ensure=present gid=1000
      Notice: /Group[foobar]/ensure: created
      group { 'foobar':
        ensure => 'present',
        gid    => 'S-1-5-21-3100550808-3956625304-3008681921-1010',
      }
      PS C:\Program Files\Puppet Labs> .\Puppet\bin\puppet.bat resource group foobar ensure=present gid=1000
      Error: gid is read-only
      Error: /Group[foobar]/gid: change from 'S-1-5-21-3100550808-3956625304-3008681921-1010' to 1000 failed: gid is read-onlygroup { 'foobar':
        ensure => 'present',
        gid    => 'S-1-5-21-3100550808-3956625304-3008681921-1010',
      } 

      Desired Behavior:

      Either fail on the first run, or don't fail on either run. I prefer the second option because it's convenient, but it's probably Wrong. ¯_(ツ)_/¯

      It could just emit a warning but otherwise work.

      Actual Behavior:

      It works and then fails.

        Attachments

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              daniel.parks Daniel Parks
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:

                Zendesk Support