Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ftp password #50

Closed
wants to merge 2 commits into from
Closed

ftp password #50

wants to merge 2 commits into from

Conversation

joubertredrat
Copy link

A small contribution with a set a ftp variable to run on a script

Note: hahaha, now I request on a correct pull request, sorry for this.

@zertrin
Copy link
Owner

zertrin commented Jul 9, 2013

I don't get the point here... Why not setting the ftp password directly in the DEST="ftp://user[:password]@other.host[:port]/some_dir" ?

@joubertredrat
Copy link
Author

Really, works in this mode too, but I'm addicted to security.
If you use this option and in another console type ps aux | grep duplicity, is possible to see the duplicity command in background, and a ftp password.

root@yamato:/# ps aux | grep duplicity
root     13370  0.1  0.0  20104  1704 pts/0    S+   14:46   0:00 bash ./duplicity-backup.sh -c /root/bk/aion.conf -f
root     13379 13.3  0.6 145708 13584 pts/0    Rl+  14:46   0:01 /usr/bin/python /usr/bin/duplicity full -v3 --encrypt-key=XXXXXXX --sign-key=YYYYYYY --include=/folder/folder/folder /folder/folder/folder ftp://bk:mypassword@myhost.com/bk2/

In my case all command was executed by root, but I like to minimize risks.

Sorry for this, may refuse my push, I'm taking advantage of fix another problem I found here.

@zertrin
Copy link
Owner

zertrin commented Jul 22, 2013

I'll reopen it and include it with a little modification to make it clearer.

@zertrin zertrin reopened this Jul 22, 2013
@zertrin
Copy link
Owner

zertrin commented Jul 22, 2013

hum, but without your addition of the HOME variable

@zertrin
Copy link
Owner

zertrin commented Jul 22, 2013

Done, I merged 582416f and modified the explanation in the config file to be more accurate.

Thanks @joubertredrat for the idea.

However, I'm not considering yet to merge your following change about the HOME variable, which isn't really closely related to duplicity but with gpg instead.

@zertrin zertrin closed this Jul 22, 2013
@joubertredrat
Copy link
Author

Hi @zertrin!

I'm happy to have helped.

In fact, the HOME variable isn't a problem with GPG, at least in ubuntu.
In ubuntu, root login is disabled, then usually the first user has the power to sudo, and when he performs the sudo, even as root, the variable home remains defined as the sudo user and cron don't know this.
So in my case it was necessary to tell who the home right where is the GPG key for the duplicity-backup recognize the keyword.

In any case, the merge that I had before had no change of home variable, and this change I did yesterday, so I don't know how it got in your merge, so I sorry for that.

@zertrin
Copy link
Owner

zertrin commented Jul 22, 2013

In any case, the merge that I had before had no change of home variable, and this change I did yesterday, so I don't know how it got in your merge, so I sorry for that.

This is because you used the master branch on your side to open this pull request, and all commits added to a branch involved in a not yet merged pull request get automatically included in it.

Best practice is to always use a separate branch dedicated to do a pull request, and only include commits related to the pull request on this branch.

More generally, try to avoid using the master branch for a pull request, this makes life a lot easier for everyone ;)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants