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

gopass not picking tmp dir location from ENV variable. Can't see a config option neither. #2856

Open
r3k2 opened this issue Apr 4, 2024 · 5 comments
Milestone

Comments

@r3k2
Copy link

r3k2 commented Apr 4, 2024

Summary

Hello I installed gopass on termux but it does not pick up the ENV variable for the tmp dir:
When I try to sync I get:

~ $ gopass sync
🚥 Syncing with all remotes ...
[<root>] 
   gitfs pull and push ... ⚠ Failed to pull before git push: exit status 1: unix_listener: cannot bind to path /tmp/.ssh-61459bda7da1328b149cdf2ede56bae0bdaa0f34.86wFKsFDcefQDIVe: No such file or directory
fatal: Could not read from remote repository.

Please make sure you have the correct access rights
and the repository exists.
❌ Failed to push "<root>" to its remote: exit status 128: unix_listener: cannot bind to path /tmp/.ssh-61459bda7da1328b149cdf2ede56bae0bdaa0f34.f82JMcPn3dohmhlB: No such file or directory
fatal: Could not read from remote repository.

Please make sure you have the correct access rights
and the repository exists.
✅ All done

the ENV variable is:
TMPDIR=/data/data/com.termux/files/usr/tmp

I was reading the doc to see if I find a way to hardcode the path on the config but so far I was not lucky or
I missed it.

Android tablet with Termux
I installed with apk
is running other go apps just fine like nctask
gopass 1.15.11 go1.21.4 android arm64

@dominikschulz
Copy link
Member

We use os.Tempdir() when initializing the git repo: https://github.com/gopasspw/gopass/blob/master/internal/backend/storage/gitfs/ssh_others.go#L19

@r3k2
Copy link
Author

r3k2 commented Apr 6, 2024

cool, so what do i need to do?

@r3k2
Copy link
Author

r3k2 commented Apr 17, 2024

hello, I have tried tons of things my TMPDIR env is setup to /sdcard/tmp all terminal programs work, and gopass kind of works if I copy with scp the vault and entries to its right place, but I can't sync... is like somewhere is hardcored or not picking up from TMPDIR have any idea were to look?

@dominikschulz dominikschulz added this to the 1.x.x milestone Jul 20, 2024
@lhardt
Copy link
Contributor

lhardt commented Oct 1, 2024

This seems to relate to the file ssh_others or ssh_darwin. Since Android would fall in the 'others' category, additional testing on Termux would be needed. I guess doing TMPDIR=/this/folder gopass on the terminal directly would be fine

@AnomalRoil
Copy link
Member

@r3k2 Could you try setting GIT_SSH and GIT_SSH_COMMAND both to an empty string?
Does it works for you? That should disable persistent connections and thus prevent us from trying to write to a temp directory.

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

No branches or pull requests

4 participants