[Server-devel] The three step XSCE demo

Tim Moody tim at timmoody.com
Fri Nov 22 13:15:57 EST 2013


I take a middle of the road approach, using vbox, but not vagrant.

Some time ago I created a vbox with a minimal FC18 64 bit install, which I 
call FC18-64Base and which I periodically yum update and into which I put my 
personal account, make myself a sudoer, etc., turn on sshd if necessary.

I then did a vbox clone of the that vm and performed Miguel's setup - get 
git and ansible and update ansible, which I call XSCEAnsibleBase with two 
nics, one for wan and one for lan. A vbox clone takes a little over a 
minute.

When I want to test the server I do a vbox clone of XSCEAnsibleBase and name 
it XSCEAnsibleTest (I usually generate new mac addresses to be safe).

Then I git clone https://github.com/XSCE/xsce --depth 1 or my working 
branch.  (--depth 1 saves a lot of time on the git clone)

I connect XSCEAnsibleTest to my home network on wan so I can ssh in and to 
an isolated access point on the lan to connect XOs.  I can also sftp into 
the server using my account.

I am fortunate to have some XOs for testing, but I have also used SoaS, 
again running as a vbox vm.  In that case I could eliminate the extra access 
point and just connect the server and client vms on the lan side over a 
virtual network internal to vbox.  Awhile back I successfully ran three SoaS 
vms simultaneously on an old Dell laptop to test collaboration.



