feat: for v0.29
This commit is contained in:
@@ -14,6 +14,7 @@ if [ ! -f "$samRoot/index.php" ]; then
|
||||
mkdir -p $samRoot
|
||||
chown -R www-data:www-data $wwwRoot
|
||||
gosu www-data git clone $gameGitPath $samRoot
|
||||
gosu www-data git checkout $gameGitBranch
|
||||
fi
|
||||
|
||||
if [ "$HIDCHE_IMAGE_USE_INTERNAL" = "yes" ] && [ ! -d "$imageRoot" ]; then
|
||||
|
||||
@@ -2,6 +2,7 @@
|
||||
#서버 git 주소.
|
||||
#만약 https:// 대신 ssh://로 시작하는 주소를 사용하는 경우 app/id_ecdsa, app/known_host 에 ecdsa 개인키와 ssh값을 추가할 것.
|
||||
gameGitPath=ssh://git@storage.hided.net:2525/devsam/core.git
|
||||
gameGitBranch=devel
|
||||
imgGitPath=ssh://git@storage.hided.net:2525/devsam/image.git
|
||||
|
||||
#게임 시간대.
|
||||
|
||||
@@ -45,13 +45,17 @@ if not os.path.exists(indexPHP):
|
||||
while True:
|
||||
try:
|
||||
r = requests.head('http://web/sam/f_install/j_install_status.php')
|
||||
if r.status_code == 200:
|
||||
if r.status_code == 503 or r.status_code == 500:
|
||||
b = requests.get('http://web/sam/install.php', timeout=60000)
|
||||
elif r.status_code == 200:
|
||||
break
|
||||
except Exception:
|
||||
pass
|
||||
print("Waiting for web connection...", flush=True)
|
||||
time.sleep(2)
|
||||
|
||||
requests.get('http://web/sam/install.php', timeout=60000) #NPM
|
||||
|
||||
while True:
|
||||
result = subprocess.call('nc -z -v -w30 db 3306'.split(' '), stderr=subprocess.STDOUT)
|
||||
if result == 0:
|
||||
@@ -109,8 +113,8 @@ serverList.reverse()
|
||||
for serverName in serverList:
|
||||
updateResult = session.post('http://web/sam/j_updateServer.php', {
|
||||
'server':serverName,
|
||||
'target':'origin/devel'
|
||||
}, headers=headers)
|
||||
'target':'origin/'+env['gameGitBranch']
|
||||
}, headers=headers, timeout=60000)
|
||||
print(serverName, updateResult.text, flush=True)
|
||||
|
||||
db_pw = hash_password(serverName+env['HIDCHE_PW_SALT'], env['MARIADB_ROOT_PASSWORD'])[:32]
|
||||
|
||||
Reference in New Issue
Block a user