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

Unable to change directories when exposed via Mina SFTP #94

Open
thomascollett opened this issue Jan 25, 2018 · 0 comments · May be fixed by #96
Open

Unable to change directories when exposed via Mina SFTP #94

thomascollett opened this issue Jan 25, 2018 · 0 comments · May be fixed by #96

Comments

@thomascollett
Copy link

thomascollett commented Jan 25, 2018

When using s3fs as a file system for Mina SFTP, i'm unable to change directory (cd):

sftp> ls -l
d---------   1 OWNER@   GROUP@          0 Jan 25 10:51 bar
d---------   1 OWNER@   GROUP@          0 Jan 25 10:42 foo
sftp> cd foo
Can't change directory: Can't check target

POSIX permissions are not being returned for these directories, which is causing an exception in the SFTP client when attempting to cd to the directory. This is fixed by:
#96

Versions:

<dependencies>
      <dependency>
        <groupId>org.apache.sshd</groupId>
        <artifactId>sshd-core</artifactId>
        <version>1.6.0</version>
      </dependency>   

      <dependency>
        <groupId>com.upplication</groupId>
        <artifactId>s3fs</artifactId>
        <version>2.2.1</version>
      </dependency>
</dependencies>

My file system factory looks like:

FileSystem fileSystem = FileSystems.newFileSystem(
  URI.create("s3://s3-eu-west-1.amazonaws.com/"),
  ImmutableMap.of(),
  Thread.currentThread().getContextClassLoader());

Path bucketPath = fileSystem.getPath("/" + bucketName + "/");
return new VirtualFileSystemFactory(bucketPath);
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 a pull request may close this issue.

1 participant