Skip to content

Commit 0b61b1c

Browse files
qa/tasks: update python.py to use template module
The file python.py was making use of subst_vip from vip.py. The more generic template.py provides the same functionality as subst_vip plus a better more general templating system. Replace subst_vip in this file so that we can remove subst_vip in the future. Signed-off-by: John Mulligan <[email protected]>
1 parent f87e622 commit 0b61b1c

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

qa/tasks/python.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import logging
22
from teuthology import misc as teuthology
3-
from tasks.vip import subst_vip
3+
from tasks import template
44

55
log = logging.getLogger(__name__)
66

@@ -41,5 +41,6 @@ def task(ctx, config):
4141
]
4242
if sudo:
4343
args = ['sudo'] + args
44-
remote.run(args=args, stdin=subst_vip(ctx, code))
44+
code = template.transform(ctx, config, code)
45+
remote.run(args=args, stdin=code)
4546

0 commit comments

Comments
 (0)