This repository was archived by the owner on Feb 8, 2026. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
🚀 Feature/multicloud: Major security fixes, testing overhaul, and code quality improvements #11
Merged
Merged
Changes from all commits
Commits
Show all changes
44 commits
Select commit
Hold shift + click to select a range
0eee3c6
Merge pull request #3 from abevz/feature/improvements
abevz f8a859e
Update RELEASE_NOTES.md with security and code quality improvements
abevz 9299f5f
🔧 Hotfix v1.1.1: Fix critical status command bugs (#5)
abevz 4821ad9
fix: hotfix v1.1.2 - restore addon functionality and fix all module bugs
abevz c694519
docs: Add release notes for v1.1.2 hotfix
abevz 10e0a16
🚀 Modular Addon System - Complete Architecture Redesign (v1.2.0) (#7)
abevz 37025a5
feat: update core module secrets mapping and add VS Code settings (#8)
abevz 25e49bc
docs: add comprehensive secrets management guide and update documenta…
abevz 45572bb
refactor: completely refactor 60_tofu.sh module for better maintainab…
abevz bfaf407
Add comprehensive unit tests for refactored 60_tofu.sh functions
abevz 592fcca
Add comprehensive pytest test suite for refactored 60_tofu.sh functions
abevz 4ace271
Fix automatic environment loading and Proxmox API authentication
abevz b235610
🎉 Fix Kubernetes connectivity and add comprehensive unit tests
abevz 30467a1
Fix configuration inconsistency and improve test isolation
abevz 1a965df
Fix ./cpc ctx command and workspace management
abevz 5f8415a
Clean up test artifacts and temporary files
abevz 0c8b298
feat: Refactor tofu module and fix AWS credentials handling
abevz 080a15b
🔄 Restore deleted test files from commit 5f8415a
abevz 5a86d80
feat: Add workspace command support with backward compatibility
abevz 8514d41
feat: Comprehensive Ansible module refactoring and testing
abevz f56cab7
feat: Comprehensive pytest test suite for 00_core.sh module
abevz e2db05e
Fix Ansible playbook syntax error and refactor k8s_cluster module
abevz 85d4cbb
fix: resolve k8s_get_kubeconfig certificate corruption and add compre…
abevz c9f70f8
enhance: Comprehensive test runner infrastructure improvements
abevz db35552
Fix k8s_nodes module and add uncordon functionality
abevz 08ad75a
Add comprehensive unit tests for 10_proxmox module
abevz ce934d4
Improve Proxmox module and hostname generation system
abevz 84f8e8e
Add Python test cache to .gitignore
abevz 67da7aa
Remove pycache file from git tracking
abevz 4d2a76d
Add comprehensive pytest test suite for k8s_nodes module
abevz 0487581
feat(testing): Add tests for cluster_ops and refactor module
abevz b5b001e
fix(refactor): Correct stdout/stderr pollution in helper function
abevz 0e95813
fix(ops): Correct CoreDNS config and validation logic
abevz 99e6083
fix(ops): Correct CoreDNS config and validation logic
abevz 75b5787
feat(refactor): Refactor 70_dns_ssl.sh module
abevz 478eb8d
fix(tests): Ensure test runner restores original CPC context and isol…
abevz cd372e8
feat(testing): overhaul and repair test suite
abevz 227050e
feat(ssh): Refactor SSH module and add robust test suite
abevz 0f587bb
feat(testing): Create comprehensive unit test suite
abevz 6d31184
feat(linting): Integrate shellcheck and tflint
abevz 88e0d74
feat(security): Major security improvements and release preparation
abevz c12b953
Security: Fix critical and medium-priority vulnerabilities
abevz 7160f2e
Merge branch 'main' into feature/multicloud
abevz 4ae4403
fix: resolve shellcheck SC2168 errors and add tflint to CI
abevz File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or 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,38 @@ | ||
| name: Linting | ||
|
|
||
| on: | ||
| pull_request: | ||
| branches: | ||
| - main | ||
| - 'feature/**' | ||
|
|
||
| jobs: | ||
| shellcheck: | ||
| name: Shellcheck | ||
| runs-on: ubuntu-latest | ||
| steps: | ||
| - name: Checkout code | ||
| uses: actions/checkout@v3 | ||
|
|
||
| - name: Install shellcheck | ||
| run: sudo apt-get update && sudo apt-get install -y shellcheck | ||
|
|
||
| - name: Run shellcheck | ||
| run: make lint-shell | ||
|
|
||
| tflint: | ||
| name: TFLint | ||
| runs-on: ubuntu-latest | ||
| steps: | ||
| - name: Checkout code | ||
| uses: actions/checkout@v3 | ||
|
|
||
| - name: Install tflint | ||
| run: | | ||
| TFLINT_VERSION=$(curl -s https://api.github.com/repos/terraform-linters/tflint/releases/latest | grep '"tag_name"' | cut -d'"' -f4 | sed 's/v//') | ||
| wget "https://github.com/terraform-linters/tflint/releases/download/v${TFLINT_VERSION}/tflint_linux_amd64.zip" | ||
| unzip tflint_linux_amd64.zip | ||
| sudo mv tflint /usr/local/bin/ | ||
|
|
||
| - name: Run tflint | ||
| run: cd terraform && tflint |
This file contains hidden or 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 hidden or 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,2 @@ | ||
| # Ignore SC2086 (Double quote to prevent globbing and word splitting) | ||
| disable=SC2086 | ||
This file contains hidden or 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,3 @@ | ||
| config { | ||
| preset = "all" | ||
| } |
This file contains hidden or 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,75 @@ | ||
| # CPC Auto Environment Loading | ||
|
|
||
| ## Overview | ||
| CPC now supports automatic loading of environment variables into your shell session. This allows you to access secrets and configuration variables in your terminal without running `cpc load_secrets` manually. | ||
|
|
||
| ## Commands | ||
|
|
||
| ### `cpc auto` | ||
| Loads all environment variables and outputs export commands for shell sourcing. | ||
|
|
||
| ```bash | ||
| # View available variables | ||
| ./cpc auto | ||
|
|
||
| # Load variables into current shell | ||
| eval "$(./cpc auto 2>/dev/null | grep -E '^export ')" | ||
|
|
||
| # Load variables into new shell | ||
| zsh -c 'eval "$(./cpc auto 2>/dev/null | grep -E \"^export \")" && ./cpc ctx' | ||
| ``` | ||
|
|
||
| ### `cpc-auto` script | ||
| Simple wrapper script for loading environment variables. | ||
|
|
||
| ```bash | ||
| # Load variables into current shell | ||
| ./cpc-auto | ||
|
|
||
| # Use in new shell | ||
| zsh -c './cpc-auto && ./cpc ctx' | ||
| ``` | ||
|
|
||
| ## What gets loaded | ||
|
|
||
| The auto-loading system loads variables from: | ||
|
|
||
| 1. **Global configuration** (`cpc.env`): | ||
| - Proxmox connection settings | ||
| - General project configuration | ||
|
|
||
| 2. **Workspace configuration** (`envs/{context}.env`): | ||
| - Kubernetes versions | ||
| - VM specifications | ||
| - DNS settings | ||
| - Template configurations | ||
|
|
||
| 3. **Secrets** (`terraform/secrets.sops.yaml`): | ||
| - Proxmox credentials | ||
| - SSH keys | ||
| - Cloud provider credentials | ||
| - Docker registry credentials | ||
|
|
||
| ## Usage Examples | ||
|
|
||
| ```bash | ||
| # Load variables and run tofu | ||
| ./cpc-auto && tofu plan | ||
|
|
||
| # Load variables and check cluster status | ||
| ./cpc-auto && ./cpc cluster-info | ||
|
|
||
| # Use in scripts | ||
| #!/bin/bash | ||
| ./cpc-auto | ||
| echo "Using TEMPLATE_VM_ID: $TEMPLATE_VM_ID" | ||
| echo "Using AWS_ACCESS_KEY_ID: $AWS_ACCESS_KEY_ID" | ||
| ``` | ||
|
|
||
| ## Troubleshooting | ||
|
|
||
| If you encounter AWS credential errors in tofu/OpenTofu, make sure to load the environment variables first: | ||
|
|
||
| ```bash | ||
| ./cpc-auto && tofu workspace select k8s133 | ||
| ``` |
This file contains hidden or 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 hidden or 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 was deleted.
Oops, something went wrong.
This file contains hidden or 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
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.