Skip to content

Commit 2f5f042

Browse files
committed
Global rewrite using Swagger to generate codes
1 parent f1df715 commit 2f5f042

File tree

1,183 files changed

+142784
-18169
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

1,183 files changed

+142784
-18169
lines changed

README.md

+7-4
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,25 @@
11
# Kubernetes API PHP Wrapper
22

3-
This is a PHP FULL implementation of [Kubernetes](https://kubernetes.io)'s [API(Ver 1.6)](https://kubernetes.io/docs/api-reference/v1.6/)
3+
This is a full PHP client reverse engineered from Kubernetes' Swagger defination.
44

55
[![Minimum PHP Version](https://img.shields.io/badge/php-%3E%3D7-green.svg?style=plastic)](https://php.net/)
66
[![Gitter](https://badges.gitter.im/allansun/kubernetes-php-api.svg?style=plastic)](https://gitter.im/allansun/kubernetes-php-api?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge)
77

88
## Installation
99

10-
Add a dependency on kubernetes/api to your project's `composer.json` by utilizing the [Composer](https://getcomposer.org/) package manager.
10+
Add a dependency on kubernetes/php-client to your project's `composer.json` by utilizing the [Composer]
11+
(https://getcomposer.org/) package manager.
1112

1213
```json
1314
{
1415
"require-dev": {
15-
"kubernetes/api": "@stable"
16+
"kubernetes/php-client": "{KUBERNETES_VERSION}"
1617
}
1718
}
1819
```
1920

21+
{KUBERNETES_VERSION} is the version of your Kubernets cluster
22+
2023
## Usage instruction
2124

2225

@@ -30,5 +33,5 @@ Kubernetes\Client::configure('username','apikey');
3033
## API Implementations
3134

3235
This API Wrapper implements all API endpoints currently provided by Kubernetes, for full documentation on how to use
33-
it please refere to [API](https://kubernetes.io/docs/api-reference/v1.6/)
36+
it please refere to [API](https://kubernetes.io/docs/reference/#api-reference)
3437

bin/console

+18
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
#!/usr/bin/env php
2+
<?php
3+
// application.php
4+
5+
require __DIR__ . '/../vendor/autoload.php';
6+
7+
use CodeGenerator\Command;
8+
use Symfony\Component\Console\Application;
9+
10+
$application = new Application();
11+
12+
// ... register commands
13+
$application->addCommands([
14+
new Command\GenerateCommand()
15+
]);
16+
17+
18+
$application->run();

composer.json

+16-8
Original file line numberDiff line numberDiff line change
@@ -15,16 +15,17 @@
1515
}
1616
],
1717
"require": {
18-
"php": ">=7",
18+
"php": ">=7.1",
1919
"guzzlehttp/guzzle": "~6.0",
20-
"monolog/monolog": "@stable",
21-
"zendframework/zend-eventmanager": "^3.1",
22-
"zendframework/zend-hydrator": "^2.2",
23-
"zendframework/zend-filter": "^2.7",
24-
"zendframework/zend-servicemanager": "^3.3"
20+
"monolog/monolog": "@stable"
2521
},
2622
"require-dev": {
27-
"phpunit/phpunit": "~6.1"
23+
"phpunit/phpunit": "~7",
24+
"allansun/openapi-parser": "dev-master",
25+
"zendframework/zend-code": "3.3.*",
26+
"symfony/console": "4.1.*",
27+
"mattketmo/camel": "^1.1",
28+
"symfony/filesystem":"4.1.*"
2829
},
2930
"autoload": {
3031
"psr-4": {
@@ -33,9 +34,16 @@
3334
},
3435
"autoload-dev": {
3536
"psr-4": {
36-
"Kubernetes\\Test\\": "test"
37+
"Kubernetes\\Test\\": "test",
38+
"CodeGenerator\\": "dev_src"
3739
}
3840
},
41+
"archive": {
42+
"exclude": [
43+
"openapi",
44+
"bin"
45+
]
46+
},
3947
"minimum-stability": "dev",
4048
"prefer-stable": true
4149
}

0 commit comments

Comments
 (0)