-
Notifications
You must be signed in to change notification settings - Fork 257
Compatibility with newest Python, Terraform versions + new features #103
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
Open
Ianyliu
wants to merge
191
commits into
28mm:master
Choose a base branch
from
Ianyliu:main
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
191 commits
Select commit
Hold shift + click to select a range
30da508
Commit all previous changes from previous repository
Ianyliu 10bdad3
Update comments and variables in blast-radius-aws.tf
Ianyliu 40bfb03
Allow Blast Radius to handle remote Terraform modules
Ianyliu 84ed47a
Improve Error Handling & Allow Blast Radius Viewer to be Accessed Eve…
Ianyliu 903bbdb
Remove console.logs
Ianyliu 724c33f
Add an alert to navbar on server failure
Ianyliu 304ff63
Include package data when setup.py is run during installation processes
Ianyliu ce4ac67
Add JS variables and documentation
Ianyliu 6e16c57
Update requirements.txt
Ianyliu 948dac8
Update Dockerfile to update packages in container
Ianyliu 8176bd0
Simplify code
Ianyliu 028ee36
Add Terratests to Dockerfile
Ianyliu 0d3631b
Provide doc fix support
Ianyliu cba20cd
Ignore .vscode configuration folders
Ianyliu 4308ac6
Update documentation for hcl2 instead of pyhcl
Ianyliu b0bad3a
Add compatibility with collections library regardless of Python version
Ianyliu f458970
Bump jinja2 from 2.10.1 to 2.11.3
dependabot[bot] a208749
Create codeql-analysis.yml
Ianyliu 6b2b3dc
Merge pull request #1 from Ianyliu/dependabot/pip/jinja2-2.11.3
Ianyliu 8b20178
Updated README.md
Ianyliu ddbed77
Allow print function to be used in even in Python 2
Ianyliu 933492d
Add Docker Build and Run PowerShell Scripts
Ianyliu de86130
Updated index.html
Ianyliu b326b4e
Update Docker Run PowerShell Script
Ianyliu 4f4bfa9
Update Docker Build PowerShell Command to Use BuildX
Ianyliu c87c952
Allow Users to Run Docker Container using BASH Script
Ianyliu 41f1702
Update PowerShell Script to Avoid Build Error
Ianyliu 38b3a70
Remove comments
Ianyliu 01c83fa
Fix Flask Installation Error
Ianyliu c473926
Resolve pip Installation Error
Ianyliu ffb5fbb
Merge branch 'main' into dev
Ianyliu 839ec88
Update pip before package installation (Dockerfile)
Ianyliu 7483fdb
Merge dev into main (#3)
Ianyliu 90a185a
Remove redundant code
Ianyliu 056b3ad
Remove redundant code
Ianyliu e1e020a
Default to Docker build instead of buildx build
Ianyliu 72a9b48
Added Kubernetes YAML files (lost in previous commits)
Ianyliu be2a276
Added non_tf_dir.html (lost in previous commits)
Ianyliu 2a16be0
Removed duplicate file (other one is in Docker folder)
Ianyliu 9701416
Trivial changes
Ianyliu b05c811
Fix Docker Run Error
Ianyliu 2688efe
Trivial naming change*
Ianyliu 9c2918d
Added a comment
Ianyliu edef86b
Changed log
Ianyliu 7149080
Updated .dockerignore to exclude unnecessary files
Ianyliu fc374a2
Updated .dockerignore to include .md files
Ianyliu 970dbc2
.
Ianyliu e1d3cfd
Enable Building Docker Images for Other Architectures
Ianyliu 8058a3e
Merge remote-tracking branch 'origin/dev' into dev
Ianyliu e4ef2bd
Merge dev into main (#4)
Ianyliu 0dd2234
Update README.md
Ianyliu 0cdb43b
Updated README.md
Ianyliu 09715c6
Updated README.md
Ianyliu a03923a
Updated README.md
Ianyliu b3ee3f8
Updated .gitignore
Ianyliu 4ce3769
Updated README.md
Ianyliu 5404916
Updated README.md
Ianyliu b7f09cc
Updated Docker.md
Ianyliu 77404fb
Updated example Terraform file
Ianyliu 515a362
Update README.md
Ianyliu 371044a
Optimize Docker image size and update Python to 3.9
Ianyliu 1a282bb
Create codeql.yml
Ianyliu c396e2b
Create dependency-review.yml
Ianyliu af07662
Merge dev branch (#6)
Ianyliu ed19848
Update Docker documentation
Ianyliu ab4bd08
Resolve Docker build error for PowerShell script
Ianyliu 9e045f7
Remove buildx for PowerShell script
Ianyliu e002009
Update Docker.md
Ianyliu fb2516d
Update Docker.md
Ianyliu b239f3a
Update documentation
Ianyliu b586527
Merge /Dev branch (#7)
Ianyliu 5852700
Update README.md
Ianyliu a51d9b0
Updated Docker.md
Ianyliu 9be4c3e
Remove console.log() and comments
Ianyliu 5aa64d3
Merge dev into main (#9)
Ianyliu c9f832d
Update README.md
Ianyliu 8b93b4a
Update README.md
Ianyliu b4ef8fa
Update README.md
Ianyliu 5926718
Improve error notifying
Ianyliu d1b082a
Resolve error where user is redirected even though Terraform director…
Ianyliu bc983d4
Dev merge (#10)
Ianyliu 9ff9fa1
Update README.md
Ianyliu 66fa26a
Resolve path error
Ianyliu 410422b
Resolve path error (#11)
Ianyliu 596a24e
Resolve path error
Ianyliu 982d92a
Resolve path error (#12)
Ianyliu fe2f01e
Resolve path error
Ianyliu a8c1ef9
Resolve path error (#13)
Ianyliu 21cdc89
Simplify code
Ianyliu e2c35a2
Simplify code (#14)
Ianyliu 0b5cb0d
Add detection for Python3
Ianyliu 3951df9
Add detection for Python3 (#15)
Ianyliu 7d52b34
Update README.md
Ianyliu 2289b66
Resolve Graph Colorization Error
Ianyliu 4b7127d
Removed redundant code
Ianyliu 9b3f005
Resolve errors (#16)
Ianyliu b9d904f
Added error logging
Ianyliu 30fdeda
Added error logging (#17)
Ianyliu ad5a715
Update README.md
Ianyliu 1b1c0aa
Avoid infinite recursions in terraform parser
blentz 6d87d30
Avoid infinite recursions in terraform parser (#18)
Ianyliu c7bfa55
Update README.md
Ianyliu b03db54
Update README.md
Ianyliu 64a9117
Update requirements.txt
Ianyliu 562b4db
Handle Remote Modules
Ianyliu 703b971
Update .gitignore
Ianyliu 0a3f4ed
Better Error Handling
Ianyliu fc829e4
Handle Remote Modules (#26)
Ianyliu 1a3647a
Better Error Handling (#27)
Ianyliu c382323
Update Terraform Version in Docker Image
Ianyliu 4c47dad
Remove Empty Line
Ianyliu 81b94e1
Merge Dev (#28)
Ianyliu 136e357
Repair Docker Error
Ianyliu 4a9027c
Bump setuptools from 63.4.3 to 65.5.1
dependabot[bot] 5299b27
Bump setuptools from 63.4.3 to 65.5.1 (#29)
Ianyliu ba8deeb
Update README.md
Ianyliu 4affffa
Install the CodeSee workflow. Learn more at https://docs.codesee.io
840a26c
Install the CodeSee workflow. (#30)
Ianyliu 5950d87
Bump flask from 2.1.2 to 2.3.2
dependabot[bot] a4e5696
Bump flask from 2.1.2 to 2.3.2 (#31)
Ianyliu b68284b
bump itsdangerous
glasnt 34f3ec9
Bump requests from 2.27.1 to 2.31.0
dependabot[bot] 6c4a3da
Bump requests from 2.27.1 to 2.31.0 (#34)
Ianyliu b65ec42
bump itsdangerous (#33)
Ianyliu 61bd968
Update requirements.txt
Ianyliu a43af05
Update requirements.txt (#40)
Ianyliu aa65da2
Merge branch 'main' into dev
Ianyliu 24214d2
Update requirements (#41)
Ianyliu 74444e8
Add File Upload & Text Input Explanation
Ianyliu 719c44b
Add File Upload & Text Input Explanation (#42)
Ianyliu 1ac7fdf
Bump jinja2 from 3.1.2 to 3.1.3
dependabot[bot] 94f151f
Bump jinja2 from 3.1.2 to 3.1.3 (#44)
Ianyliu 0a1157d
fix entrypoint script
dannyvolders f10f46a
Add Disclaimer and Helpful Tip for Docker Run Command When Path Has S…
Ianyliu 29f865f
Merge branch 'main' of https://github.com/Ianyliu/blast-radius-fork
Ianyliu 5fdf934
Bump jinja2 from 3.1.3 to 3.1.4
dependabot[bot] ba6affc
Bump jinja2 from 3.1.3 to 3.1.4 (#46)
Ianyliu bffe1db
8b8d95d
Bump requests from 2.31.0 to 2.32.0 (#47)
Ianyliu f8af9dc
Bump setuptools from 65.5.1 to 70.0.0
dependabot[bot] e47caed
Bump setuptools from 65.5.1 to 70.0.0 (#49)
Ianyliu 7e7ed33
Add star history pic to README.md
Ianyliu 8d6da2e
Star History Dark Theme Support
Ianyliu 7d031b3
Update README.md
Ianyliu 61374b9
Add star history pic to README.md (#50)
Ianyliu 47f0d72
fix entrypoint script (#53)
Ianyliu 56fd19c
Bug Fix
Ianyliu eccaef9
Bug fix (Terraform initialized in an empty directory) (#54)
Ianyliu 7455703
Update README.md Title
Ianyliu aa6408a
Update README.md Title (#55)
Ianyliu 75ae6be
Add print message
Ianyliu 1e9561e
Add print message (#56)
Ianyliu bdd14d9
Update README.md
Ianyliu 3e0ade2
Update README.md (#58)
Ianyliu e1917ad
Update README.md
Ianyliu 9f271b0
Update README.md (#59)
Ianyliu 8d42879
Allow for host to be configured (default is 0.0.0.0, which may be und…
6194a82
type=str oops
5c6b000
Update readme
9092f19
Make bound host configurable (#60)
Ianyliu fe010e0
Update requirements.txt
Ianyliu f610430
Update requirements.txt (#62)
Ianyliu f4f9e51
Bump setuptools from 70.0.0 to 78.1.1
dependabot[bot] b80bee5
Bump setuptools from 70.0.0 to 78.1.1 (#63)
Ianyliu 1ff00d1
Bump requests from 2.32.0 to 2.32.4
dependabot[bot] 152898e
Bump requests from 2.32.0 to 2.32.4 (#64)
Ianyliu 114f53f
Bump flask from 2.3.2 to 3.1.3
dependabot[bot] cfbcf66
Bump requests from 2.32.4 to 2.33.0
dependabot[bot] 740a778
Bump requests from 2.32.4 to 2.33.0 (#66)
Ianyliu e7378d3
Bump setuptools from 78.1.1 to 83.0.0
dependabot[bot] fc89868
Bump setuptools from 78.1.1 to 83.0.0 (#67)
Ianyliu 3a805d0
Bump flask from 2.3.2 to 3.1.3 (#65)
Ianyliu 8cc2cb1
Update Docker Terraform support to 1.15.8 (#68)
Ianyliu c26f6fe
Fix module-depth graph collapsing
Ianyliu dc8a6a8
Document module-depth behavior
Ianyliu f20f892
Fix --module-depth graph collapsing (#69)
Ianyliu 8e10098
Make diagnostics portable across platforms
Ianyliu ab107cb
Make Windows diagnostics resilient (#70)
Ianyliu cd1f865
Install a cross-platform console launcher
Ianyliu b4bd02c
Test the installed Windows wheel
Ianyliu ec4a802
Install a native Windows console launcher (#71)
Ianyliu b7e3216
Add a structured DOT rendering API
Ianyliu 354604f
Render pasted graphs without a synthetic root
Ianyliu ba33277
Accept modern rootless Terraform DOT input (#72)
Ianyliu 52c0e63
Make graph pruning cycle safe
Ianyliu c4f3e4f
Re-render each tab from its original graph
Ianyliu ae3f000
Document graph pruning workflow
Ianyliu 6e3246e
Prune uploaded and pasted graphs correctly (#73)
Ianyliu 0668cc3
Make Docker Terraform initialization configurable
Ianyliu ff56c45
Document Docker initialization modes
Ianyliu 5741a9e
Make Docker Terraform initialization cache-aware (#74)
Ianyliu 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 |
|---|---|---|
| @@ -1,4 +1,17 @@ | ||
| .* | ||
| AWS/ | ||
| doc | ||
| Dockerfile | ||
| *.md | ||
| !README.md | ||
| *.svg | ||
| *.json | ||
| *.png | ||
| docker-compose.yml | ||
| providers/ | ||
| LICENSE | ||
| examples/ | ||
| example/ | ||
| PowerShell/ | ||
| BASH/ | ||
| Kubernetes/ |
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,72 @@ | ||
| # For most projects, this workflow file will not need changing; you simply need | ||
| # to commit it to your repository. | ||
| # | ||
| # You may wish to alter this file to override the set of languages analyzed, | ||
| # or to provide custom queries or build logic. | ||
| # | ||
| # ******** NOTE ******** | ||
| # We have attempted to detect the languages in your repository. Please check | ||
| # the `language` matrix defined below to confirm you have the correct set of | ||
| # supported CodeQL languages. | ||
| # | ||
| name: "CodeQL" | ||
|
|
||
| on: | ||
| push: | ||
| branches: [ "main" ] | ||
| pull_request: | ||
| # The branches below must be a subset of the branches above | ||
| branches: [ "main" ] | ||
| schedule: | ||
| - cron: '41 11 * * 0' | ||
|
|
||
| jobs: | ||
| analyze: | ||
| name: Analyze | ||
| runs-on: ubuntu-latest | ||
| permissions: | ||
| actions: read | ||
| contents: read | ||
| security-events: write | ||
|
|
||
| strategy: | ||
| fail-fast: false | ||
| matrix: | ||
| language: [ 'javascript', 'python' ] | ||
| # CodeQL supports [ 'cpp', 'csharp', 'go', 'java', 'javascript', 'python', 'ruby' ] | ||
| # Learn more about CodeQL language support at https://aka.ms/codeql-docs/language-support | ||
|
|
||
| steps: | ||
| - name: Checkout repository | ||
| uses: actions/checkout@v3 | ||
|
|
||
| # Initializes the CodeQL tools for scanning. | ||
| - name: Initialize CodeQL | ||
| uses: github/codeql-action/init@v2 | ||
| with: | ||
| languages: ${{ matrix.language }} | ||
| # If you wish to specify custom queries, you can do so here or in a config file. | ||
| # By default, queries listed here will override any specified in a config file. | ||
| # Prefix the list here with "+" to use these queries and those in the config file. | ||
|
|
||
| # Details on CodeQL's query packs refer to : https://docs.github.com/en/code-security/code-scanning/automatically-scanning-your-code-for-vulnerabilities-and-errors/configuring-code-scanning#using-queries-in-ql-packs | ||
| # queries: security-extended,security-and-quality | ||
|
|
||
|
|
||
| # Autobuild attempts to build any compiled languages (C/C++, C#, or Java). | ||
| # If this step fails, then you should remove it and run the build manually (see below) | ||
| - name: Autobuild | ||
| uses: github/codeql-action/autobuild@v2 | ||
|
|
||
| # ℹ️ Command-line programs to run using the OS shell. | ||
| # 📚 See https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#jobsjob_idstepsrun | ||
|
|
||
| # If the Autobuild fails above, remove it and uncomment the following three lines. | ||
| # modify them (or add more) to build your code if your project, please refer to the EXAMPLE below for guidance. | ||
|
|
||
| # - run: | | ||
| # echo "Run, Build Application using script" | ||
| # ./location_of_script_within_repo/buildscript.sh | ||
|
|
||
| - name: Perform CodeQL Analysis | ||
| uses: github/codeql-action/analyze@v2 | ||
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,72 @@ | ||
| # For most projects, this workflow file will not need changing; you simply need | ||
| # to commit it to your repository. | ||
| # | ||
| # You may wish to alter this file to override the set of languages analyzed, | ||
| # or to provide custom queries or build logic. | ||
| # | ||
| # ******** NOTE ******** | ||
| # We have attempted to detect the languages in your repository. Please check | ||
| # the `language` matrix defined below to confirm you have the correct set of | ||
| # supported CodeQL languages. | ||
| # | ||
| name: "CodeQL" | ||
|
|
||
| on: | ||
| push: | ||
| branches: [ "main" ] | ||
| pull_request: | ||
| # The branches below must be a subset of the branches above | ||
| branches: [ "main" ] | ||
| schedule: | ||
| - cron: '38 19 * * 0' | ||
|
|
||
| jobs: | ||
| analyze: | ||
| name: Analyze | ||
| runs-on: ubuntu-latest | ||
| permissions: | ||
| actions: read | ||
| contents: read | ||
| security-events: write | ||
|
|
||
| strategy: | ||
| fail-fast: false | ||
| matrix: | ||
| language: [ 'javascript', 'python' ] | ||
| # CodeQL supports [ 'cpp', 'csharp', 'go', 'java', 'javascript', 'python', 'ruby' ] | ||
| # Learn more about CodeQL language support at https://aka.ms/codeql-docs/language-support | ||
|
|
||
| steps: | ||
| - name: Checkout repository | ||
| uses: actions/checkout@v3 | ||
|
|
||
| # Initializes the CodeQL tools for scanning. | ||
| - name: Initialize CodeQL | ||
| uses: github/codeql-action/init@v2 | ||
| with: | ||
| languages: ${{ matrix.language }} | ||
| # If you wish to specify custom queries, you can do so here or in a config file. | ||
| # By default, queries listed here will override any specified in a config file. | ||
| # Prefix the list here with "+" to use these queries and those in the config file. | ||
|
|
||
| # Details on CodeQL's query packs refer to : https://docs.github.com/en/code-security/code-scanning/automatically-scanning-your-code-for-vulnerabilities-and-errors/configuring-code-scanning#using-queries-in-ql-packs | ||
| # queries: security-extended,security-and-quality | ||
|
|
||
|
|
||
| # Autobuild attempts to build any compiled languages (C/C++, C#, or Java). | ||
| # If this step fails, then you should remove it and run the build manually (see below) | ||
| - name: Autobuild | ||
| uses: github/codeql-action/autobuild@v2 | ||
|
|
||
| # ℹ️ Command-line programs to run using the OS shell. | ||
| # 📚 See https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#jobsjob_idstepsrun | ||
|
|
||
| # If the Autobuild fails above, remove it and uncomment the following three lines. | ||
| # modify them (or add more) to build your code if your project, please refer to the EXAMPLE below for guidance. | ||
|
|
||
| # - run: | | ||
| # echo "Run, Build Application using script" | ||
| # ./location_of_script_within_repo/buildscript.sh | ||
|
|
||
| - name: Perform CodeQL Analysis | ||
| uses: github/codeql-action/analyze@v2 |
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,23 @@ | ||
| # This workflow was added by CodeSee. Learn more at https://codesee.io/ | ||
| # This is v2.0 of this workflow file | ||
| on: | ||
| push: | ||
| branches: | ||
| - main | ||
| pull_request_target: | ||
| types: [opened, synchronize, reopened] | ||
|
|
||
| name: CodeSee | ||
|
|
||
| permissions: read-all | ||
|
|
||
| jobs: | ||
| codesee: | ||
| runs-on: ubuntu-latest | ||
| continue-on-error: true | ||
| name: Analyze the repo with CodeSee | ||
| steps: | ||
| - uses: Codesee-io/codesee-action@v2 | ||
| with: | ||
| codesee-token: ${{ secrets.CODESEE_ARCH_DIAG_API_TOKEN }} | ||
| codesee-url: https://app.codesee.io |
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,20 @@ | ||
| # Dependency Review Action | ||
| # | ||
| # This Action will scan dependency manifest files that change as part of a Pull Request, surfacing known-vulnerable versions of the packages declared or updated in the PR. Once installed, if the workflow run is marked as required, PRs introducing known-vulnerable packages will be blocked from merging. | ||
| # | ||
| # Source repository: https://github.com/actions/dependency-review-action | ||
| # Public documentation: https://docs.github.com/en/code-security/supply-chain-security/understanding-your-software-supply-chain/about-dependency-review#dependency-review-enforcement | ||
| name: 'Dependency Review' | ||
| on: [pull_request] | ||
|
|
||
| permissions: | ||
| contents: read | ||
|
|
||
| jobs: | ||
| dependency-review: | ||
| runs-on: ubuntu-latest | ||
| steps: | ||
| - name: 'Checkout Repository' | ||
| uses: actions/checkout@v3 | ||
| - name: 'Dependency Review' | ||
| uses: actions/dependency-review-action@v2 |
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,109 @@ | ||
| name: Docker Terraform version smoke test | ||
|
|
||
| on: | ||
| push: | ||
| branches: | ||
| - main | ||
| pull_request: | ||
| branches: | ||
| - main | ||
| workflow_dispatch: | ||
|
|
||
| permissions: | ||
| contents: read | ||
|
|
||
| jobs: | ||
| docker-smoke: | ||
| name: ${{ matrix.scenario }} Terraform ${{ matrix.terraform_version }} | ||
| runs-on: ubuntu-latest | ||
| strategy: | ||
| fail-fast: false | ||
| matrix: | ||
| include: | ||
| - scenario: default | ||
| terraform_version: "1.15.8" | ||
| required_version: ">= 1.7.5" | ||
| override_default: false | ||
| - scenario: issue-39-override | ||
| terraform_version: "1.7.5" | ||
| required_version: "= 1.7.5" | ||
| override_default: true | ||
|
|
||
| env: | ||
| IMAGE_TAG: blast-radius-fork:${{ matrix.scenario }} | ||
| EXPECTED_TERRAFORM_VERSION: ${{ matrix.terraform_version }} | ||
| REQUIRED_TERRAFORM_VERSION: ${{ matrix.required_version }} | ||
|
|
||
| steps: | ||
| - name: Check out repository | ||
| uses: actions/checkout@v6 | ||
|
|
||
| - name: Test Terraform initialization policy | ||
| run: python -m unittest tests/test_docker_init.py -v | ||
|
|
||
| - name: Build Docker image | ||
| run: | | ||
| build_args=() | ||
| if [[ "${{ matrix.override_default }}" == "true" ]]; then | ||
| build_args+=(--build-arg "TF_VERSION=${EXPECTED_TERRAFORM_VERSION}") | ||
| fi | ||
|
|
||
| docker build "${build_args[@]}" \ | ||
| --build-arg PYTHON_VERSION=3.10 \ | ||
| -t "${IMAGE_TAG}" \ | ||
| . | ||
|
|
||
| - name: Verify embedded Terraform version | ||
| run: | | ||
| docker run --rm --entrypoint terraform \ | ||
| "${IMAGE_TAG}" version | tee terraform-version.txt | ||
| grep -F "Terraform v${EXPECTED_TERRAFORM_VERSION}" terraform-version.txt | ||
|
|
||
| docker run --rm --entrypoint /bin/sh "${IMAGE_TAG}" \ | ||
| -c 'printf "%s\n" "$BLAST_RADIUS_TERRAFORM_VERSION"' | | ||
| grep -Fx "${EXPECTED_TERRAFORM_VERSION}" | ||
|
|
||
| - name: Create minimal Terraform project | ||
| run: | | ||
| mkdir -p /tmp/blast-radius-tf-smoke | ||
| cat > /tmp/blast-radius-tf-smoke/main.tf <<EOF | ||
| terraform { | ||
| required_version = "${REQUIRED_TERRAFORM_VERSION}" | ||
| } | ||
|
|
||
| resource "terraform_data" "example" { | ||
| input = "blast-radius" | ||
| } | ||
| EOF | ||
|
|
||
| - name: Run Blast Radius container and request graph endpoints | ||
| run: | | ||
| set -euo pipefail | ||
| cleanup() { | ||
| docker logs blast-radius-smoke || true | ||
| docker rm -f blast-radius-smoke || true | ||
| } | ||
| trap cleanup EXIT | ||
|
|
||
| docker run -d \ | ||
| --name blast-radius-smoke \ | ||
| -p 5001:5000 \ | ||
| -v /tmp/blast-radius-tf-smoke:/data:ro \ | ||
| --security-opt apparmor:unconfined \ | ||
| --cap-add=SYS_ADMIN \ | ||
| "${IMAGE_TAG}" | ||
|
|
||
| for i in $(seq 1 30); do | ||
| if curl -fsS http://127.0.0.1:5001/ >/tmp/blast-radius-index.html; then | ||
| break | ||
| fi | ||
| sleep 1 | ||
| done | ||
|
|
||
| curl -fsS http://127.0.0.1:5001/ >/tmp/blast-radius-index.html | ||
| curl -fsS http://127.0.0.1:5001/graph.svg >/tmp/blast-radius-graph.svg | ||
| curl -fsS http://127.0.0.1:5001/graph.json >/tmp/blast-radius-graph.json | ||
|
|
||
| grep "<svg" /tmp/blast-radius-graph.svg | ||
| grep '"nodes"' /tmp/blast-radius-graph.json | ||
| docker logs blast-radius-smoke | grep "Terraform has been successfully initialized" |
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,48 @@ | ||
| name: Windows wheel | ||
|
|
||
| on: | ||
| pull_request: | ||
| push: | ||
| branches: | ||
| - main | ||
|
|
||
| permissions: | ||
| contents: read | ||
|
|
||
| jobs: | ||
| wheel: | ||
| runs-on: windows-latest | ||
| defaults: | ||
| run: | ||
| shell: bash | ||
| steps: | ||
| - uses: actions/checkout@v4 | ||
| - uses: actions/setup-python@v5 | ||
| with: | ||
| python-version: "3.10" | ||
| cache: pip | ||
| - name: Build wheel | ||
| run: | | ||
| python -m pip install --upgrade pip wheel | ||
| python -m pip wheel --wheel-dir wheelhouse . | ||
| - name: Install the built wheel | ||
| run: | | ||
| python -m pip install --force-reinstall wheelhouse/blastradius-*.whl | ||
| - name: Verify the Windows console launcher | ||
| run: | | ||
| blast-radius --help | ||
| python -m unittest discover -s tests -v | ||
| node --test tests/frontend/*.test.js | ||
| - name: Verify serve mode | ||
| run: | | ||
| blast-radius --serve --host 127.0.0.1 --port 5055 . >server.log 2>&1 & | ||
| server_pid=$! | ||
| trap 'kill "$server_pid" 2>/dev/null || true' EXIT | ||
| for attempt in {1..30}; do | ||
| if curl --fail --silent http://127.0.0.1:5055/ >/dev/null; then | ||
| exit 0 | ||
| fi | ||
| sleep 1 | ||
| done | ||
| cat server.log | ||
| exit 1 |
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.
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.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There are two CodeQL workflows (
codeql.ymlandcodeql-analysis.yml) with the samename: "CodeQL"and nearly identical configuration. This will run CodeQL twice on the same events and can be confusing/noisy. Consider deleting one file or consolidating schedules into a single workflow.