wtsi-hgi/http-status-puppet

Name: http-status-puppet

Owner: Wellcome Trust Sanger Institute - Human Genetics Informatics

Description: A HTTP server that will return a status code of your choice

Created: 2018-02-20 14:29:13.0

Updated: 2018-02-26 10:15:00.0

Pushed: 2018-02-26 11:08:52.0

Homepage:

Size: 13

Language: Python

GitHub Committers

UserMost Recent Commit# Commits

Other Committers

UserEmailMost Recent Commit# Commits

README

Build Status codecov PyPI version

HTTP Status Puppet

A HTTP server that will return a status code of your choice

Introduction

This server simply returns back a status code depending on what endpoint is contacted, e.g.

rl -s -o /dev/null -w "%{http_code}" http://0.0.0.0:8000/403

rl -s -o /dev/null -w "%{http_code}" http://0.0.0.0:8000/200

Installation

Prerequisites

The tool can be installed from PyPi:

install httpstatuspuppet

Bleeding edge versions can be installed directly from GitHub:

install git+https://github.com/wtsi-hgi/http-status-puppet/.git@master#egg=httpstatuspuppet
Usage

Warning: this server was only designed for use in testing!

Local

After installing dependencies, in the project directory:

ONPATH=. python httpstatuspuppet/entrypoint.py
Docker
er run -d -p ${HOST_PORT}:8000 mercury/http-status-puppet
Alternatives

This work is supported by the National Institutes of Health's National Center for Advancing Translational Sciences, Grant Number U24TR002306. This work is solely the responsibility of the creators and does not necessarily represent the official views of the National Institutes of Health.