From 0f4517d7a288536bc5ee610b1766a49170720ece Mon Sep 17 00:00:00 2001 From: jassim Date: Wed, 28 Jan 2026 12:44:05 +0000 Subject: [PATCH] Update Jenkinsfile --- Jenkinsfile | 14 ++++++-------- 1 file changed, 6 insertions(+), 8 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index a7b2e59..1cf59aa 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -134,17 +134,15 @@ pipeline { cd ${BUILD_PATH} echo "Preparing deployment directory..." - sudo mkdir -p ${DEPLOY_PATH} + sudo rm -rf ${DEPLOY_PATH} - echo "Moving dist files to deployment directory..." + echo "Moving entire dist folder to /var/www/..." if [ -d "dist" ]; then - sudo rm -rf ${DEPLOY_PATH}/* - sudo cp -r dist/* ${DEPLOY_PATH}/ - echo "Dist files copied successfully" + sudo mv dist ${DEPLOY_PATH} + echo "Dist folder moved successfully to ${DEPLOY_PATH}" elif [ -d "build" ]; then - sudo rm -rf ${DEPLOY_PATH}/* - sudo cp -r build/* ${DEPLOY_PATH}/ - echo "Build files copied successfully" + sudo mv build ${DEPLOY_PATH} + echo "Build folder moved successfully to ${DEPLOY_PATH}" else echo "Error: No dist or build directory found!" exit 1