From 6c80805e9877bd32860ac1feed9912b6441b3e36 Mon Sep 17 00:00:00 2001 From: Dave Wasmer Date: Thu, 27 Apr 2017 21:16:14 -0600 Subject: [PATCH] feat: add root CA setup versioning --- src/root-authority.ts | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/root-authority.ts b/src/root-authority.ts index 9ef99d4..a824bfc 100644 --- a/src/root-authority.ts +++ b/src/root-authority.ts @@ -60,6 +60,10 @@ function generateOpenSSLConfFiles() { writeFileSync(opensslConfPath, confTemplate); writeFileSync(configPath('index.txt'), ''); writeFileSync(configPath('serial'), '01'); + // This version number lets us write code in the future that intelligently upgrades an existing + // devcert installation. This "ca-version" is independent of the devcert package version, and + // tracks changes to the root certificate setup only. + writeFileSync(configPath('devcert-ca-version'), '1'); } // macOS is pretty simple - just add the certificate to the system keychain, and most applications