|
|
@ -122,9 +122,9 @@ def sendStaticFiles(project, filename):
|
|
|
|
@app.route(f'/{base_url}/hook/', methods=['GET', 'POST'])
|
|
|
|
@app.route(f'/{base_url}/hook/', methods=['GET', 'POST'])
|
|
|
|
def pull():
|
|
|
|
def pull():
|
|
|
|
if request.method == 'POST':
|
|
|
|
if request.method == 'POST':
|
|
|
|
post_data = json.loads(request.form['payload'])
|
|
|
|
import subprocess
|
|
|
|
stream = os.popen('git pull')
|
|
|
|
output = subprocess.call(['sh', '/home/kamo/public_html/update.sh'])
|
|
|
|
output = stream.read()
|
|
|
|
print(output)
|
|
|
|
return output
|
|
|
|
return output
|
|
|
|
return 'GET method not supported'
|
|
|
|
return 'GET method not supported'
|
|
|
|
|
|
|
|
|
|
|
|