Open link in a new tab

Content

Expand project menu

cannot setup development environment on Ubuntu desktop 16.04 LTS

Hi
Based on this link:
https://www.openproject.org/development/setting-up-development-environment/

i tied to setup development environment on Ubuntu Desktop 16.04 LTS
i have administrator privileges and when i try to install latest nodejs (nodenv install 8.10.0) , it says it cannot install it and i need to use —compile switch.

when i run “nodenv install 8.10.0 —compile” it says dont have permission and it fails.
when i run “sudo nodenv install 8.10.0 —compile” it says nodenv not installed.

i think the setup instruction are not correct regarding rbenv and nodenv and bash source.

which one i should do to use rbenv and nodenv with or without sudo successfully?
source ~/.bash_profile
source ~/.profile
source ~/.bashrc

or i should sudo them?

Message actions

alireza@alireza-ubuntu:~$ nodenv install 8.10.0
Downloading node-v8.10.0-linux-x64.tar.gz…
-> https://nodejs.org/dist/v8.10.0/node-v8.10.0-linux-x64.tar.gz
Installing node-v8.10.0-linux-x64…
mkdir: cannot create directory ‘/home/alireza/.nodenv/versions/8.10.0’: Permission denied

BUILD FAILED (Ubuntu 16.04 using node-build 3.0.5-2-gd7e054a)

Binary installation failed; try compiling from source with `—compile` flag

Inspect or clean up the working tree at /tmp/node-build.20180328173525.2950
Results logged to /tmp/node-build.20180328173525.2950.log

Last 10 log lines:
/tmp/node-build.20180328173525.2950 ~
/tmp/node-build.20180328173525.2950/node-v8.10.0-linux-x64 /tmp/node-build.20180328173525.2950 ~
alireza@alireza-ubuntu:$ sudo nodenv install 8.10.0
[sudo] password for alireza:
sudo: nodenv: command not found
alireza@alireza-ubuntu:
$ sudo mkdir /home/alireza/.nodenv/versions/8.10.0
alireza@alireza-ubuntu:~$ nodenv install 8.10.0
Downloading node-v8.10.0-linux-x64.tar.gz…
-> https://nodejs.org/dist/v8.10.0/node-v8.10.0-linux-x64.tar.gz
Installing node-v8.10.0-linux-x64…
cp: cannot create directory ‘/home/alireza/.nodenv/versions/8.10.0/./share’: Permission denied
cp: cannot create regular file ‘/home/alireza/.nodenv/versions/8.10.0/./LICENSE’: Permission denied
cp: cannot create directory ‘/home/alireza/.nodenv/versions/8.10.0/./bin’: Permission denied
cp: cannot create directory ‘/home/alireza/.nodenv/versions/8.10.0/./lib’: Permission denied
cp: cannot create regular file ‘/home/alireza/.nodenv/versions/8.10.0/./CHANGELOG.md’: Permission denied
cp: cannot create regular file ‘/home/alireza/.nodenv/versions/8.10.0/./README.md’: Permission denied
cp: cannot create directory ‘/home/alireza/.nodenv/versions/8.10.0/./include’: Permission denied

BUILD FAILED (Ubuntu 16.04 using node-build 3.0.5-2-gd7e054a)

Binary installation failed; try compiling from source with `—compile` flag

Inspect or clean up the working tree at /tmp/node-build.20180328173716.3191
Results logged to /tmp/node-build.20180328173716.3191.log

Last 10 log lines:
/tmp/node-build.20180328173716.3191 ~
/tmp/node-build.20180328173716.3191/node-v8.10.0-linux-x64 /tmp/node-build.20180328173716.3191 ~
alireza@alireza-ubuntu:~$