Skip to content

A minimalistic, single-module, dependency-less two-directory Web server in Go.

License

Notifications You must be signed in to change notification settings

CarlSmotricz/tiny-go-server

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

tiny-go-server

A minimalistic, single-module, dependency-less two-directory Web server in Go.

Purpose

I wanted a no-frills Web server to act as a repository librarian for a small set of Lua scripts written for an OpenComputers environment. Virtual "robots" in MC, running a very bare-bones wget knockoff, will be interacting with this server.

Description

Specific requirements:

  • A landing page (to provide the other URLs);
  • Serve directory listings and files from two directories lib and upl;
  • Upload files to upl (but not lib);
  • Accept single-line "log" messages and display them in the server's log.

Implementation

Go's standard packages provide enough scaffolding for a simple Web server from a single source module. This code does exactly what I want (modulo the ToDos), nothing more and nothing less, and I can control its feature set.

The fine print

The LICENSE is MIT, which means that anyone can do whatever they want with the code.

SECURITY WAS NOT CONSIDERED IN THIS SOFTWARE so it might have (unintended!) security issues.

As a result, I recommend you don't use it in a security-critical environment.

Downloads

Two files you may be interested in:

About

A minimalistic, single-module, dependency-less two-directory Web server in Go.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages