GithubHelp home page GithubHelp logo

gg-rest's Introduction

ALPHA RESTful server for Argent project
Demo implementation
=================================

How to compile:

* Make sure you have GO version 1.8.3+
* Only usable on Gentoo-based distros, for now.

git clone https://github.com/StefanCristian/gg-rest

* Set GOPATH=<path/to/the/cloned/folder/gg-rest>
* Set GOROOT to where golang is installed!
* Get into folder called gg-rest/src and:

go get -u gitlab.com/stefancristian/mux

go build

=================================

How to use:

Once started the server, the only functions it will take right now are:
- Getting all available commands with "GET" on port 8003 ( which cannot be changed )
- POST request on http://<IP>:8003/installation/install_pkg with a json body as:
{ "packages" : "<any-package-name>" }
The install_pkg path does not take multiple packages.
The install_pkg path does not take [space] between json elements.
The POST request on that specific link will trigger the installation of any package
you parse it to. It takes existing packages, it does not have exit status codes yet.
- Getting a demo function installation through POST request on http://<IP>:8003/installation
This POST request will install the demo package named "argent-skel", it can be changed only
from the code right now, to have an idea what's about to happen in the future.
- Getting all available commands by using "GET" method on http://<IP>:8003/allcommands
The link, if using "GET", will show-up all the available command which were setup in
gentoo_commands.json through the standard json format ( "emerge" : "emerge" )

==================================

To be implemented:

* Code refactoring, making things more dynamic
* Exit codes from Portage materialized
* Manipulate and control json inputs
* Full search using GET through Gentoo Portage package manager
* More dynamic configuration of the REST server
* Database support
* Logging support
* Service management

gg-rest's People

Contributors

stefancristian avatar

Watchers

James Cloos avatar  avatar

Forkers

rogentos

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.