Add sub-domains to your server with Apache

11/05/2013 - No comments

    If you have multiple services running on your server, and want to use sub-domains instead of sub-folders, here is a quick howto 😏
    I am running different services on my server at home, for example Shaarli and Leed. Instead of using different sub-folders of the main Apache /var/www/ folder, I preferred to use sub-domains. With sub-domains you obtain something like :
links.domain.com instead of domain.com/links
    To do so, you have to edit a file in the Apache configuration. In Ubuntu, the file is located under
/etc/apache2/sites-availabe/
Open the file named "default" with your preferred text editor and add the following lines at the end of the file
<VirtualHost *:80>
DocumentRoot /var/links/
ServerName links.domain.com
</VirtualHost>
The folder /var/links/ represent the installation folder of Shaarli.
Then, restart your Apache server
sudo /etc/init.d/apache2 restart
open your browser to links.domain.com
Enjoy ✅

Tags : HowTo, Server

Blogotext's Links, new section on the blog

16/04/2013 - No comments

    I usually like to write detailed articles on my blog. However it often happens that I want to share a quick note, for example a basic command. In this situation, I am not going to write a complete article about how to use this command. That's why I decided to use Blogotext's (BT) Links as a links/notes sharing platform. BT Links is similar to Shaarli (installed on my own server for personal use).
    Here, I preferred BT Links instead of Shaarli because it fits better with my blog. I can manage my links from the blog's admin page, the graphical chart remains the same as on my blog and it is easier to use. From now on, you can follow my links/notes from my Links page, or using your favorite RSS reader from my Links RSS feed.
    I hope you'll enjoy 😉

Tags : General

Installing RStudio Server on Mac OS X Lion

14/04/2013 - 2 comments

RStudio.png     RStudio is a great IDE for the R programming language. Two versions of RStudio are available, the desktop and the server edition. The desktop edition is a full version running locally and the server edition is running on a server with the graphical RStudio interface accessible from your web browser. At work I am using a Mac Pro as a personal server with all my data and my running scripts. To preserve my memory (RAM) on my laptop I wanted to run R from my server. Until now, I used the command line with ssh, but after testing RStudio I couldn't go back anymore :)
    You can install RStudio Server in any machine and access its graphical interface from any web browser. You will then access your normal IDE running R (on the server-side) with your Rhistory and R plots remaining there.
    Recently, I found the following tutorial about how to install RStudio server on Mac OS X Lion. It works very well, but I got an error at some point. After running the following command
sudo ./install-boost
    I got an error claiming that bootstrap.sh was not found. To continue the installation, you need to run bootstrap.sh by yourself. To do so, run the following commands from your terminal
cd $YOUR_RSTUDIO_INSTALLATION_FOLDER/dependencies/common/boost-build/boost_1_50_0
sudo ./bootstrap.sh
sudo ./bjam --prefix=/opt/rstudio-tools/boost/boost_1_50_0 toolset=clang variant=release threading=multi link=static install
    Of course, change the version of boost if your are using a more recent one. Don't forget to modify $YOUR_RSTUDIO_INSTALLATION_FOLDER by your Rstudio installation folder path.
Then, continue with the normal installation process, everything should go well.
    Browse to http://localhost:8787 login with your username and password you use for the computer where you installed RStudio server and enjoy ;)

image: rstudio.org

UPDATE: Opera is not supported by RStudio BUT works with IE if you install the Google Chrome Frame plugin. OMG :)

rstudioError.jpg

Tags : HowTo, Mac, Server, Software

How to convert PDF to PNG from the command line on a Mac

10/04/2013 - No comments

    Instead of opening your PDF file with the Preview app (or other PDF reader) and export it to PNG, you can easily use the command line.
To do so, you need to use the sips (scriptable image processing system) command installed by default in Mac OS X. Open your terminal and run:
sips -s format png your_pdf_file.pdf --out your_png_file.png
The script also works for the jpeg format the same way.
Voilà ;)

source
 : straylink
A.P. Lawrence

Tags : HowTo, tips

Add tabulations in your articles with Blogotext

