GithubHelp home page GithubHelp logo

loteks / httpfs Goto Github PK

View Code? Open in Web Editor NEW

This project forked from progrium/httpfs

0.0 0.0 0.0 21 KB

Create filesystems using your favorite HTTP framework.

License: MIT License

Go 84.59% Makefile 1.47% Shell 13.94%

httpfs's Introduction

httpfs

Create virtual filesystems using any HTTP framework.

$ tree ~/demo
/Users/progrium/demo
├── greet
│   ├── goodbye
│   └── hello
└── random

2 directories, 3 files

The file tree mounted at ~/demo is powered by this Flask app:

import os, random
from flask import Flask
from autodir import AutoDirMiddleware

app = Flask(__name__)
AutoDirMiddleware(app)

@app.get("/greet/hello")
def hello():
    return "Hello, world!\n"

@app.get("/greet/goodbye")
def goodbye():
    return "Goodbye, world!\n"

@app.get("/random")
def rnd():
    return ''.join(random.choice('abcdefghijklmnopqrstuvwyz') for _ in range(24))+"\n"

All it took was one command:

httpfs -mount ~/demo ./examples/flask-basic/app.py

Don't care for Flask? Use any web framework!

Install

Currently works on Linux and Mac (with MacFUSE). Download from latest release or you can run this installer:

bash -c "$(curl -sSL https://raw.githubusercontent.com/progrium/httpfs/main/install.sh)"

Alternatively you can install using Homebrew:

brew tap progrium/homebrew-taps
brew install httpfs

Build an HTTP filesystem

Check out the examples directory or read the PROTOCOL.md to see how it works.

Roadmap

Full read-write and more coming soon. See our roadmap.

License

MIT

httpfs's People

Contributors

progrium avatar gmlewis 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.