- Open your repository
- Select
Pipelines
from the side menu
- Choose
More > Other
from the choice of languages
- Commit the default
bitbucket-pipelines.yml
file
- Select
Settings
from the side menu
- Select
Environment variables
from the PIPELINE
section. See Using environment variables (First look at BitBucket Pipelines, part 3)
- Add the variables
FTP_USERNAME
, FTP_PASSWORD
and FW_REINIT
(these last two should be marked as Secured
)
- Select
Settings
from the PIPELINE
section
- Click
View bitbucket-pipelines.yml
- Replace the default content with...
image: samueldebruyn/debian-git
pipelines:
default:
- step:
script:
- apt-get update
- apt-get -qq install git-ftp
- git ftp init --user $FTP_USERNAME --passwd $FTP_PASSWORD ftp://example.com/path/to/my/site/
- curl https://example.com/?fwreinit=$FW_REINIT
- After the first run change
init
, which does an complete deploy, to push
to deploy new updates/deletions to the ftp site