Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Work on ci #1

Merged
merged 44 commits into from
Dec 27, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
44 commits
Select commit Hold shift + click to select a range
0340460
Work on ci
duckhawk Dec 22, 2023
89cf333
wip
duckhawk Dec 22, 2023
f7ce6dc
Wip
duckhawk Dec 22, 2023
cd79594
Wip
duckhawk Dec 22, 2023
0534d44
Wip
duckhawk Dec 22, 2023
af4e18d
Wip
duckhawk Dec 22, 2023
4a31ef7
Wip
duckhawk Dec 22, 2023
9b40951
Wip
duckhawk Dec 22, 2023
949b48c
Wip
duckhawk Dec 22, 2023
c814925
Wip
duckhawk Dec 22, 2023
1b84fe9
Wip
duckhawk Dec 22, 2023
32ad053
Wip
duckhawk Dec 22, 2023
68aa9e4
Wip tags
duckhawk Dec 22, 2023
61e1c7f
Commented workflows
AleksZimin Dec 22, 2023
e7762c5
Update build_dev.yml
dxavx Dec 25, 2023
03e9f0c
Update main.go
dxavx Dec 26, 2023
a76c853
Create deploy_dev.yml
dxavx Dec 26, 2023
9224187
Update deploy_dev.yml
dxavx Dec 26, 2023
8f0a2c7
Create deploy_prod.yml
dxavx Dec 26, 2023
c3873ae
Update deploy_prod.yml
dxavx Dec 26, 2023
9b442a8
Update deploy_prod.yml
dxavx Dec 26, 2023
fe18ee9
Update deploy_prod.yml
dxavx Dec 26, 2023
9804d40
Update deploy_prod.yml
dxavx Dec 26, 2023
187765d
Update deploy_prod.yml
dxavx Dec 27, 2023
70d12c7
Update deploy_prod.yml
dxavx Dec 27, 2023
ca6778b
Update deploy_prod.yml
dxavx Dec 27, 2023
b5e7f7c
Update deploy_prod.yml
dxavx Dec 27, 2023
878fcff
Update deploy_prod.yml
dxavx Dec 27, 2023
80fa537
Add EN usage.md and configuration.md
kirkonru Dec 21, 2023
2ceadf3
Change priority for path in blockdevices
AleksZimin Dec 21, 2023
f0c1257
Change priority for vg in lvmvolumegroup
AleksZimin Dec 21, 2023
8f5d591
Fix enum in status.health for lvmvolumegroup
AleksZimin Dec 21, 2023
08d9b7d
Add FAQ.md and translate
kirkonru Dec 25, 2023
8828631
Changes blockdevice deletion logic
ViktorKram Dec 27, 2023
a29f743
Merge pull request #2 from deckhouse/migrate-code
AleksZimin Dec 27, 2023
0ee4560
Change version in Chart.yaml
AleksZimin Dec 27, 2023
a6f389e
Merge branch 'main' into work-on-ci
AleksZimin Dec 27, 2023
ee37e91
Remove "log message Hello from github"
AleksZimin Dec 27, 2023
5d63503
Add kmod to sds-node-configurator agent
AleksZimin Dec 27, 2023
490931b
Enable build for prod
AleksZimin Dec 27, 2023
e2b2991
Fix envs for build_prod workflow
AleksZimin Dec 27, 2023
0372668
Enable build for FE
AleksZimin Dec 27, 2023
86b3e23
Add credentials env to deploy_prod
AleksZimin Dec 27, 2023
da4b1f7
Enable EE/CE
AleksZimin Dec 27, 2023
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
29 changes: 29 additions & 0 deletions .github/workflows/build_dev.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
on:
pull_request:

jobs:
dev_setup_build:
runs-on: ubuntu-latest
env:
MODULES_REGISTRY: ${{ vars.DEV_REGISTRY }}
CI_COMMIT_REF_NAME: ${{ github.ref_name }}
MODULES_MODULE_NAME: ${{ vars.MODULE_NAME }}
MODULES_MODULE_SOURCE: ${{ vars.DEV_MODULE_SOURCE }}
MODULES_REGISTRY_LOGIN: ${{ secrets.DEV_MODULES_REGISTRY_LOGIN }}
MODULES_REGISTRY_PASSWORD: ${{ secrets.DEV_MODULES_REGISTRY_PASSWORD }}
name: Build and Push images
steps:
- run: |
MODULES_MODULE_TAG="$(echo pr${{ github.ref_name }} | sed 's/\/.*//g')"
echo $MODULES_REGISTRY
echo $CI_COMMIT_REF_NAME
echo "MODULES_MODULE_TAG=$MODULES_MODULE_TAG" >> "$GITHUB_ENV"
echo $MODULES_MODULE_NAME
echo $MODULES_MODULE_SOURCE
echo $MODULES_MODULE_TAG
shell: bash
name: Show vars

