Giter Site home page Giter Site logo

ynm3k's Introduction

YNM3K

A Fakesite for http test, see also go-fakesite.

docker run -p 9527:80 notsobad/ynm3k

curl http://127.0.0.1:9527/

Also you can build it yourself

cd ynm3k
docker build -t ynm3k .
docker run -it --rm -p 9527:80 ynm3k

A demo page with http 502 response:

wangxh:~/myapp/ynm3k$ curl 127.1:9527/code/502.jpg -vv
> GET /code/502.jpg HTTP/1.1
> User-Agent: curl/7.30.0
> Host: 127.1:9527
> Accept: */*
>
< HTTP/1.1 502 Bad Gateway
< Content-Length: 62
< Set-Cookie: csrftoken=8e0f2f299fede170969578ebceec0967; expires=Thu, 09-Jan-2014 06:29:39 GMT; Max-Age=31449600; Path=/
< Vary: Accept-Encoding
< Server: YNM3000
< Date: Wed, 14 May 2014 09:25:11 GMT
< Content-Type: text/html; charset=UTF-8
<
<h1>Http 502</h1> <hr/>Generated at 2014-05-14 17:25:11.603423

Trace

Show raw request header.

/trace/

Static file

Visit same url, get same result

/static/$RANDOM.$EXT

Dynamic url

Visit same url, get different result

/dynamic/$RANDOM.$EXT

HTTP status code

/code/$CODE.$EXT

Specified size response

You can output a file of the specified size.

/size/$SIZE.$EXT

A server with a slow response

Visit /slow/$SECONDS, the url will take $SECONDS time to render.

URL redirect

All kinds of url redirect method

DEMO:

curl -v 'localhost:9527/redirect/301?url=file:///etc/passwd'
curl -v 'localhost:9527/redirect/302?url=http://www.jiasule.com'

ynm3k's People

Contributors

hallelujah-shih avatar notsobad avatar zdcydev avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

ynm3k's Issues

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.