[python]Usage examples of pyvault2

Introduction I am using hashicorp vault to store secrets of devices, and I am writing my own functions in python for my personal usage. There is a hashicorp vault api wrapper module known as hvac, at first I attempted to use hvac but I found it to be extremely difficult to use and not enough … Continue reading [python]Usage examples of pyvault2

[Go] API client

Background web client implementation is within the package net/http, this code uses this package to write an API client. Examples can be found in Golang. This API test website is used for testing the code. The endpoint which the code uses is /posts/1 as the json response is the shortest. Postman This is the response … Continue reading [Go] API client

[python]Deploy flask api with gunicorn and nginx

NGINX is a load balancer and a reverse proxy, the purpose is to interface between user and WSGI server. Web server cannot directly interact with Flask like php, to use the Flask web application a WSGI server is required, in this case Gunicorn is a WSGI server. Gunicorn will run the python flask application and … Continue reading [python]Deploy flask api with gunicorn and nginx

[python]404 not found after flask_restful deployed with gunicorn

Ok, I have been struggling to get the gunicorn worked with the flask_restful. So finally I found my answer here. after the if __name__ == "__main__" only run the app.run(). so I did some adjustment of my codes to become like this. Then I run gunicorn -b app:app and it worked. app:app, the app … Continue reading [python]404 not found after flask_restful deployed with gunicorn