Publish Over FTP1.15Minimum Jenkins requirement: 1.625.3ID: publish-over-ftp
Publish Over ...
Read Publish Over ... wiki page first
Please read Publish Over first.
Common configuration options that are documented in the Publish Over ... wiki page will not be repeated here.
- Send files to FTP servers
- The plugin is "promotion aware" see Promotions
- Publish to multiple servers in the "Post-build Actions"
- Transfer complete directory structures, partial structures or just files
- Option to delete all files in the remote directory before publishing
- Use passive (PASV) or active (PORT) transfers
- FTP can be used as a build step during the build process
- Passwords are encrypted in the configuration files and in the UI
Create host configurations in the main Jenkins configuration
From the Jenkins home page, click "Manage Jenkins" and the click on "Configure System"
Find the FTP section (as below) and click on the "Add" button next to "FTP Servers"
You should now have the configuration options as below
Fill in Name, Hostname, Username, Password and Remote Directory. see Publish Over ... for common options for Host Configurations
If you click the "Advanced..." button for a configuration, then you will make more configuration options available (see below)
Use active data mode
By default passive mode will be used to connect to the FTP Server.
In passive mode the client initiates all connections which will allow the client to send files through a firewall that has been configured to refuse all inbound connections (and does not create dynamic rules).
If you want to dissable passive mode, and have the client use PORT commands for the server to connect to the client to retieve the files, then you can check this box.
Don't make nested dirs
Do not try to create nested directories with a single MKD command
The default behaviour when creating directories is to try to create the target directory with single command, even if it is nested. If this fails, the plugin will fall back to creating each directory individually. Some FTP servers, when asked to create nested directories will respond with a success code, but will not create the directories correctly. This will result in directories being created in incorrect branches of the directory tree.
This option will not prevent the creation of nested directories, it is just a fix for badly behaved FTP servers.
Click "Test Configuration".
Add more server configurations (if required)
Configure a job to Publish Over FTP
Open a jobs main page and then click "Configure" from the left hand menu.
Find the "Send build artifacts over FTP" checkbox in the "Post-build Actions" section (as below) and click in the box.
You should now have the configuration options as below
The build will fail if you do not select any Source files to transfer
Advanced (Transfer Sets)
If you click the "Advanced..." button for a Transfer Set, then you will make more configuration options available (see below)
Transfer the files using ASCII mode.
This means that during the transfer, new lines and carriage returns will be converted from the format used on the client operating system to the format used on the servers operating system.
Do not use this option if your Source files pattern will match any binary files, as there is a good chance that binary files will be corrupted during transfer.
Delete all files and directories from the remote directory before uploading the new files.
If you click the "Advanced..." button that is immediately below the "Add Server" button, then you will make more configuration options available (see below)
Options to override the default Promotion behaviour
If you are configuring an action in a promotion, new options will become available.
- JENKINS-16681 Allow source file names and paths to contain whitespace
- Add Advanced Transfer Set option "Pattern separator"
- JENKINS-16976 Upload creates unneeded folders
- Add Advanced FTP Server option "Don't make nested dirs"
- JENKINS-13126 Option to create empty directories
- No default excludes option now available for all versions of Jenkins
- Exclude files pattern now available for all versions of Jenkins
- JENKINS-14283 Enable FTP as a build step
- JENKINS-13693 Add option to disable default excludes
- Prefix Publish over to the global config section title
- Move the defaults configuration in the global config to an Advanced section
- Advanced option to enable the FTP control channel encoding to be set for an FTP server configuration
- Enable the server credentials to be specified/overriden when configuring the publisher in a job
- JENKINS-10599 When using the Flatten files option, do not create the Remote directory if there are no files to transfer (unless Clean remote is also selected)
- JENKINS-10363 Allow the publisher default values to be changed in Manage Jenkins (on Jenkins and Hudson 1.391 - 1.395)
- Remove duplicate delete button from the system config page
- Fixed JENKINS-10268
- Add Parameterized publishing JENKINS-10006
- Add ability to retry the publish JENKINS-10094
- Moved the "Verbose output in console" option to the new Advanced section containing the other new Server options
- Remove "Give the master a NODE_NAME" option when running on Jenkins 1.414 or later
- Default the "Give the master a NODE_NAME" option to 'master' when run on a Jenkins older than 1.414
- advanced Transfer Set option to Exclude files
(option only available with Jenkins 1.407 and later)
- reduce horizontal space taken up by labels in the configuration views
- clean remote - option to delete all files in the remote directory before publishing
- passwords encrypted in config files and in UI (now requires Hudson > 1.384 or any Jenkins)
- environment variables for substitution now include build variables (including matrix build axis)
- added form validation
- removed debug logs for new configurations
- 2 new configuration options when in promotion
- Use the workspace when selecting "Source files"
- Use the time of the promotion when using "Remote directory is a date format"
- Initial release