Revert "Passing calling commands with subprocess."
This reverts commit beb0312c688d908f065c46a91f92c5125ed6a796.
This commit is contained in:
parent
beb0312c68
commit
2181182f26
@ -5,7 +5,6 @@
|
||||
vars_files:
|
||||
- domainpwd.vault
|
||||
roles:
|
||||
- checkver
|
||||
- init
|
||||
- base
|
||||
- custom
|
||||
|
@ -1,6 +1,5 @@
|
||||
---
|
||||
|
||||
- include: init.yml
|
||||
when: live_repover != ansible_local.checksum.repover
|
||||
tags:
|
||||
- init
|
||||
|
@ -1,6 +1,6 @@
|
||||
#!/usr/bin/env python
|
||||
|
||||
from subprocess import Popen, PIPE, STDOUT
|
||||
from os import popen
|
||||
from os.path import isfile
|
||||
from json import dumps, loads
|
||||
from hashlib import md5
|
||||
@ -15,9 +15,8 @@ local_repo_hash = ''
|
||||
|
||||
live_repo_hash = ''
|
||||
# Getting live versions for repo
|
||||
p = Popen("pushd %s >/dev/null; git log --pretty=oneline -1 | cut -d' ' -f 1; popd > /dev/null" % repo_path, shell=True, stdout=PIPE, stderr=STDOUT)
|
||||
output = p.communicate()[0]
|
||||
live_repo_hash = output.strip()
|
||||
repover = popen("pushd %s >/dev/null; git log --pretty=oneline -1 | cut -d' ' -f 1; popd > /dev/null" % repo_path)
|
||||
live_repo_hash = repover.read().strip()
|
||||
repover.close()
|
||||
|
||||
live_pkg_hash = ''
|
||||
|
Loading…
x
Reference in New Issue
Block a user