-
Notifications
You must be signed in to change notification settings - Fork 0
How to set up Che on Linux
Start by following the steps commands listed on the following link: https://eclipse-che.readme.io/docs/configuration-che-on-ec2
The first set of commands on the link are used for installing docker. Remember to replace commands intended for specific users with the user that be running Che. For example, if ec2-user is running Che, commands such as sudo usermod -aG docker $(whoami) would instead be sudo usermod -aG docker ec2-user along with sudo gpasswd -a ec2-user docker .
sudo yum install wgetwget -qO- https://get.docker.com/ | shsudo usermod -aG docker $(whoami)
Make sure that the user you add to the docker group has a UID of 1000 and once that user is added they must log out and back in for the changes to take effect.
The commands listed for installing docker are sudo systemctl enable docker.service and sudo systemctl start docker.service. However, I run docker through the command sudo service docker start. Try testing docker by running the following commands:
docker infodocker imagesdocker run hello-world
If you get the response "Cannot connect to the Docker daemon. Is the docker daemon running on this host?", check to see if docker is running using the following command sudo service docker status. If it is running, check to see if the user who has been added to the docker group is the one running the commands or if they logged out and back in since they were added to the group. Once those commands are fully functional, we can move on to the next step.
This one is a lot less troublesome. Just follow the commands on the link for installing java and everything should work as intended.
sudo yum install java-1.8.0-openjdk*which javavi ~/.bashrcexport JAVA_HOME=/usr/export PATH=$JAVA_HOME/bin:$PATHsource ~/.bashrc-
sudo update-alternatives --config javain order to switch to your most recent version of Java
- Follow the steps to install Che on the link and move the Che directory to the
/optdirectory. wget -P /home/centos "https://install.codenvycorp.com/che/eclipse-che-latest.zip" -O che.zipsudo yum install unzipunzip che.zipsudo chown -R cheuser /opt/eclipse-che-4.2.0sudo chgrp -R cheuser /opt/eclipse-che-4.2.0- Find out the externally available ip address of your EC2 vm by pinging the host name outside the vm and run Che through the following command as the user that was added to the docker group:
/opt/eclipse-che-4.2.0/bin/che.sh run -r:$ipaddresswhere$ipaddressis enter the ip address that you received earlier.