~jfb-tempo-consulting/unifield-wm/packaging_py27_US-3762

« back to all changes in this revision

Viewing changes to windows/setup.nsi

  • Committer: jf
  • Date: 2018-03-21 14:20:55 UTC
  • Revision ID: jfb@tempo-consulting.fr-20180321142055-zcxxphwu2z0vufb3
US-3762: password & account openpgsvc must not expire

Show diffs side-by-side

added added

removed removed

Lines of Context:
309
309
    ${Endif}
310
310
 
311
311
    # Create the service user and service
312
 
    nsExec::ExecToLog 'net user openpgsvc 0p3npgsvcPWD /add'
 
312
    nsExec::ExecToLog 'net user openpgsvc 0p3npgsvcPWD /EXPIRES:NEVER /add'
313
313
    SimpleSC::GrantServiceLogonPrivilege openpgsvc
314
314
    nsExec::ExecToLog 'icacls "$TextPostgreSQLInstPath" /c /t /grant openpgsvc:F'
315
315
    nsExec::ExecToLog 'pgsql\bin\pg_ctl register -N Postgres \
316
316
        -U openpgsvc -P 0p3npgsvcPWD -D "$TextPostgreSQLInstPath"'
 
317
    nsExec::ExecToLog `WMIC USERACCOUNT WHERE "Name='openpgsvc'" SET PasswordExpires=FALSE`
317
318
 
318
319
    # Edit the postgresql.conf
319
320