-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Update up cluster * Add ignore __pycache__ * Fix install requrements * Add check ready nodes * Add new helm chart * Fix critical error * Add param skip_exising if exist helm * Test * Check * Test * Update up cluster * Added README.md
- Loading branch information
Showing
7 changed files
with
73 additions
and
32 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
# Helm package for CI/CD | ||
|
||
## Installing the Chart | ||
|
||
Add the repository to helm. How to do it is described in | ||
detail [here](https://github.com/text-adi/helm-charts?tab=readme-ov-file#add-repository). | ||
|
||
To install the chart: | ||
|
||
Example: | ||
|
||
```console | ||
helm install ci-cd-helper textadi/ci-cd-helper | ||
``` | ||
|
||
## Installing the Chart | ||
|
||
To update the chart: | ||
|
||
```console | ||
helm upgrade ci-cd-helper textadi/ci-cd-helper | ||
``` | ||
|
||
## Parameters | ||
|
||
| Name | Description | Value | | ||
|--------------------|------------------------------------------------------------------------------------------------------------------------------------------------------------|-------------------------------| | ||
| `image.registry` | Image registry | `docker.io` | | ||
| `image.repository` | Image repository | `textadi/ecr-registry-helper` | | ||
| `image.tag` | Image tag | `2.15.40-1.30.0` | | ||
| `apiServer` | Link to server cluster API. To get the required value, run the command in the terminal `kubectl config view --minify --output jsonpath={..cluster.server}` | `https://localhost:6443` | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,2 @@ | ||
docker==7.1.0 | ||
docker==7.1.0 | ||
click==8.1.7 |
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
import time | ||
|
||
import click | ||
|
||
from cluster import K0SCluster | ||
|
||
|
||
@click.group() | ||
def cli(): | ||
pass | ||
|
||
|
||
@click.command('up-cluster') | ||
@click.option('--tag', help='Version docker images', type=str) | ||
@click.option('--workers', help='Count workers', type=int) | ||
@click.option('--ready-wait', is_flag=True, help='Count workers', type=bool, default=False) | ||
@click.option('--force', is_flag=True, help='Count workers', type=bool, default=False) | ||
def up_cluster(tag: str, workers: int, ready_wait: bool, force: bool): | ||
cluster = K0SCluster(tag) | ||
if force: | ||
cluster.delete_cluster() | ||
cluster.create_master() | ||
cluster.create_workers(workers) | ||
|
||
while ready_wait: | ||
if cluster.is_ready_nodes(): | ||
break | ||
time.sleep(1) | ||
print(cluster.admin_config) | ||
|
||
|
||
cli.add_command(up_cluster) | ||
|
||
if __name__ == '__main__': | ||
cli() |
This file was deleted.
Oops, something went wrong.