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

Adding JUNEST_HOME variable during the installation as a parameter of junest setup #266

Open
crsegerie opened this issue Jun 15, 2021 · 2 comments

Comments

@crsegerie
Copy link

I am installing junest on a server on which I do not have the root access. On the server, there is the workbench (/local) and my private repository (/home) but there is not enough space on my home, so I changed the junest/lib/core/common.sh file by just changing JUNEST_HOME in the bash variable:

# JUNEST_HOME=${JUNEST_HOME:-~/.${CMD}}
JUNEST_HOME="/local/junest/exe"
JUNEST_TEMPDIR=${JUNEST_TEMPDIR:-/tmp}

Then, after changing the JUNEST_HOME variable, I ran the junest setup command.

But it seems that changing the JUNEST_HOME is not permitted because now I run into lots of problems:

scampo01@v100alpha:/local/jun/junest/lib$ junest proot -f
proot warning: can't chdir("/local/jun/junest/lib/./.") in the guest rootfs: No such file or directory
proot info: default working directory is now "/"
proot info: pid 716: terminated with signal 11
proot warning: can't chdir("/local/jun/junest/lib/./.") in the guest rootfs: No such file or directory
proot info: default working directory is now "/"
Warn: Proot is not properly working. Disabling SECCOMP and expect the application to run slowly in particular when it uses syscalls intensively.
Try to use Linux namespace instead as it is more reliable: junest ns
proot warning: can't chdir("/local/jun/junest/lib/./.") in the guest rootfs: No such file or directory
proot info: default working directory is now "/"
root@v100alpha:/# ls
ls: cannot access 'lib64': No such file or directory
ls: cannot access 'mnt': No such file or directory
ls: cannot access 'root': No such file or directory
ls: cannot access 'usr': No such file or directory
ls: cannot access 'lib': No such file or directory
ls: cannot access 'run': No such file or directory
ls: cannot access 'proc': No such file or directory
ls: cannot access 'boot': No such file or directory
ls: cannot access 'bin': No such file or directory
ls: cannot access 'srv': No such file or directory
ls: cannot access 'opt': No such file or directory
ls: cannot access 'etc': No such file or directory
ls: cannot access 'home': No such file or directory
ls: cannot access 'sbin': No such file or directory
ls: cannot access 'sys': No such file or directory
ls: cannot access 'var': No such file or directory
ls: cannot access 'dev': No such file or directory
ls: cannot access 'tmp': No such file or directory
bin  boot  dev  etc  home  lib  lib64  mnt  opt  proc  root  run  sbin  srv  sys  tmp  usr  var
root@v100alpha:/# 

My take would be to change the default working directory to the same path as JUNEST_HOME, but I looked a bit in the code and I can't find any way to do it. I will be very grateful if you help me on those problems.

But the main point of this issue is really to make it more easy to setup junest in a custom directory, otherwise I would have posted on stack overflow.

Thank you very much for your help, and thank you for maintaining this very cool package.

@fsquillace
Copy link
Owner

Hi,

Sorry I am not sure I follow. You should be able to change the JUNEST_HOME env variable without changing any code (doc here).

JUNEST_HOME=/local/junest/exe junest setup

@crsegerie
Copy link
Author

That's what I did, but you can see on my capture that it broke the installation

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

No branches or pull requests

2 participants