July 2, 2010
Note: This makes sense only if you want to ship a custom dojo build with your Plone application or if you find it slow and annoying to go get dojo from one of the CDNs. If you don’t have a custom dojo build (if you don’t know what I am talking about, then you certainly don’t need one) just get dojo from the CDN – works beautifully with Plone.
The existing solutions ranged from the brute force to the exotic and excessive.
The solution we settled down to (after a little bit of thinking) is to setup dojo behind apache and serve the files from there. Here’s how to do it.
- Get the dojo sdk
- extract it to a directory like /home/xxx/dojo and do a cross domain build (see dojo documentation on how to do this).
- Setup apache if you haven’t already done this. Don’t be scared – setting up apache these days just means installing the package from your favorite distribution.
- Open up /etc/apache2/apache2.conf (This is where it resides on my ubuntu server) and add the following at the end
Alias /dojo/ "/home/xxx/dojo/"
Options Indexes MultiViews FollowSymLinks
Deny from all
Allow from 127.0.0.0/255.0.0.0 ::1/128
That will setup your dojo files to be served to the localhost – for development purposes it is ok. You can eventually change it to serve your intranet/internet users as well.
May 27, 2010
For once something did not work out of the box on my Ubuntu 9.10 installation. My ASUS WL-167G USB 2.0 WLAN adapter could not connect to my HOME wireless network – UT STarcom Model WA3002G4 wireless router. Out of the box Ubuntu uses NetworkManager to connect to wireless networks. After several attempts and Internet researching I settled on the following set of guidelines which has since helped me in troubleshooting other wireless related issues. If nothing seems to work for you, try this as a last resort and isolate the problem. The goal is to get the connection established without compromising on wireless security.
- Router Side Configuration:
- Enable broadcasting of network name or SSID if it is turned off.
- Turn off or disable MAC address filtering. Any MAC should be able to connect.
- Set wireless security to WPA/WPA2-PSK.
- Setup a passphrase.
- Desktop/Laptop side configuration:
- NetworkManager is not very useful. If it does not work outright, don’t bother with it at this stage.
- Setup your /etc/wpa_supplicant.conf file as shown in end.
- Setup your /etc/network/intefaces as shown in the end.
- ifdown interface_name; ifup interface_name
- If at the end of 4 you could connect, congratulations, there is nothing wrong with your chipset or driver or the router. You can continue to play with the above setup and modify it as per your needs to turn on or off some parameters.
- If at the end of 4 you could not connect, do the following from a terminal.
- ifdown interface_name
- Run “iwlist scan” from a terminal. You should see your network listed if you have correctly configured your router as mentioned above. If not something is wrong with the driver. Try to verify that the chipset or the WLAN card model drivers are available for your linux distribution. If you can see your network proceed to the next step.
- wpa_supplicant -dd -c/etc/wpa_supplicant.conf
- The above command does a lot of verbose printing. The output tells a lot about where the problem is. This is where it gets murkier.
# cat /etc/wpa_supplicant.conf
#cat /etc/network/interfaces #wlan0 is the name of my interface.
iface wlan0 inet dhcp
pre-up wpa_supplicant -iwlan0 -c/etc/wpa_supplicant.conf
post-down killall -q wpa_supplicant