<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0"
    xmlns:content="http://purl.org/rss/1.0/modules/content/"
    xmlns:dc="http://purl.org/dc/elements/1.1/"
    xmlns:atom="http://www.w3.org/2005/Atom">
    <channel>
        <title>command-line — LowEndSpirit DEV</title>
        <link>https://dev.lowendspirit.com/index.php?p=/</link>
        <pubDate>Wed, 08 Apr 2026 19:51:47 +0000</pubDate>
        <language>en</language>
            <description>command-line — LowEndSpirit DEV</description>
    <atom:link href="https://dev.lowendspirit.com/index.php?p=/discussions/tagged/command-line/feed.rss" rel="self" type="application/rss+xml"/>
    <item>
        <title>HTTP Server Setup with a Single Command Line</title>
        <link>https://dev.lowendspirit.com/index.php?p=/discussion/3931/http-server-setup-with-a-single-command-line</link>
        <pubDate>Mon, 21 Mar 2022 20:31:31 +0000</pubDate>
        <category>LES Talk</category>
        <dc:creator>alexxgg</dc:creator>
        <guid isPermaLink="false">3931@/index.php?p=/discussions</guid>
        <description><![CDATA[<p><em>Written by <a href="https://dev.lowendspirit.com/index.php?p=/profile/alexxgg" rel="nofollow">@alexxgg</a>, 19 May 2021</em><br /><small>Article was migrated from WordPress to Vanilla in March 2022</small></p>

<p>
  <img src="https://talk.lowendspirit.com/uploads/editor/y9/8lyyu4b1q32d.png" alt="image" /></p>

<p>This is a guest post by <a rel="nofollow" href="https://talk.lowendspirit.com">forum</a> user <a href="https://dev.lowendspirit.com/index.php?p=/profile/alexxgg" rel="nofollow">@alexxgg</a>,</p>

<p>Hi there!</p>

<p>These days when the internet shares things in milliseconds, who of you have needed to share a file quickly? I bet some of you remember at least one time one of those cases.</p>

<p>As you probably know, in terms of web servers, we can share files with popular software like Apache, Nginx, and Lighttpd but this software need basic configuration, also they consume server resources as long as they’re active.</p>

<p>What if you could set up a basic HTTP web server without installing Apache, Nginx, or Lighttpd? Well, that’s sounds kind of impossible, and even more unbelievable is that you can kill it with Ctrl^C. Thanks to Python3 we can do that with its <a rel="nofollow" href="https://pypi.org/project/httpserver/">HTTP server module</a>.</p>

<p>This module will deploy an HTTP server in any directory of the server, even in the root directory and that sounds ridiculously dangerous, fortunately, the default port of this HTTP server isn’t 80. Instead, it will use port: 8000 but you can assign a custom port, very convenient for NAT environment instances.</p>

<p>Now you can deploy a basic HTTP server -in the current directory with the default port- by typing this single command line:</p>

<pre spellcheck="false" tabindex="0">python3 -m http.server
</pre>

<p>Starting HTTP Server</p>

<p><img src="https://talk.lowendspirit.com/uploads/editor/05/lopja74fwxsh.png" alt="" title="" /></p>

<p>Killing HTTP Server</p>

<p><img src="https://talk.lowendspirit.com/uploads/editor/j0/nzh2vdl7fq70.png" alt="" title="" /></p>

<p>HTTP Server as Shown in Browser</p>

<p><img src="https://talk.lowendspirit.com/uploads/editor/ic/4ppesu0bamvj.png" alt="" title="" /></p>

<p><img src="https://talk.lowendspirit.com/uploads/editor/81/dmmmh9vc0eds.png" alt="" title="" /></p>

<p>You can change the default port (example port: 32085) and specify a directory (example directory: /tmp/) with:</p>

<pre spellcheck="false" tabindex="0">python3 -m http.sever 32085 --directory /tmp/
</pre>

<p>More information about Python3 httpserver module is available <a rel="nofollow" href="https://docs.python.org/3/library/http.server.html">here</a></p>

<p>Also, there is a github page <a rel="nofollow" href="https://github.com/freelamb/simple_http_server">here</a></p>

<p><strong>Note</strong>: of course, you will need to install Python3 in order to use these post example command lines.<br />
Leave a comment to let me know any questions or suggestions.</p>
]]>
        </description>
    </item>
   </channel>
</rss>
