This repository has been archived on 2020-03-24. You can view files and clone it, but cannot push or open issues or pull requests.
quay/config_app/init/certs_create.sh
Sam Chow 69c155ef4f Sets up nginx on image for config app with ssl
Move copying entry scripts to quay-entrypoint
2018-06-13 14:29:11 -04:00

12 lines
455 B
Bash
Executable file

#! /bin/bash
set -e
QUAYPATH=${QUAYPATH:-"."}
QUAYCONF=${QUAYCONF:-"$QUAYPATH/conf"}
cd ${QUAYDIR:-"/"}
echo 'Creating self-signed certs for quay-config app'
# Create certs to secure connections while uploading config for secrets
echo '{"CN":"CA","key":{"algo":"rsa","size":2048}}' | cfssl gencert -initca - | cfssljson -bare quay-config
cp quay-config-key.pem $QUAYDIR/config_app/quay-config.key
cp quay-config.pem $QUAYDIR/config_app/quay-config.cert