From bf683bd6ba50e80e73af85b1126bf7874a0964f4 Mon Sep 17 00:00:00 2001 From: Claude AI Date: Tue, 6 Jan 2026 08:50:18 +0000 Subject: [PATCH] feat(jenkinsfile): Add proper HTML page with version display --- apps/demo-nginx/Jenkinsfile | 61 +++++++++++++++++++++++++++++++++++-- 1 file changed, 58 insertions(+), 3 deletions(-) diff --git a/apps/demo-nginx/Jenkinsfile b/apps/demo-nginx/Jenkinsfile index 81997c8..94734d7 100644 --- a/apps/demo-nginx/Jenkinsfile +++ b/apps/demo-nginx/Jenkinsfile @@ -52,15 +52,70 @@ pipeline { steps { echo "Checking out application source code..." - sh ''' + // Create Dockerfile with actual version + sh """ cat > Dockerfile << 'EOF' FROM nginx:1.25.3-alpine -RUN echo "

Demo Nginx - Build ${BUILD_NUMBER}

Environment: Production

Version: ${IMAGE_TAG}

" > /usr/share/nginx/html/index.html +COPY index.html /usr/share/nginx/html/index.html COPY nginx.conf /etc/nginx/nginx.conf EXPOSE 80 CMD ["nginx", "-g", "daemon off;"] EOF - ''' + """ + + // Create index.html with actual version + sh """ + cat > index.html << EOF + + + + Demo Nginx + + + +
+

🚀 Demo Nginx - Build #${BUILD_NUMBER}

+

Environment: Production

+

Version: ${IMAGE_TAG}

+

+ Image: ${DOCKER_REGISTRY}/${DOCKER_REPO}/${APP_NAME}:${IMAGE_TAG} +

+
+ + +EOF + """ sh ''' cat > nginx.conf << 'EOF'