This repository has been archived on 2020-08-11. You can view files and clone it, but cannot push or open issues or pull requests.
stack/certificates/ca.sh

8 lines
393 B
Bash
Raw Normal View History

2020-04-02 13:20:50 +00:00
mkdir -p ../.certificates
openssl genrsa -des3 -out ../.certificates/ca.key 4096
openssl req -x509 -new -nodes -key ../.certificates/ca.key -sha256 -days 10000 -subj "/C=GB/ST=Devon/O=SiGyl/OU=SiGyl/CN=CA" -out ../.certificates/ca.crt
mkdir -p ../.ca/$1
cp ../.certificates/ca.crt ../.ca/$1
sudo mkdir -p /etc/docker/certs.d/$1
sudo cp ../.ca/$1/*.* /etc/docker/certs.d/$1