write_connection_config = async (connobj, user, dryRun) => {
  const { configFilePath, configFileDir } = get_paths(user);
  await asyncSudo(["mkdir", "-p", configFileDir], false, dryRun);
  await asyncSudo(["chown", `${user}:${user}`, configFileDir], false, dryRun);
  if (!dryRun)
    fs.writeFileSync("/tmp/.saltcorn", JSON.stringify(connobj), {
      mode: 0o600,
    });
  await asyncSudo(["mv", "/tmp/.saltcorn", configFilePath], false, dryRun);
  await asyncSudo(["chown", `${user}:${user}`, configFilePath], false, dryRun);
}
Write configuration file ${user}/.config/.saltcorn
@param connobj - DB connection object
@param user - OS user
@param dryRun
@returns {Promise<void>}