Commit Graph

11 Commits

Author SHA1 Message Date
Ed Bartosh
1b1206e39a fpga: change webhook service port
Changed port webhook is listening on from 443 to 8443 to be able
to bind to it from non-root user account.
2020-01-14 16:31:12 +02:00
Alexander Kanevskiy
67825dcc06 Fix admission hook for pods generated by ReplicaSet
In the pods generated automatically by Deployment/ReplicaSets
fields name and namespace might be missing.
We can use information about namespace from request itself.
2019-10-25 17:40:42 +03:00
Dmitry Rozhkov
565045f6f2 fpga: mutate pods with CRDs from its corresponding namespace
CRDs for AF or Region mappings are scoped to namespaces. So an
admitted pod has to be mutated with CRDs existing in the same
namespace as the pod's.

Closes #167
2019-04-02 12:17:08 +03:00
Dmitry Rozhkov
90776a63c7 webhook: make debug message meaningful 2018-10-04 10:19:23 +03:00
Dmitry Rozhkov
f60aad70d6 webhook: deny all requests for unknown FPGA resources 2018-08-20 12:09:31 +03:00
Dmitry Rozhkov
eccd70c600 replace glog with simpler home-grown debug logging 2018-08-16 17:40:16 +03:00
Dmitry Rozhkov
2ff6c5929a Use annotated errors for tracing 2018-08-16 17:31:19 +03:00
Dmitry Rozhkov
271bc0d29a webhook: add dynamically configured mappings
Currently we have hardcoded mapping from human readable names of
AFs and FPGA regions like arria10-nlb0 to the resource names
produced by the FPGA device plugin. This is not sustainable
long term solution.

Implement CRD based mappings so that a new mapping can be added or
removed dynamically by cluster admins with CRD resources.
2018-08-08 17:58:18 +03:00
Dmitry Rozhkov
972a80bedb fpga_admissionwebhook: update resource names 2018-07-30 15:29:33 +03:00
Dmitry Rozhkov
3d30fa2872 fpga_admissionwebhook: add orchestrated mode
In `orchestrated` mode the webhook parses requested resources and to translates
them to a container's ENV variables to let CRI hooks to program the FPGA with
requested bitstreams before starting the container.
2018-06-29 16:30:36 +03:00
Dmitry Rozhkov
562f8fe722 fpga-admissionwebhook: add initial implementation 2018-06-19 14:55:59 +03:00