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

./ZeroNet.sh: line 12: runtime/bin/python3: Permission denied #163

Open
slrslr opened this issue Apr 22, 2022 · 12 comments
Open

./ZeroNet.sh: line 12: runtime/bin/python3: Permission denied #163

slrslr opened this issue Apr 22, 2022 · 12 comments

Comments

@slrslr
Copy link

slrslr commented Apr 22, 2022

Step 1: Please describe your environment

Step 2: Describe the problem:

Steps to reproduce:

As a user

cd $home;wget --no-check-certificate -c https://github.com/ZeroNetX/ZeroNet/releases/latest/download/ZeroNet-linux.zip && unzip ZeroNet-linux.zip && rm -f ZeroNet-linux.zip && mv ZeroNet* zeronet;cd zeronet;chmod +x ZeroNet.sh;./ZeroNet.sh --help

Result:

./ZeroNet.sh: line 12: runtime/bin/python3: Permission denied

$ python3 ./ZeroNet.sh --help

Result:

File "/home/user/zeronet/./ZeroNet.sh", line 2
SCRIPT_DIR=$( cd ${0%/*} && pwd -P )
^
SyntaxError: invalid syntax

Workaround was to replace that "runtime/bin/python3" inside ZeroNet.sh by "python3"

@canewsin
Copy link
Collaborator

@slrslr You have to deploy it as

./ZeroNet.sh --help

Not python ./ZeroNet.sh --help

@slrslr
Copy link
Author

slrslr commented Apr 22, 2022

I did and it failed with mentioned Permission error.

@canewsin
Copy link
Collaborator

Is python available ?
Try python --version
If yes
Try chmod +x ZeroNet.sh
Retry start cmd
./ZeroNet.sh

@slrslr
Copy link
Author

slrslr commented Apr 22, 2022

python is not available, only python3:

python3 --version
Python 3.9.2

$ chmod +x ZeroNet.sh;./ZeroNet.sh --help
./ZeroNet.sh: line 12: runtime/bin/python3: Permission denied

Maybe the command inside the script is wrong?
runtime/bin/python3 "$SCRIPT_DIR/$SCRIPT" --dist_type bundle_linux64 "$@"

@canewsin
Copy link
Collaborator

Are you executing this as root ?
sudo chmod +x ZeroNet.sh

@slrslr
Copy link
Author

slrslr commented Apr 22, 2022

ZeroNet.sh already had executable permission for the current user: -rwxr-xr-x
Maybe python3 not (runtime/bin/python3):
Access: (0644/-rw-r--r--) Uid: ( 1000/ me) Gid: ( 1000/ me)

When instead of runtime/bin/python3 i use python3, then i see:
- Starting ZeroNet...

I have mentioned:

Maybe the command inside the script is wrong?
runtime/bin/python3 "$SCRIPT_DIR/$SCRIPT" --dist_type bundle_linux64 "$@"

Workaround was to replace that "runtime/bin/python3" inside ZeroNet.sh by "python3"

@yanmaani
Copy link

Duplicate of #146.

@ghost
Copy link

ghost commented Jul 10, 2022

Screenshot from 2022-07-09 22-59-21

Set Python3 as allow executing file as program and it worked

Screenshot from 2022-07-09 23-00-06

@styromaniac
Copy link

You just have to give all executable files permission to run as programs.

@ghost
Copy link

ghost commented Jul 10, 2022

Ok thanks you can close this

@qomhmd
Copy link

qomhmd commented Oct 4, 2022

@slrslr
Copy link
Author

slrslr commented Apr 20, 2023

@canewsin can you please apply this into source file?

Workaround was to replace that "runtime/bin/python3" inside ZeroNet.sh by "python3"

I have faced this issue again after downloading current ZNX from https://github.com/ZeroNetX/ZeroNet/releases/latest/download/ZeroNet-linux.zip.

Also maybe do the same for ../runtime/bin/openssl #199
Since it is second error seen on my Debian 11 (Stable) Linux with stock python3.

marek22k pushed a commit to marek22k/ZeroNet that referenced this issue Oct 30, 2023
marek22k pushed a commit to marek22k/ZeroNet that referenced this issue Oct 30, 2023
marek22k pushed a commit to marek22k/ZeroNet that referenced this issue Oct 30, 2023
marek22k pushed a commit to marek22k/ZeroNet that referenced this issue Oct 30, 2023
…rprinting

Reduce fingerprinting available to sites

refs ZeroNetX#163
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

5 participants