- uses: actions/checkout@v4
- uses: deckhouse/modules-actions/setup@v1
- uses: deckhouse/modules-actions/build@v1
73 changes: 73 additions & 0 deletions .github/workflows/build_prod.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,73 @@
name: Build and push for prod

env:
MODULES_REGISTRY: ${{ vars.PROD_REGISTRY }}
CI_COMMIT_REF_NAME: ${{ github.ref_name }}
MODULES_MODULE_NAME: ${{ vars.MODULE_NAME }}
MODULE_SOURCE_NAME: ${{ vars.PROD_MODULE_SOURCE_NAME }}
MODULES_REGISTRY_LOGIN: ${{ secrets.PROD_MODULES_REGISTRY_LOGIN }}
MODULES_REGISTRY_PASSWORD: ${{ secrets.PROD_MODULES_REGISTRY_PASSWORD }}
MODULES_MODULE_TAG: ${{ github.ref_name }}

on:
push:
tags:
- '**'

jobs:
prod_ce_setup_build:
runs-on: ubuntu-latest
name: Build and Push CE
steps:
- name: SET VAR
run: |
echo "MODULES_MODULE_SOURCE=$MODULES_REGISTRY/$MODULE_SOURCE_NAME/ce/modules" >> "$GITHUB_ENV"
- run: |
echo $MODULES_REGISTRY
echo $MODULES_MODULE_NAME
echo $MODULES_MODULE_SOURCE
echo $MODULES_MODULE_TAG
shell: bash
name: Show vars

- uses: actions/checkout@v4
- uses: deckhouse/modules-actions/setup@v1
- uses: deckhouse/modules-actions/build@v1

prod_ee_setup_build:
runs-on: ubuntu-latest
name: Build and Push EE
steps:
- name: SET VAR
run: |
echo "MODULES_MODULE_SOURCE=$MODULES_REGISTRY/$MODULE_SOURCE_NAME/ee/modules" >> "$GITHUB_ENV"
- run: |
echo $MODULES_REGISTRY
echo $MODULES_MODULE_NAME
echo $MODULES_MODULE_SOURCE
echo $MODULES_MODULE_TAG
shell: bash
name: Show vars

- uses: actions/checkout@v4
- uses: deckhouse/modules-actions/setup@v1
- uses: deckhouse/modules-actions/build@v1

prod_fe_setup_build:
runs-on: ubuntu-latest
name: Build and Push FE
steps:
- name: SET VAR
run: |
echo "MODULES_MODULE_SOURCE=$MODULES_REGISTRY/$MODULE_SOURCE_NAME/fe/modules" >> "$GITHUB_ENV"
- run: |
echo $MODULES_REGISTRY
echo $MODULES_MODULE_NAME
echo $MODULES_MODULE_SOURCE
echo $MODULES_MODULE_TAG
shell: bash
name: Show vars

- uses: actions/checkout@v4
- uses: deckhouse/modules-actions/setup@v1
- uses: deckhouse/modules-actions/build@v1
48 changes: 0 additions & 48 deletions .github/workflows/deploy_dev.yml

This file was deleted.

102 changes: 73 additions & 29 deletions .github/workflows/deploy_prod.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,15 @@
name: Deploy Prod

env:
MODULES_REGISTRY: ${{ vars.PROD_REGISTRY }}
MODULE_SOURCE_NAME: ${{ vars.PROD_MODULE_SOURCE_NAME }}
CI_COMMIT_REF_NAME: ${{ github.ref_name }}
MODULES_MODULE_NAME: ${{ vars.MODULE_NAME }}
RELEASE_CHANNEL: ${{ github.event.inputs.version }}
MODULES_REGISTRY_LOGIN: ${{ secrets.PROD_MODULES_REGISTRY_LOGIN }}
MODULES_REGISTRY_PASSWORD: ${{ secrets.PROD_MODULES_REGISTRY_PASSWORD }}
MODULES_MODULE_TAG: ${{ github.event.inputs.tag }}

on:
workflow_dispatch:
inputs:
Expand All @@ -13,47 +23,81 @@ on:
- "early-access"
- "stable"
- "rock-solid"

edition:
description: "Select edition"
type: choice
default: fe
options:
- "ce"
- "ee"
- "fe"

ce:
type: boolean
description: CE
ee:
type: boolean
description: EE
fe:
type: boolean
description: FE

tag:
description: "Tag of the module, exapmle v1.21.1"
description: "Tag of the module, example v1.21.1"
type: string
required: true

