Saturday, February 3, 2018

view stackoverflow offline

1- download stackdump from
https://bitbucket.org/samuel.lai/stackdump/downloads/

2- download stackoverflow dump file from
https://archive.org/download/stackexchange

i choose below for test
https://archive.org/download/stackexchange/astronomy.stackexchange.com.7z


3- first we need internet connection to get info from the stackoverflow itself
$ unzip stackdump-v1.3.1.zip
$  cd stackdump
$ ./start_solr.sh
$ cd data
$ wget https://stackexchange.com/feeds/sites
$ ./manage.sh download_site_info

4- extract  our data,astronomy.stackexchange.com.7z, to a directory
 then start indexing from that directory


$ cd stackdump
$ ./manage.sh import_site --base-url astronomy.stackexchange.com --dump-date "Dec 2017" /tmp/astronomy

5- after the indexing finishes, we cat start the web and can browse it offline
$  ./start_web.sh

and to access it use url
http://thepcipOrlocalhost:8080

No comments:

Post a Comment