@@ -44,8 +44,7 @@ public function test_http_authentication()
44
44
$ this ->app ['config ' ]->set ('k8s.default ' , 'http ' );
45
45
$ this ->app ['config ' ]->set ('k8s.connections.http ' , [
46
46
'driver ' => 'http ' ,
47
- 'host ' => env ('KUBE_HOST ' , '127.0.0.1 ' ),
48
- 'port ' => env ('KUBE_PORT ' , 8080 ),
47
+ 'host ' => env ('KUBE_HOST ' , 'http://127.0.0.1:8080 ' ),
49
48
'ssl ' => [
50
49
'certificate ' => '/path/to/.minikube/client.crt ' ,
51
50
'key ' => '/path/to/.minikube/client.key ' ,
@@ -82,8 +81,7 @@ public function test_token_authentication()
82
81
$ this ->app ['config ' ]->set ('k8s.default ' , 'token ' );
83
82
$ this ->app ['config ' ]->set ('k8s.connections.token ' , [
84
83
'driver ' => 'token ' ,
85
- 'host ' => env ('KUBE_HOST ' , '127.0.0.1 ' ),
86
- 'port ' => env ('KUBE_PORT ' , 8080 ),
84
+ 'host ' => env ('KUBE_HOST ' , 'http://127.0.0.1:8080 ' ),
87
85
'ssl ' => [
88
86
'certificate ' => '/path/to/.minikube/client.crt ' ,
89
87
'key ' => '/path/to/.minikube/client.key ' ,
@@ -115,6 +113,12 @@ public function test_token_authentication()
115
113
116
114
public function test_in_cluster_config ()
117
115
{
116
+ $ this ->app ['config ' ]->set ('k8s.default ' , 'cluster ' );
117
+ $ this ->app ['config ' ]->set ('k8s.connections.cluster ' , [
118
+ 'driver ' => 'cluster ' ,
119
+ 'host ' => env ('KUBE_HOST ' , 'https://kubernetes.default.svc.cluster.local ' ),
120
+ ]);
121
+
118
122
$ cluster = LaravelK8sFacade::connection ('cluster ' )->getCluster ();
119
123
120
124
[
0 commit comments