jobs:
deploy:
print-vars:
runs-on: ubuntu-latest
env:
MODULES_REGISTRY: ${{ vars.PROD_REGISTRY }}
MODULE_SOURCE_NAME: ${{ vars.PROD_MODULE_SOURCE_NAME }}
CI_COMMIT_REF_NAME: ${{ github.ref_name }}
MODULES_MODULE_NAME: ${{ vars.MODULE_NAME }}
MODULES_MODULE_SOURCE: $MODULES_REGISTRY/$MODULE_SOURCE_NAME/${{ github.event.inputs.edition }}/modules
RELEASE_CHANNEL: ${{ github.event.inputs.version }}
MODULES_MODULE_TAG: ${{ github.event.inputs.tag }}
name: Build and Push images
name: Print vars
steps:
- run: |
- name: PRINT VARS
run: |
echo $MODULES_REGISTRY
echo $MODULE_SOURCE_NAME
echo $CI_COMMIT_REF_NAME
echo $MODULES_MODULE_NAME
echo $MODULES_MODULE_SOURCE
echo $RELEASE_CHANNEL
echo $MODULES_MODULE_TAG
shell: bash
name: Show vars


# steps:
# - uses: actions/checkout@v4
# - uses: deckhouse/modules-actions/setup@v1
# - uses: deckhouse/modules-actions/deploy@v1

job-CE:
name: Edition CE
runs-on: ubuntu-latest
if: github.event.inputs.ce == 'true'
steps:
- run: echo "CE"
- name: SET VAR
run: |
echo "MODULES_MODULE_SOURCE=$MODULES_REGISTRY/$MODULE_SOURCE_NAME/ce/modules" >> "$GITHUB_ENV"
- name: ECHO VAR
run: |
echo $MODULES_MODULE_SOURCE
- uses: actions/checkout@v4
- uses: deckhouse/modules-actions/setup@v1
- uses: deckhouse/modules-actions/deploy@v1

job-EE:
name: Edition EE
runs-on: ubuntu-latest
if: github.event.inputs.ee == 'true'
steps:
- run: echo "EE"
- name: SET VAR
run: |
echo "MODULES_MODULE_SOURCE=$MODULES_REGISTRY/$MODULE_SOURCE_NAME/ee/modules" >> "$GITHUB_ENV"
- name: ECHO VAR
run: |
echo $MODULES_MODULE_SOURCE
- uses: actions/checkout@v4
- uses: deckhouse/modules-actions/setup@v1
- uses: deckhouse/modules-actions/deploy@v1

job-FE:
name: Edition FE
runs-on: ubuntu-latest
if: github.event.inputs.fe == 'true'
steps:
- run: echo "FE"
- name: SET VAR
run: |
echo "MODULES_MODULE_SOURCE=$MODULES_REGISTRY/$MODULE_SOURCE_NAME/fe/modules" >> "$GITHUB_ENV"
- name: ECHO VAR
run: |
echo $MODULES_MODULE_SOURCE
- uses: actions/checkout@v4
- uses: deckhouse/modules-actions/setup@v1
- uses: deckhouse/modules-actions/deploy@v1
2 changes: 1 addition & 1 deletion Chart.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
name: sds-node-configurator
version: 0.0.25-dev.1701781997
version: 0.0.1
dependencies:
- name: deckhouse_lib_helm
version: 1.1.3
Expand Down
1 change: 0 additions & 1 deletion crds/blockdevices.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,6 @@ spec:
name: Path
type: string
description: Actual device path (name).
priority: 1
- jsonPath: .status.actualVGNameOnTheNode
name: VG
type: string
Expand Down
9 changes: 4 additions & 5 deletions crds/lvmvolumegroup.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -87,11 +87,11 @@ spec:
type: string
description: |
The global state of the Volume Group. Might be:
- Operational (if everything is fine)
- NonOperational (if there are some problems in the volume group)
enum:
- Operational (if everything is fine with the Volume Group)
- NonOperational (if there are some problems with the Volume Group)
- NonOperational (if there are some problems in the Volume Group)
enum:
- Operational
- NonOperational
message:
type: string
description: |
Expand Down Expand Up @@ -192,7 +192,6 @@ spec:
name: VG
type: string
description: Actual VG name.
priority: 1
- jsonPath: .spec.type
name: type
type: string
Expand Down
14 changes: 14 additions & 0 deletions docs/CONFIGURATION.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
---
title: "The Sds-Node-Configurator module: settings"
---
{% alert level="warning" %}
The module is guaranteed to work in the following cases only:
- if stock kernels shipped with [supported distributions](../../supported_versions.html#linux) are used;
- if a 10Gbps network is used.

As for any other configurations, the module may work, but its smooth operation is not guaranteed.
{% endalert %}

{% include module-bundle.liquid %}

No configuration on the user's side is required
Loading