From 3f4e2c5ada1050555775661f850e3a20d2933046 Mon Sep 17 00:00:00 2001 From: Andrew D. France Date: Wed, 23 Jul 2025 03:33:49 -0500 Subject: make was improperly being called inside the container on a project that is missing its dependencies in the lib/ directory, leading to a 'No rule to make target' error: updated Dockerfile to remove the submodule command at: ln:29: and: Jenkinsfile will use the git submodule sync command. This will ensure the agent's repository is correctly configured before fetching the submodule code: at: ln:9-17 --- Jenkinsfile | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'Jenkinsfile') diff --git a/Jenkinsfile b/Jenkinsfile index 6512f35..dccf6b9 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -7,7 +7,12 @@ pipeline { stage('Build Application Image') { steps { script { - // NOTE: Dockerfile handles submodule initialization + echo 'Initializing Git submodules...' + // First, sync the submodule URLs from .gitmodules to .git/config + sh 'git submodule sync --recursive' + // Then, initialize and update the submodules + sh 'git submodule update --init --recursive' + echo 'Building the Lush application Docker image...' sh 'docker build -t lush-app:latest .' } @@ -62,6 +67,7 @@ EOF echo 'Creating and starting the build container...' sh "docker run -d --name ${containerName} lush-app:latest sleep infinity" + // Since the Docker image now has the full source, we only need to copy the test script. echo 'Copying test script into the container...' sh "docker cp test_52.lua ${containerName}:/app/test_52.lua" -- cgit v1.2.3-59-g8ed1b