mathiaspius / hrobot-rs Goto Github PK
View Code? Open in Web Editor NEWHetzner Robot API Client library for Rust
Home Page: https://docs.rs/hrobot/latest/hrobot/
License: MIT License
Hetzner Robot API Client library for Rust
Home Page: https://docs.rs/hrobot/latest/hrobot/
License: MIT License
These types should be easily constructible from u32 integers.
Should make the API much more intuitive since a function taking a TemplateId
lets you search the docs for references to it and thereby ways of acquiring one/constructing
Automatically makes impossible errors like trying to fetch a server using a firewall template ID for instance, except when explicitly constructing a TemplateId
using a server_number Id.
Hetzner is updating their dedicated server billing model from monthly to hourly.
https://docs.hetzner.com/general/others/new-billing-model/
With that change, it might be feasible to redesign the disruptive tests to use short-term rented dedicated servers instead of risking my existing server fleet. Integration tests could also be run as part of the pipeline flow without incurring huge debts.
Might be useful for people to be able to store returned objects directly in json format.
Places where byte sizes should be used:
Option<ByteSize>
where None implies unlimited.I just noticed that I've been relying solely on the AsyncRobot::default()
functionality which uses AsyncRobot::from_env() under the hood for fetching username and password.
There is an AsyncRobot::new() constructor which takes username and password, but it also requires passing in a hyper client which is very cumbersome to construct.
It would be nice to have a simple AsyncRobot::from_credentials(username: &str, password: &str)
constructor which handles the heavy client construction.
I have a dedicated server without an IPv4 Address, so only IPv6 subnet, and in the response of e.g. get_server
or list_servers
, the ip
field is null, which means serde can't deserialize the response.
It looks like this is undocumented behavior, at least the Robot API docs have no example for this.
The relevant piece of code:
hrobot-rs/src/api/server/models.rs
Lines 141 to 146 in 186d3dd
This could be fixed by either wrapping the Vec in an Option (I tried that locally, would be a breaking change), or using a custom deserialization function.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.