Giter Site home page Giter Site logo

rgate's Introduction

RGate

RGate my little project to take http server abstraction to logical extreme. Main goal is to allow use of any preprocessors you want to install to your unix enviorment when serving web pages. This means any templating engine or even output of shell script can be served.

How to use

Config.toml

Config.toml has example server config. This has basic details like server ports etc. I will later probly use .env and system env to make it easier for containers but currently this is how it is :)

Preproc.toml

Preproc.toml is the meat of the operation. Only required field is the extension. This eliminates the need for extension in the adress bar. Supported properties:

  • extension: what is the end of the file name that this applies to.
  • command: what is ran in your unix shell. defaults to cat
  • input_type: how the file is used by the command
    • "pipe": (default) equilevant of using < file.php at the end of shell command.
    • "file": equilevant of using file.php at the end of shell command.
  • priority: if there is conflict between preprocessors, one with lower number is selected. defaults to MAX u16

Tested

Some of the tested 'preprocessors' so far are:

  • cat - most common terminal tool to quickly view file contents.
  • php - seems to work fine, argument passing needs to be implemented.
  • figlet - silly cli for transforming text into ascii art.
  • rant - cli for rant language. currently requires "file" input_type to work.

Future

I am building this with intent to build my small portfolio page. I absolutely intend to 'dog food' this project.

Licence

I have not decided yet.

rgate's People

Contributors

otsoturpeinen avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.