bridgepreflight 1.0.0 → 1.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +7 -0
- package/README.md +189 -65
- package/package.json +8 -3
package/LICENSE
ADDED
package/README.md
CHANGED
|
@@ -6,118 +6,242 @@
|
|
|
6
6
|
<!------------------------------ ------------------------------------>
|
|
7
7
|
BridgePreflight
|
|
8
8
|
|
|
9
|
-
|
|
9
|
+
The Deployment Risk Intelligence Platform
|
|
10
10
|
|
|
11
|
-
BridgePreflight analyzes your
|
|
11
|
+
BridgePreflight is a production-readiness scanner that analyzes your codebase before deployment and generates a structured Deployment Risk Score.
|
|
12
12
|
<!------------------------------ ------------------------------------>
|
|
13
13
|
|
|
14
14
|
|
|
15
15
|
<!------------------------------ ------------------------------------>
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
•
|
|
19
|
-
•
|
|
20
|
-
•
|
|
21
|
-
•
|
|
16
|
+
It identifies critical infrastructure weakness such as:
|
|
17
|
+
• Broken or missing builds
|
|
18
|
+
• Unsafe environment variable usage
|
|
19
|
+
• Runtime incompatibility risks
|
|
20
|
+
• Localhost leakage
|
|
21
|
+
• Missing lockfiles or Node version enforcement
|
|
22
22
|
Issues are discovered too late — during staging or production.
|
|
23
23
|
|
|
24
|
-
BridgePreflight
|
|
24
|
+
BridgePreflight runs locally or in CI to prevent high-risk deployments before they happen.
|
|
25
25
|
<!------------------------------ ------------------------------------>
|
|
26
26
|
|
|
27
27
|
|
|
28
28
|
|
|
29
29
|
<!------------------------------ ------------------------------------>
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
•
|
|
35
|
-
•
|
|
36
|
-
•
|
|
37
|
-
|
|
38
|
-
|
|
30
|
+
The Problem
|
|
31
|
+
Modern teams ship fast.
|
|
32
|
+
|
|
33
|
+
But deployments often fail because:
|
|
34
|
+
• Runtime versions are inconsistent
|
|
35
|
+
• Enviroment variables are misconfigured
|
|
36
|
+
• Builds silently pass with warnings
|
|
37
|
+
• Localhost endpoints leak into production
|
|
38
|
+
• Dependency locking is missing
|
|
39
|
+
These issues are rarely caught early.
|
|
39
40
|
|
|
41
|
+
They surface in staging - or worse - in production
|
|
42
|
+
<!------------------------------ ------------------------------------>
|
|
40
43
|
|
|
41
44
|
|
|
42
45
|
<!------------------------------ ------------------------------------>
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
• Test presence and structure
|
|
46
|
-
• Build configuration
|
|
47
|
-
• CI workflow setup
|
|
48
|
-
• Documentation presence
|
|
49
|
-
• Repository hygiene
|
|
50
|
-
Each category contributes weighted points to the final score.
|
|
46
|
+
The Solution
|
|
47
|
+
Bridgepreflight introduces Deployment Risk Intelligence directly into your development workflow.
|
|
51
48
|
|
|
52
|
-
|
|
53
|
-
•
|
|
54
|
-
•
|
|
55
|
-
•
|
|
49
|
+
instead of guessing whether a repository is safe to deploy, you get:
|
|
50
|
+
• A quantified Deployment Risk Sore
|
|
51
|
+
• Structured analyzer breakdown
|
|
52
|
+
• Severity classification (Healthy/ Low/ Medium/ High/ Critical)
|
|
53
|
+
• Clear remediation signals
|
|
54
|
+
You move from reactive debugging to proactive risk prevention.
|
|
56
55
|
<!------------------------------ ------------------------------------>
|
|
57
56
|
|
|
58
57
|
|
|
59
58
|
<!------------------------------ ------------------------------------>
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
npm run build
|
|
63
|
-
node dist/cli.js scan
|
|
59
|
+
What BridgePreflight Analyzes (v1.0.0)
|
|
60
|
+
Current analyzers include:
|
|
64
61
|
|
|
62
|
+
1. Build Check
|
|
63
|
+
• Verifies package.json
|
|
64
|
+
• Ensures build script exists
|
|
65
|
+
• Detects TypeScript without proper build configuration
|
|
66
|
+
• Captures build-time warnings
|
|
65
67
|
|
|
66
|
-
|
|
67
|
-
|
|
68
|
+
2. Environment Variables Check
|
|
69
|
+
• Detects unsafe process.env usage
|
|
70
|
+
• Flags missing configuration hygiene
|
|
71
|
+
• Identifies potential production misconfiguration risks
|
|
72
|
+
|
|
73
|
+
3. Runtime Compatibility Check
|
|
74
|
+
• Verifies Node engine specification
|
|
75
|
+
• Detects missing .nvmrc or .node-version
|
|
76
|
+
• Ensures lockfile presence
|
|
77
|
+
|
|
78
|
+
4. Localhost Leak Check
|
|
79
|
+
• Scans for localhost and 127.0.0.1 usage
|
|
80
|
+
• Prevents accidental production endpoint leakage
|
|
68
81
|
<!------------------------------ ------------------------------------>
|
|
69
82
|
|
|
70
83
|
|
|
84
|
+
|
|
71
85
|
<!------------------------------ ------------------------------------>
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
86
|
+
Installation
|
|
87
|
+
|
|
88
|
+
Global Installation (Recommended)
|
|
89
|
+
• npm install -g bridgepreflight
|
|
75
90
|
|
|
91
|
+
Run:
|
|
92
|
+
• bridgepreflight scan
|
|
76
93
|
|
|
77
|
-
|
|
78
|
-
•
|
|
79
|
-
• Run on every pull request
|
|
80
|
-
• Automatically fail if readiness < 70
|
|
81
|
-
• Comment with risk breakdown
|
|
94
|
+
Or without global install:
|
|
95
|
+
• npx bridgepreflight scan
|
|
82
96
|
<!------------------------------ ------------------------------------>
|
|
83
97
|
|
|
84
98
|
|
|
85
99
|
<!------------------------------ ------------------------------------>
|
|
86
100
|
Example Output
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
101
|
+
Running BridgePreflight scan...
|
|
102
|
+
|
|
103
|
+
✅ Build Check: HEALTHY (50/50)
|
|
104
|
+
❌ Environment Variables Check: HIGH (10/30)
|
|
105
|
+
⚠ Localhost Leak Check: LOW (16/20)
|
|
106
|
+
❌ Runtime Compatibility Check: HIGH (6/20)
|
|
107
|
+
|
|
108
|
+
-----------------------------
|
|
109
|
+
Total Score: 79/120 (65.8%)
|
|
110
|
+
Readiness: High Risk
|
|
111
|
+
-----------------------------
|
|
112
|
+
|
|
113
|
+
Top Risk Factors:
|
|
114
|
+
• Environment Variables Check
|
|
115
|
+
• Runtime Compatibility Check
|
|
116
|
+
<!------------------------------ ------------------------------------>
|
|
117
|
+
|
|
118
|
+
|
|
119
|
+
<!------------------------------ ------------------------------------>
|
|
120
|
+
JSON Output
|
|
121
|
+
For machine-readable output:
|
|
122
|
+
|
|
123
|
+
bridgepreflight scan --json
|
|
124
|
+
|
|
125
|
+
This enables CI integration and automated risk gating.
|
|
95
126
|
<!------------------------------ ------------------------------------>
|
|
96
127
|
|
|
97
128
|
|
|
98
129
|
<!------------------------------ ------------------------------------>
|
|
99
|
-
|
|
100
|
-
BridgePreflight
|
|
130
|
+
Scoring Model
|
|
131
|
+
BridgePreflight uses a weighted scoring model.
|
|
132
|
+
|
|
133
|
+
Each analyzer contributes to a maximum composite score (currently 120 points).
|
|
101
134
|
|
|
102
|
-
|
|
103
|
-
•
|
|
104
|
-
•
|
|
105
|
-
•
|
|
106
|
-
|
|
135
|
+
Severity is calculated proportionally:
|
|
136
|
+
• Healthy
|
|
137
|
+
• Low
|
|
138
|
+
• Medium
|
|
139
|
+
• High
|
|
140
|
+
• Critical
|
|
141
|
+
|
|
142
|
+
The scoring model is deterministic and transparent.
|
|
143
|
+
<!------------------------------ ------------------------------------>
|
|
144
|
+
|
|
145
|
+
|
|
146
|
+
<!------------------------------ ------------------------------------>
|
|
147
|
+
CI Integration (Coming Next Phase)
|
|
148
|
+
BridgePreflight is designed to be CI-ready.
|
|
149
|
+
|
|
150
|
+
Upcoming native integrations:
|
|
151
|
+
• Pull request gating
|
|
152
|
+
• GitHub Actions workflow templates
|
|
153
|
+
• Exit-code enforcement
|
|
154
|
+
• Team policy thresholds
|
|
107
155
|
<!------------------------------ ------------------------------------>
|
|
108
156
|
|
|
109
157
|
|
|
110
158
|
<!------------------------------ ------------------------------------>
|
|
111
159
|
Roadmap
|
|
160
|
+
BridgePreflight is evolving into a full Deployment Risk Intelligence Platform.
|
|
161
|
+
|
|
162
|
+
Phase 1 (Current)
|
|
163
|
+
• Local CLI scanning
|
|
164
|
+
• Weighted risk scoring
|
|
165
|
+
• Deterministic analyzer engine
|
|
166
|
+
|
|
167
|
+
Phase 2
|
|
112
168
|
• Configurable scoring weights
|
|
113
|
-
• Plugin-based analyzer
|
|
114
|
-
•
|
|
115
|
-
|
|
116
|
-
|
|
169
|
+
• Plugin-based analyzer architecture
|
|
170
|
+
• CI enforcement modes (--strict, --ci)
|
|
171
|
+
|
|
172
|
+
Phase 3
|
|
173
|
+
• Historical risk tracking
|
|
174
|
+
• GitHub integration
|
|
175
|
+
• PR blocking with threshold enforcement
|
|
176
|
+
|
|
177
|
+
Phase 4
|
|
178
|
+
• Cloud dashboard
|
|
179
|
+
• Team-level risk insights
|
|
180
|
+
• Policy enforcement
|
|
181
|
+
• Enterprise compliance modules
|
|
182
|
+
<!------------------------------ ------------------------------------>
|
|
183
|
+
|
|
184
|
+
|
|
185
|
+
|
|
186
|
+
<!------------------------------ ------------------------------------>
|
|
187
|
+
Contributing
|
|
188
|
+
BridgePreflight is currently in early-stage evolution.
|
|
189
|
+
|
|
190
|
+
Contributions are welcome in the following areas:
|
|
191
|
+
|
|
192
|
+
• Analyzer improvements
|
|
193
|
+
• Performance optimization
|
|
194
|
+
• Additional infrastructure checks
|
|
195
|
+
• Documentation refinement
|
|
196
|
+
• CI templates
|
|
197
|
+
|
|
198
|
+
To contribute:
|
|
199
|
+
1. Fork the repository
|
|
200
|
+
2. Create a feature branch
|
|
201
|
+
3.Submit a pull request with clear reasoning
|
|
202
|
+
|
|
203
|
+
All contributions should preserve deterministic scoring logic and architecture stability.
|
|
204
|
+
<!------------------------------ ------------------------------------>
|
|
205
|
+
|
|
206
|
+
|
|
207
|
+
|
|
208
|
+
<!------------------------------ ------------------------------------>
|
|
209
|
+
Versioning
|
|
210
|
+
BridgePreflight follows semantic versioning:
|
|
211
|
+
|
|
212
|
+
MAJOR.MINOR.PATCH
|
|
213
|
+
|
|
214
|
+
• MAJOR - Breaking changes
|
|
215
|
+
• MINOR - New analyzers or features
|
|
216
|
+
• PATCH - Bug fixes and improvements
|
|
217
|
+
|
|
218
|
+
GitHub releases are tagged accordingly
|
|
219
|
+
• git tag v1.0.0
|
|
220
|
+
• git push --tags
|
|
221
|
+
|
|
222
|
+
This aligns repository versions with npm releases.
|
|
223
|
+
<!------------------------------ ------------------------------------>
|
|
224
|
+
|
|
225
|
+
|
|
226
|
+
|
|
117
227
|
<!------------------------------ ------------------------------------>
|
|
228
|
+
License
|
|
229
|
+
MIT License
|
|
118
230
|
|
|
231
|
+
Bridgepreflight is open-core infrastructure software.
|
|
119
232
|
|
|
233
|
+
Future cloud components may be distributed under seperate licensing.
|
|
120
234
|
<!------------------------------ ------------------------------------>
|
|
121
|
-
|
|
122
|
-
|
|
235
|
+
|
|
236
|
+
|
|
237
|
+
|
|
238
|
+
<!------------------------------ ------------------------------------>
|
|
239
|
+
Vision
|
|
240
|
+
BridgePreflight is not just a CLI tool.
|
|
241
|
+
|
|
242
|
+
It is the foundation of a Deployment Risk Intelligence Platform — designed to help teams measure, manage, and reduce infrastructure risk before code reaches production.
|
|
243
|
+
|
|
244
|
+
Infrastructure reliability should be measurable.
|
|
245
|
+
|
|
246
|
+
BridgePreflight makes it measurable.
|
|
123
247
|
<!------------------------------ ------------------------------------>
|
package/package.json
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "bridgepreflight",
|
|
3
|
-
"version": "1.0.
|
|
4
|
-
"description": "
|
|
3
|
+
"version": "1.0.1",
|
|
4
|
+
"description": "Deployment Risk Intelligence CLI for Node.js projects. Detect build, runtime, and configuration risks before production.",
|
|
5
5
|
"bin": {
|
|
6
|
-
"bridgepreflight": "
|
|
6
|
+
"bridgepreflight": "dist/cli.js"
|
|
7
7
|
},
|
|
8
8
|
"files": [
|
|
9
9
|
"dist"
|
|
@@ -15,6 +15,11 @@
|
|
|
15
15
|
},
|
|
16
16
|
"keywords": [
|
|
17
17
|
"devtools",
|
|
18
|
+
"risk",
|
|
19
|
+
"infrastructure",
|
|
20
|
+
"nodejs",
|
|
21
|
+
"preflight",
|
|
22
|
+
"runtime",
|
|
18
23
|
"ci",
|
|
19
24
|
"production",
|
|
20
25
|
"deployment",
|