Use salt.utils.files.mkstemp() instead

This commit is contained in:
Mircea Ulinic 2017-11-15 15:14:58 +00:00
parent 6689bd3b2d
commit ce1882943d
No known key found for this signature in database
GPG key ID: 4286FAD4BACBB073

View file

@ -8,7 +8,9 @@ from __future__ import absolute_import
import os
import pickle
import logging
import tempfile
# Import Salt modules
import salt.utils.files
# This must be present or the Salt loader won't load this module
__proxyenabled__ = ['dummy']
@ -20,7 +22,7 @@ DETAILS = {}
DETAILS['services'] = {'apache': 'running', 'ntp': 'running', 'samba': 'stopped'}
DETAILS['packages'] = {'coreutils': '1.0', 'apache': '2.4', 'tinc': '1.4', 'redbull': '999.99'}
FILENAME = tempfile.mkstemp()[1]
FILENAME = salt.utils.files.mkstemp()
# Want logging!
log = logging.getLogger(__file__)