mirror of
https://github.com/Microsoft/sql-server-samples.git
synced 2025-12-08 14:58:54 +00:00
Fix crash of mssql_conf during setup with the MSSQL 2019 cu15
Hello everybody, In the CU15 (15.0.4198.2), the mssql-conf tool was rewrited. With this sqlserver's update and the old version of mssql_conf, we get an error "usermod command not found" during the checkinstance.sh's execution. This fix adds a merge operation of setup_env dictionary with the MSSQL_SA_PASSWORD and MSSQL_PID variables
This commit is contained in:
@@ -125,9 +125,10 @@ def main():
|
||||
changed = False
|
||||
if need_to_set_up:
|
||||
setup_env = os.environ.copy()
|
||||
setup_env.update({ 'MSSQL_SA_PASSWORD': setup_sa_password, 'MSSQL_PID': setup_pid })
|
||||
subprocess.check_call(
|
||||
['/opt/mssql/bin/mssql-conf', '--noprompt', 'setup', 'accept-eula'],
|
||||
env = { 'MSSQL_SA_PASSWORD': setup_sa_password, 'MSSQL_PID': setup_pid })
|
||||
env = setup_env)
|
||||
|
||||
if name is not None:
|
||||
subprocess.check_call(['/opt/mssql/bin/mssql-conf', '--noprompt', 'set', name, value])
|
||||
|
||||
Reference in New Issue
Block a user