Linux server.edchosting.com 4.18.0-553.79.1.lve.el7h.x86_64 #1 SMP Wed Oct 15 16:34:46 UTC 2025 x86_64
LiteSpeed
Server IP : 75.98.162.185 & Your IP : 216.73.216.163
Domains :
Cant Read [ /etc/named.conf ]
User : goons4good
Terminal
Auto Root
Create File
Create Folder
Localroot Suggester
Backdoor Destroyer
Readme
/
usr /
lib /
python3.6 /
site-packages /
salt /
runners /
Delete
Unzip
Name
Size
Permission
Date
Action
__pycache__
[ DIR ]
drwxr-xr-x
2022-10-11 05:09
__init__.py
26
B
-rw-r--r--
2022-05-16 09:16
asam.py
11.2
KB
-rw-r--r--
2022-05-16 09:16
auth.py
1.69
KB
-rw-r--r--
2022-05-16 09:16
bgp.py
17.5
KB
-rw-r--r--
2022-05-16 09:16
cache.py
12.72
KB
-rw-r--r--
2022-05-16 09:16
cloud.py
4.18
KB
-rw-r--r--
2022-05-16 09:16
config.py
913
B
-rw-r--r--
2022-05-16 09:16
ddns.py
8.89
KB
-rw-r--r--
2022-05-16 09:16
digicertapi.py
21.63
KB
-rw-r--r--
2022-05-16 09:16
doc.py
1.39
KB
-rw-r--r--
2022-05-16 09:16
drac.py
5.29
KB
-rw-r--r--
2022-05-16 09:16
error.py
545
B
-rw-r--r--
2022-05-16 09:16
event.py
2.1
KB
-rw-r--r--
2022-05-16 09:16
f5.py
9.58
KB
-rw-r--r--
2022-05-16 09:16
fileserver.py
17.37
KB
-rw-r--r--
2022-05-16 09:16
git_pillar.py
3.98
KB
-rw-r--r--
2022-05-16 09:16
http.py
2.35
KB
-rw-r--r--
2022-05-16 09:16
jobs.py
17.45
KB
-rw-r--r--
2022-05-16 09:16
launchd.py
1.35
KB
-rw-r--r--
2022-05-16 09:16
lxc.py
18.14
KB
-rw-r--r--
2022-05-16 09:16
manage.py
25.84
KB
-rw-r--r--
2022-05-16 09:16
mattermost.py
4.68
KB
-rw-r--r--
2022-05-16 09:16
mine.py
1.68
KB
-rw-r--r--
2022-05-16 09:16
nacl.py
8.15
KB
-rw-r--r--
2022-05-16 09:16
net.py
38.97
KB
-rw-r--r--
2022-05-16 09:16
network.py
2.42
KB
-rw-r--r--
2022-05-16 09:16
pagerduty.py
4.5
KB
-rw-r--r--
2022-05-16 09:16
pillar.py
5.14
KB
-rw-r--r--
2022-05-16 09:16
pkg.py
1.35
KB
-rw-r--r--
2022-05-16 09:16
queue.py
8.88
KB
-rw-r--r--
2022-05-16 09:16
reactor.py
4.97
KB
-rw-r--r--
2022-05-16 09:16
salt.py
4.69
KB
-rw-r--r--
2022-05-16 09:16
saltutil.py
21.5
KB
-rw-r--r--
2022-05-16 09:16
sdb.py
2.14
KB
-rw-r--r--
2022-05-16 09:16
smartos_vmadm.py
11.73
KB
-rw-r--r--
2022-05-16 09:16
spacewalk.py
9.8
KB
-rw-r--r--
2022-05-16 09:16
ssh.py
771
B
-rw-r--r--
2022-05-16 09:16
state.py
8.88
KB
-rw-r--r--
2022-05-16 09:16
survey.py
5.84
KB
-rw-r--r--
2022-05-16 09:16
test.py
1.75
KB
-rw-r--r--
2022-05-16 09:16
thin.py
1.74
KB
-rw-r--r--
2022-05-16 09:16
vault.py
10.09
KB
-rw-r--r--
2022-05-16 09:16
venafiapi.py
6.68
KB
-rw-r--r--
2022-05-16 09:16
virt.py
17.59
KB
-rw-r--r--
2022-05-16 09:16
vistara.py
5.6
KB
-rw-r--r--
2022-05-16 09:16
winrepo.py
8.57
KB
-rw-r--r--
2022-05-16 09:16
Save
Rename
""" Runner to manage Windows software repo """ # WARNING: Any modules imported here must also be added to # salt/modules/win_repo.py import logging import os import salt.loader import salt.minion import salt.template import salt.utils.files import salt.utils.gitfs import salt.utils.msgpack import salt.utils.path from salt.exceptions import CommandExecutionError, SaltRenderError log = logging.getLogger(__name__) # Global parameters which can be overridden on a per-remote basis PER_REMOTE_OVERRIDES = ("ssl_verify", "refspecs", "fallback") # Fall back to default per-remote-only. This isn't technically needed since # salt.utils.gitfs.GitBase.__init__ will default to # salt.utils.gitfs.PER_REMOTE_ONLY for this value, so this is mainly for # runners and other modules that import salt.runners.winrepo. PER_REMOTE_ONLY = salt.utils.gitfs.PER_REMOTE_ONLY GLOBAL_ONLY = ("branch",) def genrepo(opts=None, fire_event=True): """ Generate winrepo_cachefile based on sls files in the winrepo_dir opts Specify an alternate opts dict. Should not be used unless this function is imported into an execution module. fire_event : True Fire an event on failure. Only supported on the master. CLI Example: .. code-block:: bash salt-run winrepo.genrepo """ if opts is None: opts = __opts__ winrepo_dir = opts["winrepo_dir"] winrepo_cachefile = opts["winrepo_cachefile"] ret = {} if not os.path.exists(winrepo_dir): os.makedirs(winrepo_dir) renderers = salt.loader.render(opts, __salt__) for root, _, files in salt.utils.path.os_walk(winrepo_dir): for name in files: if name.endswith(".sls"): try: config = salt.template.compile_template( os.path.join(root, name), renderers, opts["renderer"], opts["renderer_blacklist"], opts["renderer_whitelist"], ) except SaltRenderError as exc: log.debug("Failed to render %s.", os.path.join(root, name)) log.debug("Error: %s.", exc) continue if config: revmap = {} for pkgname, versions in config.items(): log.debug("Compiling winrepo data for package '%s'", pkgname) for version, repodata in versions.items(): log.debug( "Compiling winrepo data for %s version %s", pkgname, version, ) if not isinstance(version, str): config[pkgname][str(version)] = config[pkgname].pop( version ) if not isinstance(repodata, dict): msg = "Failed to compile {}.".format( os.path.join(root, name) ) log.debug(msg) if fire_event: try: __jid_event__.fire_event( {"error": msg}, "progress" ) except NameError: log.error( "Attempted to fire the an event " "with the following error, but " "event firing is not supported: %s", msg, ) continue revmap[repodata["full_name"]] = pkgname ret.setdefault("repo", {}).update(config) ret.setdefault("name_map", {}).update(revmap) with salt.utils.files.fopen( os.path.join(winrepo_dir, winrepo_cachefile), "w+b" ) as repo: repo.write(salt.utils.msgpack.dumps(ret)) return ret def update_git_repos(opts=None, clean=False, masterless=False): """ Checkout git repos containing Windows Software Package Definitions opts Specify an alternate opts dict. Should not be used unless this function is imported into an execution module. clean : False Clean repo cachedirs which are not configured under :conf_master:`winrepo_remotes`. .. warning:: This argument should not be set to ``True`` if a mix of git and non-git repo definitions are being used, as it will result in the non-git repo definitions being removed. .. versionadded:: 2015.8.0 CLI Examples: .. code-block:: bash salt-run winrepo.update_git_repos salt-run winrepo.update_git_repos clean=True """ if opts is None: opts = __opts__ winrepo_dir = opts["winrepo_dir"] winrepo_remotes = opts["winrepo_remotes"] winrepo_cfg = [ (winrepo_remotes, winrepo_dir), (opts["winrepo_remotes_ng"], opts["winrepo_dir_ng"]), ] ret = {} for remotes, base_dir in winrepo_cfg: if not any( (salt.utils.gitfs.GITPYTHON_VERSION, salt.utils.gitfs.PYGIT2_VERSION) ): # Use legacy code winrepo_result = {} for remote_info in remotes: if "/" in remote_info: targetname = remote_info.split("/")[-1] else: targetname = remote_info rev = "HEAD" # If a revision is specified, use it. try: rev, remote_url = remote_info.strip().split() except ValueError: remote_url = remote_info gittarget = os.path.join(base_dir, targetname).replace(".", "_") if masterless: result = __salt__["state.single"]( "git.latest", name=remote_url, rev=rev, branch="winrepo", target=gittarget, force_checkout=True, force_reset=True, ) if isinstance(result, list): # Errors were detected raise CommandExecutionError( "Failed up update winrepo remotes: {}".format( "\n".join(result) ) ) if "name" not in result: # Highstate output dict, the results are actually nested # one level down. key = next(iter(result)) result = result[key] else: mminion = salt.minion.MasterMinion(opts) result = mminion.states["git.latest"]( remote_url, rev=rev, branch="winrepo", target=gittarget, force_checkout=True, force_reset=True, ) winrepo_result[result["name"]] = result["result"] ret.update(winrepo_result) else: # New winrepo code utilizing salt.utils.gitfs try: winrepo = salt.utils.gitfs.WinRepo( opts, remotes, per_remote_overrides=PER_REMOTE_OVERRIDES, per_remote_only=PER_REMOTE_ONLY, global_only=GLOBAL_ONLY, cache_root=base_dir, ) winrepo.fetch_remotes() # Since we're not running update(), we need to manually call # clear_old_remotes() to remove directories from remotes that # have been removed from configuration. if clean: winrepo.clear_old_remotes() winrepo.checkout() except Exception as exc: # pylint: disable=broad-except msg = "Failed to update winrepo_remotes: {}".format(exc) log.error(msg, exc_info_on_loglevel=logging.DEBUG) return msg ret.update(winrepo.winrepo_dirs) return ret