array( '127.0.0.1', 'dns-master', ), )); $response = $resolver->query("cluster-{$creds['db_cluster_id']}.mysql", 'CNAME'); $creds['host'] = $response->answer[0]->cname; } catch (Net_DNS2_Exception $e) { $creds['host'] = ""; } $config['store.type'] = 'sql'; $config['store.sql.dsn'] = sprintf('mysql:host=%s;port=%s;dbname=%s', $creds['host'], $creds['port'], $creds['name']); $config['store.sql.username'] = $creds['user']; $config['store.sql.password'] = $creds['pass']; $config['store.sql.prefix'] = 'simplesaml'; }