SecretSkyDB
Quick start · Google Cloud Marketplace

Up and running in ten minutes.

One click installs SecretSkyDB into your own GKE cluster. Your application connects to it as a normal PostgreSQL server. A column you mark secret is split into three shares before it leaves the proxy, and no share store ever holds the value.

1 clickdeploy from Marketplace, nothing to prepare
0 changesto your SQL, drivers or ORM
3 share storesany two rebuild a value, one alone reveals nothing
Per hourmetered on your Google Cloud bill, no licence key

1Before you start

  • A Google Cloud project with billing enabled, where you have Owner or Editor plus Kubernetes Engine Admin.
  • A GKE cluster (Standard or Autopilot). For a first install, 3 nodes of e2-standard-4 are plenty. You can also create one from the Marketplace form.
  • gcloud, kubectl and psql on the machine you test from. Or none of them, if you use Cloud Shell in step 3.
  • On Ubuntu: install gcloud from Google's apt repository together with google-cloud-cli-gke-gcloud-auth-plugin, not from snap. The snap package has no GKE auth plugin, and kubectl cannot sign in to the cluster without it.

The quick start needs no VPC work, no Private Services Access and no public IP. Everything runs inside your cluster. Marketplace meters SecretSkyDB per proxy-hour while the application is running, so delete it when a test is over.

2Deploy from Marketplace

Open the SecretSkyDB listing in your project and click Configure. Fill the form like this:

FieldValue
Clusteryour GKE cluster, or Create a new cluster
Namespacesecretskydb (choose Create a namespace)
App instance namesecretskydb
Proxy service account, reporting secretleave the defaults
Create the three share stores inside this cluster (quick start)checked
Licence keyempty. Your Marketplace subscription is the licence

Click Deploy. The console opens Kubernetes Engine → Applications → secretskydb. Wait until every component is green: three share stores, the proxy, and a bootstrap job that runs once and completes.

Expected: 3 to 5 minutes on a new cluster, most of it pulling images and creating disks. The application page then shows the connection string and a link to the password.

3Connect

Inside the cluster SecretSkyDB is a PostgreSQL server at secretskydb.secretskydb.svc.cluster.local:55432, database ssdb, user ssdb. For a first look, pick one of two routes.

A. Cloud Shell (recommended)

Open in Cloud Shell ↗. It runs in your browser and already has gcloud, the GKE sign-in plugin, kubectl and psql, so nothing on your own machine matters. Every command in steps 3 to 5 runs with one click.

B. From your own machine

One command checks your tools first, then fetches the cluster credentials, prints the generated password and opens a port-forward. If a tool is missing or unsuitable, it stops and tells you exactly what to install.

# replace CLUSTER and REGION (the cluster's region or zone)
curl -fsSL https://storage.googleapis.com/secretskydb-downloads/connect.sh | bash -s -- CLUSTER REGION

Leave that window open. In a second terminal, with the password it printed:

psql "host=127.0.0.1 port=55432 user=ssdb dbname=ssdb"
Prefer to run the commands yourself?
# replace CLUSTER and REGION
gcloud container clusters get-credentials CLUSTER --region REGION
kubectl -n secretskydb get pods
kubectl -n secretskydb get secret secretskydb-shares -o jsonpath='{.data.proxy}' | base64 -d; echo
kubectl -n secretskydb port-forward svc/secretskydb 55432:55432

The script is short and readable: connect.sh. It installs nothing; the only thing it changes on your machine is the kubectl context.

Production: expose the service through an internal load balancer or Private Service Connect. Never give the proxy a public IP. It holds plaintext in memory while serving your queries.

4Your first secret column

One comment makes a column secret. From then on its values never reach a share store in the clear, and your SQL stays the same.

CREATE TABLE patients (id int PRIMARY KEY, name text, troponin numeric);
COMMENT ON COLUMN patients.troponin IS 'SSDB: secret';
INSERT INTO patients VALUES (1, 'A', 0.43), (2, 'B', 0.08), (3, 'C', 1.20);
SELECT * FROM patients ORDER BY id;
SELECT sum(troponin), count(*) FROM patients WHERE troponin > 0.1;
Expected: the three rows come back whole, the sum is 1.63 and the count is 2. The filter and the sum ran on the share stores, each seeing only its own random-looking share. The first query on a new table may take a few seconds while the shares receive it.

5See what a share store holds

Open one share store directly. Its password is the share-a key of the same Secret:

kubectl -n secretskydb get secret secretskydb-shares -o jsonpath='{.data.share-a}' | base64 -d; echo
kubectl -n secretskydb port-forward svc/secretskydb-share-a 15432:5432
psql "host=127.0.0.1 port=15432 user=postgres dbname=ssdb" -c "SELECT * FROM patients ORDER BY id;"
Expected: id and name in the clear, troponin a number that has nothing to do with 0.43. Repeat with share-b and share-c: two more unrelated numbers. Any two of the three rebuild the value; one alone reveals nothing.

Schema changes are transactional too. This leaves no trace on the proxy or on any share:

BEGIN;
CREATE TABLE t2 (id int, v int);
COMMENT ON COLUMN t2.v IS 'SSDB: secret';
INSERT INTO t2 VALUES (1, 10);
ROLLBACK;
SELECT * FROM t2;   -- relation "t2" does not exist

6Next

Point your application at it

Change the host, port and password in your app's PostgreSQL settings. Nothing else. Mark columns secret with COMMENT ON COLUMN … IS 'SSDB: secret' as you create them.

Production: shares on AlloyDB

The quick start keeps all three share stores in one cluster under one administrator. For production, run scripts/prepare-shares.sh from the deployment assets to place each share on its own AlloyDB instance, then deploy with the quick-start box unchecked.

Clean up a test

Kubernetes Engine → Applications → secretskydb → Delete. Tick delete persistent volumes to remove the share stores' disks. Metering stops when the application is gone.