{"id":205,"date":"2010-02-23T17:53:52","date_gmt":"2010-02-23T16:53:52","guid":{"rendered":"http:\/\/kb.toderu.ro\/?p=205"},"modified":"2021-02-22T21:47:33","modified_gmt":"2021-02-22T21:47:33","slug":"serve-out-content-over-http-from-your-cwd-immediatly-2","status":"publish","type":"post","link":"https:\/\/kb.toderu.ro\/?p=205","title":{"rendered":"Serve out content over HTTP from your cwd immediatly"},"content":{"rendered":"<p>Ever want to immediatly serve content from a specific directory over HTTP, but didn\u2019t want to bother messing with<br \/>\nhttpd.conf or other webserver configiurations?<\/p>\n<p>If you\u2019ve got Python installed, this is a snap. Execute python with the SimpleHTTPServer module, using port 8080 so<br \/>\nthere isn\u2019t a need to elevate privs to root.<\/p>\n<pre id=\"terminal\"> python -m SimpleHTTPServer 8080\nServing HTTP on 0.0.0.0 port 8080 \u2026\n\nor python3 -m http.server 8080<\/pre>\n<p>Sure enough, pointing a browser to the IP address :8080 of the box hits my home directory listing. Super easy, super<br \/>\nfast, super simple!<\/p>\n<p>I use this to serve content to my PS3. The PS3 doesn\u2019t support NFS or CIFS, so to download content to the hard drive,<br \/>\nthe best method is by pulling it over HTTP with the embedded web brower. On my MacBook, I change into the directory<br \/>\ncontaining whatever media I want to transfer, fire up HTTP, and suck it down to the hard drive on the PS3. Nice!<\/p>\n<p>source: http:\/\/prefetch.net\/blog\/index.php\/2009\/10\/31\/serve-out-content-over-http-from-your-cwd-immediatly\/<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Ever want to immediatly serve content from a specific directory over HTTP, but didn\u2019t want to bother messing with httpd.conf or other webserver configiurations? If you\u2019ve got Python installed, this is a snap. Execute python with the SimpleHTTPServer module, using port 8080 so there isn\u2019t a need to elevate privs to root. python -m SimpleHTTPServer [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[19,5],"tags":[],"class_list":["post-205","post","type-post","status-publish","format-standard","hentry","category-bash","category-linux"],"_links":{"self":[{"href":"https:\/\/kb.toderu.ro\/index.php?rest_route=\/wp\/v2\/posts\/205","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/kb.toderu.ro\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/kb.toderu.ro\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/kb.toderu.ro\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/kb.toderu.ro\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=205"}],"version-history":[{"count":1,"href":"https:\/\/kb.toderu.ro\/index.php?rest_route=\/wp\/v2\/posts\/205\/revisions"}],"predecessor-version":[{"id":570,"href":"https:\/\/kb.toderu.ro\/index.php?rest_route=\/wp\/v2\/posts\/205\/revisions\/570"}],"wp:attachment":[{"href":"https:\/\/kb.toderu.ro\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=205"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/kb.toderu.ro\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=205"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/kb.toderu.ro\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=205"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}