Skip to content
This repository was archived by the owner on Jan 22, 2025. It is now read-only.

Commit 20cee26

Browse files
authored
add example docker-compose and k8s files. (#75)
* add example docker-compose and k8s files.
1 parent de27ce6 commit 20cee26

File tree

3 files changed

+78
-0
lines changed

3 files changed

+78
-0
lines changed

docs/deploy_options.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
# Alternate Deploy Options
2+
3+
We include example docker-compose and kubernetes files for deploying the SSH CA:
4+
5+
- [docker-compose-ca.yml.example](./docker-compose-ca.yml.example)
6+
- [sshca.yml.example](./sshca.yml.example)

docs/docker-compose-ca.yml.example

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
# Example docker-compose file for the SSH CA.
2+
version: '3.7'
3+
services:
4+
kbsshca:
5+
image: ca:latest
6+
container_name: kbsshca
7+
# use the corresponding entrypoint script for your purpose
8+
command: ["./docker/entrypoint-generate.sh"]
9+
#command: ["./docker/entrypoint-server.sh"]
10+
environment:
11+
TEAMS: 'list,of,teams'
12+
KEYBASE_USERNAME: 'yourusername'
13+
KEYBASE_PAPERKEY: 'your paper key' # ideally, add this as a docker secret, and not in plaintext here
14+
FORCE_WRITE: 'false'
15+
volumes:
16+
- "./docker/example-keybaseca-volume:/mnt"

docs/sshca.yml.example

Lines changed: 56 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,56 @@
1+
# Example kubernetes file for the SSH CA.
2+
---
3+
apiVersion: v1
4+
kind: PersistentVolumeClaim
5+
metadata:
6+
namespace: sshca
7+
name: kbsshca
8+
spec:
9+
accessModes:
10+
- ReadWriteOnce
11+
resources:
12+
requests:
13+
storage: 1Gi
14+
---
15+
apiVersion: apps/v1
16+
kind: Deployment
17+
metadata:
18+
namespace: sshca
19+
name: kbsshca
20+
labels:
21+
app: kbsshca
22+
spec:
23+
replicas: 1
24+
selector:
25+
matchLabels:
26+
app: kbsshca
27+
template:
28+
metadata:
29+
labels:
30+
app: kbsshca
31+
spec:
32+
containers:
33+
- name: kbsshca
34+
image: yourregistry/ca:latest
35+
command: ["./entrypoint-server.sh"]
36+
env:
37+
- name: TEAMS
38+
value: "list,of,teams"
39+
- name: KEYBASE_USERNAME
40+
value: "yourusername"
41+
- name: KEYBASE_PAPERKEY
42+
value: "your paper key" # ideally, add this as a kubernetes secret, and not in plaintext here
43+
- name: FORCE_WRITE
44+
value: "false"
45+
volumeMounts:
46+
- mountPath: /mnt
47+
name: ssh-data
48+
resources:
49+
limits:
50+
memory: 700Mi
51+
requests:
52+
memory: 300Mi
53+
volumes:
54+
- name: ssh-data
55+
persistentVolumeClaim:
56+
claimName: kbsshca

0 commit comments

Comments
 (0)