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

Anableing alternative options. #30

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

Anableing alternative options. #30

wants to merge 1 commit into from

Conversation

chevectra87
Copy link

I would like to use some options like.
Eg:

sshfs -o uid=80,gid=80,allow_other,rw,use_cache=/tmp,retries=60,default_acl=public-read,connect_timeout=30,readwrite_timeout=120,max_stat_cache_size=100000,nodnscache,del_cache,multireq_max=30,parallel_count=20" src target

I would like to use some options like.
Eg:

sshfs -o uid=80,gid=80,allow_other,rw,use_cache=/tmp,retries=60,default_acl=public-read,connect_timeout=30,readwrite_timeout=120,max_stat_cache_size=100000,nodnscache,del_cache,multireq_max=30,parallel_count=20" src target
@iszak
Copy link

iszak commented Jan 28, 2015

If I don't provide any options, will this not add an additional "-o" to the command? Will this break the execution?

source = File.expand_path(src)

status = machine.communicate.execute(
"echo \"#{password}\" | sshfs -o allow_other -o password_stdin #{username}@#{host}:#{source} #{target}",
"echo \"#{password}\" | sshfs -o allow_other -o password_stdin -o #{otheroptions} #{username}@#{host}:#{source} #{target}",
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

How about consolidate all options in a single -o, like:

options = ['allow_other', 'password_stdin'] + otheroptions
"echo ... -o #{options.merge(',')}"

@davidmpaz
Copy link

Is this working for you? How do you managed? right now if I add configuration like:
config.sshfs.options = ['follow_symlinks'] when executing: bundle exec vagrant up vagrant complain:

Vagrant::SshFS::Config:
* The following settings shouldn't exist: options

Vagrant version: 1.7.2

Thanks in advance.

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

Successfully merging this pull request may close these issues.

4 participants