>-----Original Message----- 
>From: server-devel-request at lists.laptop.org
>Sent: Friday, November 22, 2013 12:00 PM
>To: server-devel at lists.laptop.org
>Subject: Server-devel Digest, Vol 79, Issue 17
>
>Send Server-devel mailing list submissions to
>server-devel at lists.laptop.org
>
>To subscribe or unsubscribe via the World Wide Web, visit
>http://lists.laptop.org/listinfo/server-devel
>or, via email, send a message with subject or body 'help' to
>server-devel-request at lists.laptop.org
>
>You can reach the person managing the list at
>server-devel-owner at lists.laptop.org
>
>When replying, please edit your Subject line so it is more specific
>than "Re: Contents of Server-devel digest..."
>
>
>Today's Topics:
>
>   1. Re: The three step XSCE demo! (Miguel Gonz?lez)
>   2. Re: The three step XSCE demo! (David Farning)
>   3. Re: The three step XSCE demo! (Thomas Gilliard)
>
>
>----------------------------------------------------------------------
>
>Message: 1
>Date: Thu, 21 Nov 2013 19:27:42 +0100
>From: Miguel Gonz?lez <migonzalvar at activitycentral.com>
>To: Anish Mangal <anish at activitycentral.com>
>Cc: server-devel <server-devel at lists.laptop.org>
>Subject: Re: [Server-devel] The three step XSCE demo!
>Message-ID:
><CABn5_V1ZA-QYMz2HGD0r+Zib3RNRx=Nj==Qg9EcrBrK-WdhiKw at mail.gmail.com>
>Content-Type: text/plain; charset=UTF-8
>
>I'm going to describe in detail my current dev environment. Hopefully,
>it could be useful for somebody.
>
>
>Pre-requisites
>====
>
>I'm using a VirtualBox and installing a virtual machine with Fedora18.
>
>I'm also use vagrant to automatically manage the virtual machine.
>There packages available from its website [1]. I'm currently using
>version 1.3.4.
>
>
>Booting a fresh virtual machine
>====
>
>The file Vagrantfile defines a basic image to download (= vagrant box)
>and allows to add configuration details like network configuration.
>
>This is a simplified but fully functional version:
>
>```ruby
># -*- mode: ruby -*-
># vi: set ft=ruby :
>
>VAGRANTFILE_API_VERSION = "2"
>
>Vagrant.configure(VAGRANTFILE_API_VERSION) do |config|
>  config.vm.box = "fedora-18-x86_64"
>  config.vm.box_url =
>"http://puppet-vagrant-boxes.puppetlabs.com/fedora-18-x64-vbox4210-nocm.box"
>
>  # config.vm.network :public_network
>
>  # config.ssh.forward_agent = true
>
>  config.vm.synced_folder ".", "/vagrant", :disabled => true
>
>   config.vm.provider :virtualbox do |vb|
>       # vb.gui = true
>   end
>
>end
>```
>
>With this command, vagrant downloads the basic image (only the first
>time) and deploys and boots up the virtual machine:
>
>```
>$ vagrant up
>```
>
>
>Then, to access the vagrant virtual machine:
>
>```
>$ vagrant ssh
>```
>
>Installing XSCE
>====
>
>Inside the vm now it's possible to follow the install instructions
>[2]. I'm copying them below:
>
>
>Install git and ansible (for dependencies):
>
>```
>sudo su -
>yum install -y git ansible
>```
>
>Update ansible to use a :
>
>```
>cd ~/
>git clone https://github.com/ansible/ansible.git
>cd ansible
>git checkout 07b59da99
>python setup.py install
>```
>
>Clone the XSCE git repo and run the actual setup:
>
>```
>cd ~/
>git clone https://github.com/XSCE/xsce
>cd xsce/
>./runansible
>```
>
>XSCE autoconfigures itself according to the interfaces it detects. If
>XSCE only detects one interface, as in this setup, it configures
>itself in "appliance mode". But the service are not reachable because
>`eth0` in the host machine is using a subnetwork.
>
>One solutions is define a port forward for every service. Other
>solution, the one I'm using currently is to add a new interface
>**after installing XSCE**.
>
>To do it, from the host machine I halt the vm, uncomment a line in
>Vagrantfile and run again:
>
>```
>$ vagrant halt
>$ vim Vagrantfile
>... uncomment # config.vm.network :public_network
>$ vagrant up
>$ vagrant ssh
>```
>
>The guest machine has 2 interfaces, the internal subnet and another
>bridged to the same LAN as the host
>
>```
>[vagrant at schoolserver ~]$ ip a
>1: lo: <LOOPBACK,UP,LOWER_UP> mtu 16436 qdisc noqueue state UNKNOWN
>    link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
>    inet 127.0.0.1/8 scope host lo
>    inet6 ::1/128 scope host
>       valid_lft forever preferred_lft forever
>2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast
>state UP qlen 1000
>    link/ether 08:00:27:f0:90:8a brd ff:ff:ff:ff:ff:ff
>    inet 10.0.2.15/24 brd 10.0.2.255 scope global eth0
>    inet6 fe80::a00:27ff:fef0:908a/64 scope link
>       valid_lft forever preferred_lft forever
>3: eth1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast
>state UP qlen 1000
>    link/ether 08:00:27:ca:fe:ca brd ff:ff:ff:ff:ff:ff
>    inet 192.168.0.100/24 brd 192.168.0.255 scope global eth1
>    inet6 fe80::a00:27ff:feca:feca/64 scope link
>       valid_lft forever preferred_lft forever
>```
>
>And now all the services can be accessed from the LAN by any device
>for testing, in this case, using 192.168.0.100.
>
>
>The main problem here is that running XSCE installation process again
>(`./runansible`) will mess the configuration because **it will find 2
>interfaces now**. So, before configuring the server again, disable
>eth1:
>
>
>```
>[root at schoolserver xsce]# ifconfig eth1 down
>[root at schoolserver xsce]# ./runansible
>```
>
>
>More..
>====
>
>
>- To begin with a new fresh virtual machine:
>
>```
>$ vagrant destroy
>$ vagrant up
>```
>
>
>- Uncommenting `config.ssh.forward_agent = true` in Vagrantfile, it is
>possible to write in a git repo from the guest using host's keys.
>
>
>- Take a look to https://github.com/XSCE/xsce/pull/76 when we are
>trying to simplify adding new *roles* (services) to XSCE.
>
>
>
>1: http://downloads.vagrantup.com/
>
>2: https://github.com/XSCE/xsce/blob/master/docs/INSTALL.rst
>
>On Wed, Nov 20, 2013 at 11:01 AM, Anish Mangal
><anish at activitycentral.com> wrote:
>> Hi Sebastian,
>>
>> You should be able to download the image from here (Thanks to Thomas 
>> Gillard
>> for uploading the file):
>> http://people.sugarlabs.org/Tgillard/XSCE.ova
>>
>> Please verify the md5sum once you have downloaded the file.
>> 56a4f141b564b0d2bd65c543a5e585c6
>>
>> About your question on dev environment I am ccing Santi and Miguel who 
>> can
>> answer it best. It may depend on what part of the server you want to
>> contribute to, but I think you should mostly be able to get away with 
>> just a
>> VM image. I don't believe anyone has tried a chroot env (though I could 
>> be
>> wrong) but it _might_ be possible.
>>
>> Also, for testing with real clients (like xo laptops) you are probably 
>> going
>> to need something for the LAN side (an access point). There are a few
>> permutations here, but I will step back and let more the technical 
>> experts
>> converse :-)
>>
>> Cheers,
>> Anish
>>
>>
>>
>> On Wed, Nov 20, 2013 at 10:54 AM, Sebastian Silva
>> <sebastian at fuentelibre.org> wrote:
>>>
>>> Thanks that will be simpler. Actually I'm more interested in what a good
>>> dev environment would be in order to contribute.
>>> Do I need to make a fedora chroot?
>>>
>>> Regards,
>>> Sebastian
>>>
>>> El 19/11/13 09:51, Anish Mangal escribi?:
>>>
>>> I tried uploading it to xsce.activitycentral.com, but I ran out of space
>>> in my user dir. Normally the appliance is 1.3G, but this also has 400mb 
>>> of
>>> IIAB test dataset.
>>>
>>> I'll give it another shot in another area where there is some free 
>>> space,
>>> and get back.
>>>
>>>
>>> On Tue, Nov 19, 2013 at 7:24 PM, Sebastian Silva
>>> <sebastian at fuentelibre.org> wrote:
>>>>
>>>> Hi
>>>> I tried this but google drive problematic to download from as it 
>>>> requires
>>>> to download from a browser. Not adequate for 1.6gb. Let me know if I 
>>>> can
>>>> pick it up from a regular download place. Why is it so big?
>>>>
>>>> Regards,
>>>> Sebastian
>>>>
>>>> El 17/11/13 20:48, Anish Mangal escribi?:
>>>>
>>>>> Download the XSCE Virtualbox appliance from here
>>>>> https://docs.google.com/file/d/0B3eW2YPe6koIVXRVbDhSR0xXQ1U (approx 
>>>>> 1.6 GB)
>>>>
>>>>
>>>
>>>
>>
>
>
>



More information about the Server-devel mailing list