Mirror: Not connected - When i try my ftp deploy pipeline

Hi there,

I newest in pipelines.
I test to try deploying my code in my hosting server via ftp but i have a problem.

I have this:

deploy:
stage: deploy
only:
    - master
script:
    - apt-get update -qq && apt-get install -y -qq lftp
    - lftp -c "set ftp:ssl-allow no; open -u $USERNAME,$PASSWORD $HOST; mirror -Rnev --ignore-time --parallel=10 --exclude-glob .git* --exclude .git/"

And the job says:

...
Unpacking lftp (4.6.0-1+deb8u1) ...
Setting up lftp (4.6.0-1+deb8u1) ...
$ lftp -c "set ftp:ssl-allow no; open -u $USERNAME,$PASSWORD $HOST; mirror -Rnev --ignore-time --parallel=10 --
exclude-glob .git* --exclude .git/"
mirror: Not connected
ERROR: Job failed: exit code 1

What do I do wrong?

thx!
rgrds!

Hi aletsh,

Got exactly the same issue. Could you solve it and how?

rgrds!
Christian

Same error here! you solved it ?

Hi @svinesh3691 @kontakt

Works for me!
My hosting its on namecheap.

Try this in your “.gitlab-ci.yml” file:
deploy:
stage: deploy
only:
- master
script:
- apt-get update -qq && apt-get install -y -qq lftp
- lftp -c “set ftp:ssl-allow no; open -u $USERNAME,$PASSWORD $HOST; mirror -Rnev --ignore-time --parallel=10 --exclude-glob .git* --exclude .git/”

$USERNAME, $PASSWORD and $HOST it has to be created on:

  • Access to your git project repository
  • Settings --> CI / CD
  • Environment variables
  • Add this variables without dollar simbol ($) and set the value
    – > Save!

GL!
Enjoy!
Rgrds

@altesh,
I have done all this…It worked till yesterday but today I just slightly changes variables names to add new envs and it stops working. Crazy. I think the runner is not parsing my new variable!?