Chef: windows_task set's "Run only when user is logged on" if not using system account

Created on 27 Oct 2018  路  7Comments  路  Source: chef/chef

Description

If specifying a username and password, the task gets set with the "Run only when user is logged on" flag

Chef Version

14.6.47

Platform Version

Windows Server 2016 (Version 1607 OS Build 14393.447)

Replication Case

  windows_task 'my task' do
    command 'cmd /c echo see what I mean '
    action :create
    frequency :minute
    frequency_modifier 1
    execution_time_limit 28800 # 8 hours
    start_day '01/01/2018'
    start_time '00:00'
    user user
    password pass
    interactive_enabled true
  end

Client Output

Sorry, already rolled back to 14.5.33, don't have the output available.

Stacktrace

Sustaining Backlog

Most helpful comment

This will go out in Chef 14.7

All 7 comments

This will go out in Chef 14.7

I am still having this issue even with Chef 14.7

@dotcircel Are you running the same recipe?

@Vasu1105 more or less. The only difference is that the user is domain user.

@dotcircel : you also need to set interactive_enabled as false. Or you can simply remove this option, by default it is set as false.

@Nimesh-Msys That indeed was the problem. Thanks for clearing it up.

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

Was this page helpful?
0 / 5 - 0 ratings