added config.ru and improve some js