From d7521fbfe6639abd574a2f280f23fcdbacce51a4 Mon Sep 17 00:00:00 2001 From: Mike Place Date: Mon, 27 Oct 2014 16:05:25 -0600 Subject: [PATCH] Remove deprecated runas in postgre_database --- salt/states/postgres_database.py | 52 -------------------------------- 1 file changed, 52 deletions(-) diff --git a/salt/states/postgres_database.py b/salt/states/postgres_database.py index d260dab0ab..39f5503a20 100644 --- a/salt/states/postgres_database.py +++ b/salt/states/postgres_database.py @@ -30,7 +30,6 @@ def present(name, lc_ctype=None, owner=None, template=None, - runas=None, user=None, maintenance_db=None, db_password=None, @@ -62,11 +61,6 @@ def present(name, template The template database from which to build this database - runas - System user all operations should be performed on behalf of - - .. deprecated:: 0.17.0 - user System user all operations should be performed on behalf of @@ -95,23 +89,6 @@ def present(name, 'added in 0.17.0', _dont_call_warnings=True ) - if runas: - # Warn users about the deprecation - ret.setdefault('warnings', []).append( - 'The \'runas\' argument is being deprecated in favor of \'user\', ' - 'please update your state files.' - ) - if user is not None and runas is not None: - # user wins over runas but let warn about the deprecation. - ret.setdefault('warnings', []).append( - 'Passed both the \'runas\' and \'user\' arguments. Please don\'t. ' - '\'runas\' is being ignored in favor of \'user\'.' - ) - runas = None - elif runas is not None: - # Support old runas usage - user = runas - runas = None db_args = { 'maintenance_db': maintenance_db, @@ -188,7 +165,6 @@ def present(name, def absent(name, - runas=None, user=None, maintenance_db=None, db_password=None, @@ -213,11 +189,6 @@ def absent(name, db_port Database port if different from config or default - runas - System user all operations should be performed on behalf of - - .. deprecated:: 0.17.0 - user System user all operations should be performed on behalf of @@ -227,29 +198,6 @@ def absent(name, 'changes': {}, 'result': True, 'comment': ''} - salt.utils.warn_until( - 'Lithium', - 'Please remove \'runas\' support at this stage. \'user\' support was ' - 'added in 0.17.0', - _dont_call_warnings=True - ) - if runas: - # Warn users about the deprecation - ret.setdefault('warnings', []).append( - 'The \'runas\' argument is being deprecated in favor of \'user\', ' - 'please update your state files.' - ) - if user is not None and runas is not None: - # user wins over runas but let warn about the deprecation. - ret.setdefault('warnings', []).append( - 'Passed both the \'runas\' and \'user\' arguments. Please don\'t. ' - '\'runas\' is being ignored in favor of \'user\'.' - ) - runas = None - elif runas is not None: - # Support old runas usage - user = runas - runas = None db_args = { 'maintenance_db': maintenance_db,