Commit 22845878 authored by Joe Chen's avatar Joe Chen
Browse files

ss

parent 3f394d76
No related merge requests found
Showing with 7 additions and 1 deletion
+7 -1
......@@ -16,6 +16,7 @@ import subprocess
import pymysql
import pymysql.cursors
import requests
import time
# Add these for debugging
import sys
import logging
......@@ -386,7 +387,7 @@ async def deploy_repository_site(ctx: Context, repository_url: str, domain_name:
# Clone the repository
result = subprocess.run(
[f"cd {code_path} && git clone {clone_url}"],
[f"cd {code_path} && git clone {clone_url} ."],
capture_output=True,
shell=True,
text=True
......@@ -403,6 +404,8 @@ async def deploy_repository_site(ctx: Context, repository_url: str, domain_name:
# Clean up failed deployment
shutil.rmtree(code_path, ignore_errors=True)
return error_msg
# Install dependencies and build
logger.debug("Installing dependencies and building project")
......@@ -428,6 +431,9 @@ async def deploy_repository_site(ctx: Context, repository_url: str, domain_name:
# Clean up failed deployment
shutil.rmtree(code_path, ignore_errors=True)
return error_msg
time.sleep(10)
# Check if build directory exists
build_dir = os.path.join(code_path, "build")
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment