Sign inSign up

lkdevelopment/hetzner-cloud-api-mock

By lkdevelopment

•Updated over 6 years ago

A basic mock server that makes testing the Hetzner Cloud API a breeze.

Image
0

10K+

lkdevelopment/hetzner-cloud-api-mock repository overview

⁠[Unofficial] Hetzner Cloud API Mock

This mock allows developers to test against the Hetzner Cloud API without creating real resources or having a real account on the Hetzner Cloud. It uses the API Blueprint from the documentation.

Differences to the first version:

  • Rewrite in go (instead of js)
  • HTTP header validation (Authorization and Content-Type)
  • Body parameter validation (When the docs require a number we validate if the request contains a number)
  • Using drafter (c++ api blueprint parser)⁠ directly instead of using a wrapper

The mock is a complete rewrite of https://github.com/LKDevelopment/hetzner-cloud-api-mock⁠.

⁠Specs:

  • Drafter v3.x
  • Go 1.12

⁠How to use?

To start the mock as a container listing to port 8080 run:

docker run -d -p 8080:8080 lkdevelopment/hetzner-cloud-api-mock:latest
⁠Notice

This is an unofficial tool, that downloads the information about the lastest stable api from the hetzner cloud and mocks the results shown in the documentation. It is just a really "stupid" mock server, that does not contain any business logic from the Hetzner Cloud.

Tag summary

Content type

Image

Digest

Size

177.2 MB

Last updated

over 6 years ago

docker pull lkdevelopment/hetzner-cloud-api-mock