github.com/qiuhoude/go-web@v0.0.0-20220223060959-ab545e78f20d/prepare/23_proto_actor/remotessl/Makefile (about)

     1  all: nodes
     2  
     3  clean:
     4  	@rm -f cert/localhost.key
     5  	@rm -f cert/localhost.crt
     6  	@rm -f node1
     7  	@rm -f node2
     8  
     9  ssl:
    10  	@openssl req \
    11  		-config cert/localhost.conf \
    12  		-new \
    13  		-newkey rsa:4096 \
    14  		-days 365 \
    15  		-nodes \
    16  		-x509 \
    17  		-subj "/C=US/ST=California/L=SanFrancisco/O=Dis/CN=localhost" \
    18  		-keyout cert/localhost.key \
    19  		-out cert/localhost.crt
    20  
    21  nodes:
    22  	go build -o node1 nodes/node1/main.go
    23  	go build -o node2 nodes/node2/main.go
    24  
    25  .PHONY: clean ssl nodes