07/04/2013 - No comments

    I am using Blogotext as blog engine. It is a big pleasure to use it :) Blogotext is open-source, easy-to-use and very light, it works very well. I would like to thank again Timo for his great job.
    I am using paragraphs to organize my articles and make them clearer. In addition, I like to start each paragraph with a tabulation. Unfortunately, it is not easy to add tabulations using the default Blogotext editor. However, you can do it by forcing 4 spaces, such as
&nbsp;&nbsp;&nbsp;&nbsp;
    I wanted to make it easier, thus I decided to implement this option in my editor.
The default Blogotext editor's menu looks like :
BlogotextEditorWithoutIndent.jpg After implementing the tabulation option, you'll see an "indent" icon in the right-hand side of the "line-through" icon :
BlogotextEditorWithIndent.jpg

    To do so, you will have to modify two lines in two different files:

1 - First,
  • open the file /admin/form.php
  • go to line 581
  • add
    echo "\t".'<button id="button15" class="but" type="button" title="tab" onclick="insertTag(\'\&nb\s\p\;\&nb\s\p\;\&nb\s\p\;\&nb\s\p\;\',\'\',\'contenu\');"><span class="c"></span></button>'."\n";
2 - Second,
  • open the file /admin/style/style-ecrire.css
  • go to line 184
  • add
    #button15 span.c { background-image: url("format-bbcode/edit-indent.png"); }
If you want, you can modify the icon by choosing another one from your /admin/style/format-bbcode/ folder.
Enjoy ;)

Tags : HowTo, Software, tips

HyperSwitch, an interesting app switcher alternative for Mac

06/04/2013 - 4 comments

HyperSwitch.png     The default app switcher on Mac (cmd+tab) doesn't show the different opened windows for a given application. For example if you have multiple LibreOffice windows opened, you will only see one LibreOffice icon on the app switcher. I think this is a great productivity-killer :)
    When I was looking for an alternative, I first found Witch. Witch looks promising but it was too complicated for me. I also didn't like the vertical presentation of the app switcher.
    I then managed (I don't know how) to find Senebier :) I just don't understand what's written and didn't read any positive or negative comment about this app. I didn't installed it yet, but I contacted the author to ask if the source code will be available at any time or not.
    Finally, when following my feeds from LifeHacker, I stumbled upon an article about HyperSwitch. This app switcher is still in Beta but it actually works pretty well. Once you started the app switcher and moved to an app icon, you can:
  • press the down arrow to you see all the open windows and switch to one of them
  • press the up arrow to open a new window for that app or see the most recent files
    I am actually giving a try to HyperSwitch. It is a promising project, still in beta, but I am sure it will improve a lot very soon.

Source : HyperSwitch website
LifeHacker's article about HyperSwitch
Image : RoaringApps

Tags : Mac, Software

Leed: your web-based open source RSS reader

03/04/2013 - 2 comments

Leeds logo     As you can see from my older posts, I am becoming more and more self-hosted every day :) I already have some interesting services running on my own server, don't worry I will write about all of them. Last time I wrote about Shaarli, a great and open source links managing tool. Today, I will introduce you to Leed (for Light Feed). Leed is an open source RSS reader alternative to Tiny Tiny RSS or RSS Lounge for example (and the almost dead Google Reader). I never tried any RSS readers before, I was mainly reading my feeds in Thunderbird, thus I cannot compare Leed to its existing alternatives. I can only say that Leed is great.

    I wanted a web-based RSS reader to access my feeds from any devices everywhere. I recently discovered Idleman's blog (in French) when he started his tutorials about the Raspberry Pi. Then I found his project's page and Leed.
Leed is an open source and light RSS feed reader. The installation is very easy.
The "only" requirements are:
- Apache server
- PHP 5.3
- MySQL

    Once installed, you can use crontab to automatically update your feeds, or you can do it manually if you don't want to deal with crontab. You can use keyboard shortcuts and personalize the interface using themes. You can easily implement your own themes. The default theme is responsive, thus you have an easy access and user-friendly interface in any of your devices (tablet, smartphone...).
