cloud9 remove root access Debian 8

62 views
Skip to first unread message

Sebastián Sáez

unread,
Jul 21, 2017, 7:39:00 PM7/21/17
to BeagleBoard
Hi,

In Debian stretch, cloud9 is no longer root

Is it possible to remove root access to cloud 9 for Debian 8?


regards,
Sebastián

Robert Nelson

unread,
Jul 21, 2017, 7:47:12 PM7/21/17
to Beagle Board, Sebastián Sáez
On Fri, Jul 21, 2017 at 6:39 PM, Sebastián Sáez <otr...@gmail.com> wrote:
> Hi,
>
> In Debian stretch, cloud9 is no longer root
>
> Is it possible to remove root access to cloud 9 for Debian 8?

Yes, just a few changes required:

in the cloud9.service file:

Change the [Service] to have:

WorkingDirectory=/opt/cloud9/build/standalonebuild
EnvironmentFile=/etc/default/cloud9
ExecStartPre=/opt/cloud9/cloud9-symlink
ExecStart=/usr/bin/nodejs server.js --packed -w /var/lib/cloud9
SyslogIdentifier=cloud9ide
User=1000

create the "symlink"

/opt/cloud9/cloud9-symlink
****************
#!/bin/sh

user=$(getent passwd 1000 | awk -F: '{ print $1 }')

if [ -d /home/${user}/.c9 ] ; then
rm -rf /home/${user}/.c9 || true
else
if [ -f /home/${user}/.c9 ] ; then
rm /home/${user}/.c9 || true
fi
fi
ln -sf /opt/cloud9/.c9/ /home/${user}/
****************

The symlink file is just to fix up the termimal in cloud9, otherwise
"~/,$home, etc" don't work.

There's one bonescript bug Jason is working on, so that "pwm" will
work when root-less.

Regards,

--
Robert Nelson
https://rcn-ee.com/

Sebastián Sáez

unread,
Jul 22, 2017, 1:55:36 PM7/22/17
to Robert Nelson, BeagleBoard
Thanks you Robert :)

William Dillon

unread,
Feb 21, 2018, 7:15:30 AM2/21/18
to BeagleBoard
Tagging along to this discussion...  Where is the "cloud9.service" file?
Reply all
Reply to author
Forward
0 new messages