Commit Graph

29 Commits

Author SHA1 Message Date
Juan Carlos Mejías Rodríguez
1c3a1c665e Add unit tests for checkResponseForErrors() 2019-08-25 00:14:53 -04:00
Juan Carlos Mejías Rodríguez
7fb7710c55 Remove condition of requestBody being not nil to set user agent 2019-08-25 00:14:53 -04:00
Juan Carlos Mejías Rodríguez
a8bed6a7cc Rename request and reponse to requestBody and responseBody 2019-08-25 00:14:53 -04:00
Juan Carlos Mejías Rodríguez
19f58c4e1f Move Content-Type header setting to doJSON() in Portainer client 2019-08-25 00:14:53 -04:00
Juan Carlos Mejías Rodríguez
14043a8bf8 Refactor auth token setting in Portainer client 2019-08-25 00:14:53 -04:00
Juan Carlos Mejías Rodríguez
2cc0faa625 Add unit tests for portainerClientImpl.do() 2019-08-25 00:14:53 -04:00
Juan Carlos Mejías Rodríguez
f82f116e1b Change GetTranslatedStackType to use StackType instead of Stack 2019-08-25 00:14:53 -04:00
Juan Carlos Mejías Rodríguez
c0cc50c81a Add unit test for client/portainerTypes.go 2019-08-25 00:14:53 -04:00
Juan Carlos Mejías Rodríguez
3194260c05 Remove else statement with single return sentence 2019-08-23 13:14:49 -04:00
Juan Carlos Mejías Rodríguez
161fc48b5a Add comments to exported types to pass go-lint 2019-08-23 13:12:53 -04:00
Juan Carlos Mejías Rodríguez
be51da44bf Rename some identifiers to pass go-lint 2019-08-23 12:35:01 -04:00
Juan Carlos Mejías Rodríguez
0b887b414b Replace Portainer struct copies with original ones wherever possible 2019-08-10 12:14:55 -04:00
Juan Carlos Mejías Rodríguez
cf823f9dcf Add custom User-Agent to API requests 2019-08-09 15:16:12 -04:00
Juan Carlos Mejías Rodríguez
2261b4f6ac Add GetEndpointGroups() function to client 2019-08-09 13:17:40 -04:00
Juan Carlos Mejías Rodríguez
219adc5c76 Add EndpointGroup struct 2019-08-09 13:17:20 -04:00
Juan Carlos Mejías Rodríguez
8a7bb9e79d Remove unused fields from client.Stack struct 2019-08-09 13:06:47 -04:00
Juan Carlos Mejías Rodríguez
7fcdd73066 Move Portainer API URL parsing outside the client 2019-08-09 12:39:40 -04:00
Juan Carlos Mejías Rodríguez
d4956584a1 Add log message after stack deployment or removal 2019-08-09 11:38:59 -04:00
Juan Carlos Mejías Rodríguez
0f0eaa7c3f Add tests for client.NewClient() 2019-08-08 11:56:07 -04:00
Juan Carlos Mejías Rodríguez
a7bfa6e0b0 Add tests for Client.Authenticate() 2019-08-08 11:56:07 -04:00
Juan Carlos Mejías Rodríguez
b3f1989a25 Fix inconsistencies with EndpointID and SwarmID filtering 2019-08-08 11:56:07 -04:00
Juan Carlos Mejías Rodríguez
0c3e255bf2 Fix Client interface's functions comments 2019-08-08 11:56:07 -04:00
Juan Carlos Mejías Rodríguez
1830fea7b7 Move PrintVerbose() calls in client to it's callers 2019-08-08 11:56:07 -04:00
Juan Carlos Mejías Rodríguez
955a79de6f Remove printing of token after authentication 2019-08-08 11:56:07 -04:00
Juan Carlos Mejías Rodríguez
5748d862bb Move PrintDebugRequest() and PrintDebugResponse() calls in client to hooks 2019-08-08 11:56:07 -04:00
Juan Carlos Mejías Rodríguez
76d92c5885 Add "before request" and "after response" hooks to client 2019-08-08 11:56:07 -04:00
Juan Carlos Mejías Rodríguez
3989715b70 Change PortainerClientImp to unexported 2019-08-08 11:56:07 -04:00
Juan Carlos Mejías Rodríguez
27b418cb3c Rename client.ClientConfig to client.Config 2019-08-08 11:56:07 -04:00
Juan Carlos Mejías Rodríguez
9c79379191 Split common package into common, client, and util packages 2019-08-08 11:56:07 -04:00