One other great option is the link between Leed and Shaarli. If you are using Shaarli, you can automatically add any articles from your feeds to your Shaarli.
Leed is very simple and Leed works :)

When I was writing this post, I realized that Leed was only available in French. After asking the permission to the author (Idleman), I translated Leed and the installation process to English.

How to install Leed:
1 - Download the archive LeedEnglish.zip (Licence : CC by nc sa)
2 - Unzip and send the content to your server. Do a chmod 777 to the leed folder
3 - Go to the installation page http://mydomain.com/leed/install.php and follow the instructions
4 - Once the installation is finished, remove the install.php file for your security
5 - If you want to update automatically your feeds, put the following line into your crontab
Open crontab
sudo crontab -e
and add the following line for an hourly update :
0 * * * * wget -q -O /var/www/leed/logsCron "http://mydomain.com/leed/action.php?action=synchronize&code=your_synchronisation_code"
(adjust the link and your synchronisation code)
Be warn that too frequent updates can slow down the server.

Don't hesitate to ask if you have any question or remark ;)

A demo of Leed is available online here

Tags : Server, Software

Dynamic IP address with OVH

30/03/2013 - No comments


When I was configuring my server, I realized that I only had a dynamic IP address. At the time I had two options:
  • ask for a fixed IP address
  • deal with my dynamic IP address to get it updated when it changes
The first option was too expensive for me. Thus, I decided to go for the second one.

    Some tools exist to allow you to use a dynamic IP address with a specific domain name, such as DynDns or no.ip for example. Those tools provide scripts to update your IP address as soon as it changes. I could't find the free option for DynDns anymore, but there is a free option for no.ip with some limitations, but it should be find for a personal use.
    Before using one of the available general tools, I did some research about OVH (my registrar) and dynamic IP address. I then realized that OVH was providing some specific tools to update your IP information directly on your OVH manager. You can find more information in the DynHOST page.
    I am actually using the Ipcheck.py script available from the previous link. I just had to adapt the script for my own usage. I modified the dynhost script and changed the line
IP=`/sbin/ifconfig $IFACE | fgrep "inet ad" | cut -f2 -d":" | cut -f1 -d" "` 
(which was returning my local IP address)
to
IP=`/usr/bin/wget -qO- ipecho.net/plain`
to get the correct IP address used by OVH.
It actually works pretty well for me, Enjoy cool

Tags : HowTo, Server, tips

spliceIt available for iOS and Android

01/02/2013 - 3 comments


     I recently finished my first augmented reality (AR) app: spliceIt. This app contains some of the results about alternative splicing regulation I obtained during the first two years of my PhD. It also contains a 3D representation of the spliceosome using AR.
     To see the AR 3D spliceosome, go to the "Spliceosome" menu and focus your camera to the picture of the shiny spliceosome. You can pinch to zoom and slide to rotate the 3D spliceosome.


spliceIt on the Google Play Store

spliceitplaystore


spliceIt on the iOS Appstore

spliceitappstore

Feel free to use it. I am looking forward to read your comments.

Tags : Software

Share your links with Shaarli

08/01/2013 - No comments

shaarli
     I recently installed a new tool on my server at home: Shaarli. Shaarli is a very light open-source clone of delicious. You can use it for many different things: share your links, save your bookmarks, use it as a notepad, share text or information easily among your different devices...

Why is Shaarly great:
  • add all your links with a specific tag
  • find your links by tag or keywords
  • draw a tag cloud to see the most commonly used tags
  • add a bookmark on your browser to automatically save new links
  • see all your images using the picture wall
  • generate automatically a newspaper-like page containing all your daily links
  • ... more features on Shaarli's official webpage
I installed Shaarli a few months ago and I am using it very often as a bookmark accessible from everywhere, any device, any web-browser, simply great.
Shaarli requires php 5.1 (5.2 for autocomplete).
You can find an example at http://sebsauvage.net/links/
I will keep posting about interesting tools/services for self-hosting cool

Tags : Server, Software


≺ newer elements – older elements ≻