Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update cert generation Makefile to include configurable cert file names #12766

Merged
merged 1 commit into from
Mar 30, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 6 additions & 6 deletions hack/tls-setup/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -19,32 +19,32 @@ req:
-ca certs/ca.pem \
-ca-key certs/ca-key.pem \
-config config/ca-config.json \
config/req-csr.json | $(JSON) -bare certs/9.145.89.120
config/req-csr.json | $(JSON) -bare certs/${infra0}
$(CFSSL) gencert \
-ca certs/ca.pem \
-ca-key certs/ca-key.pem \
-config config/ca-config.json \
config/req-csr.json | $(JSON) -bare certs/9.145.89.173
config/req-csr.json | $(JSON) -bare certs/${infra1}
$(CFSSL) gencert \
-ca certs/ca.pem \
-ca-key certs/ca-key.pem \
-config config/ca-config.json \
config/req-csr.json | $(JSON) -bare certs/9.145.89.225
config/req-csr.json | $(JSON) -bare certs/${infra2}
$(CFSSL) gencert \
-ca certs/ca.pem \
-ca-key certs/ca-key.pem \
-config config/ca-config.json \
config/req-csr.json | $(JSON) -bare certs/peer-9.145.89.120
config/req-csr.json | $(JSON) -bare certs/peer-${infra0}
$(CFSSL) gencert \
-ca certs/ca.pem \
-ca-key certs/ca-key.pem \
-config config/ca-config.json \
config/req-csr.json | $(JSON) -bare certs/peer-9.145.89.173
config/req-csr.json | $(JSON) -bare certs/peer-${infra1}
$(CFSSL) gencert \
-ca certs/ca.pem \
-ca-key certs/ca-key.pem \
-config config/ca-config.json \
config/req-csr.json | $(JSON) -bare certs/peer-9.145.89.225
config/req-csr.json | $(JSON) -bare certs/peer-${infra2}

clean:
rm -rf certs
Expand Down
8 changes: 7 additions & 1 deletion hack/tls-setup/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,4 +28,10 @@ Example:
]
}
```
3. Run `make` to generate the certs
3. Set the following environment variables subsituting your IP address:
```bash
export infra0={IP-0}
export infra1={IP-1}
export infra2={IP-2}
```
4. Run `make` to generate the certs