How to Create a Jenkins Job that Compresses Files into a ZIP Archive and Stores it as an Artifact?
Share
Condition for Create a Jenkins Job that Compresses Files into a ZIP Archive and Stores it as an Artifact
Description: This task demonstrates how Jenkins can automatically create files, compress them into a ZIP file, and store the ZIP output as a downloadable build artifact.
Steps
Step 1 — Open Jenkins Dashboard
Open your browser and go to:
http://localhost:8080
Step 2 — Create a New Freestyle Job
Click New Item
Type job name: zip-files
Select Freestyle project → Click OK
Step 3 — Add a Build Step to Run Shell Commands
Scroll to Build
Click Add build step → Select Execute Shell
Step 4 — Enter Script to Create and Compress Files
Paste the following: