Skip to content

Commit e2a9511

Browse files
sylwiaszunejkodkropachev
authored andcommitted
Replace SCYLLA_EXT_OPTS env var with ccm updateconf options for auth superuser config
Use set_configuration_options() (the Python API behind `ccm updateconf`) to set auth_superuser_name and auth_superuser_salted_password directly in the YAML config instead of passing them via the SCYLLA_EXT_OPTS environment variable.
1 parent d31ea37 commit e2a9511

1 file changed

Lines changed: 6 additions & 3 deletions

File tree

tests/integration/standard/test_authentication.py

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -36,13 +36,16 @@
3636

3737

3838
def setup_module():
39-
os.environ['SCYLLA_EXT_OPTS'] = '--auth-superuser-name=cassandra --auth-superuser-salted-password=$6$x7IFjiX5VCpvNiFk$2IfjTvSyGL7zerpV.wbY7mJjaRCrJ/68dtT3UpT.sSmNYz1bPjtn3mH.kJKFvaZ2T4SbVeBijjmwGjcb83LlV/'
4039
if CASSANDRA_IP.startswith("127.0.0.") and not USE_CASS_EXTERNAL:
4140
use_singledc(start=False)
4241
ccm_cluster = get_cluster()
4342
ccm_cluster.stop()
44-
config_options = {'authenticator': 'PasswordAuthenticator',
45-
'authorizer': 'CassandraAuthorizer'}
43+
config_options = {
44+
'authenticator': 'PasswordAuthenticator',
45+
'authorizer': 'CassandraAuthorizer',
46+
'auth_superuser_name': 'cassandra',
47+
'auth_superuser_salted_password': '$6$x7IFjiX5VCpvNiFk$2IfjTvSyGL7zerpV.wbY7mJjaRCrJ/68dtT3UpT.sSmNYz1bPjtn3mH.kJKFvaZ2T4SbVeBijjmwGjcb83LlV/'
48+
}
4649
ccm_cluster.set_configuration_options(config_options)
4750
log.debug("Starting ccm test cluster with %s", config_options)
4851
start_cluster_wait_for_up(ccm_cluster)

0 commit comments

Comments
 (0)