File tree 2 files changed +26
-0
lines changed
wechaty-puppet-service/IO/Github/Wechaty/PuppetService
2 files changed +26
-0
lines changed Original file line number Diff line number Diff line change @@ -61,6 +61,29 @@ docker run -ti --volume="$(pwd)":/bot --rm phpwechaty/php-wechaty:v1 docker/ding
61
61
62
62
> Learn more about Wechaty Docker at [ Wiki: Docker ] ( https://github.com/Wechaty/php-wechaty/wiki/Docker ) .
63
63
64
+ #### New environment variables
65
+
66
+ <!-- markdownlint-disable MD013 -->
67
+
68
+ 1 . ` WECHATY_PUPPET_SERVICE_TLS_CA_CERT ` : can be overwrite by ` options.tlsRootCert ` . Set Root CA Cert to verify the server or client.
69
+
70
+ For Puppet Server:
71
+
72
+ | Environment Variable | Options | Description |
73
+ | -------------------- | ------- | ----------- |
74
+ | ` WECHATY_PUPPET_SERVICE_TLS_SERVER_CERT ` | ` options.tls.serverCert ` | Server CA Cert (string data) |
75
+ | ` WECHATY_PUPPET_SERVICE_TLS_SERVER_KEY ` | ` options.tls.serverKey ` | Server CA Key (string data) |
76
+ | ` WECHATY_PUPPET_SERVICE_NO_TLS_INSECURE_SERVER ` | ` options.tls.disable ` | Set ` true ` to disable server TLS |
77
+
78
+ For Puppet Client:
79
+
80
+ | Environment Variable | Options | Description |
81
+ | -------------------- | ------- | ----------- |
82
+ | ` WECHATY_PUPPET_SERVICE_AUTHORITY ` | ` options.authority ` | Service discovery host, default: ` api.chatie.io ` |
83
+ | ` WECHATY_PUPPET_SERVICE_TLS_CA_CERT ` | ` options.caCert ` | Certification Authority Root Cert, default is using Wechaty Community root cert |
84
+ | ` WECHATY_PUPPET_SERVICE_TLS_SERVER_NAME ` | ` options.serverName ` | Server Name (mast match for SNI) |
85
+ | ` WECHATY_PUPPET_SERVICE_NO_TLS_INSECURE_CLIENT ` | ` options.tls.disable ` | Set ` true ` to disable client TLS |
86
+
64
87
## The World's Shortest PHP ChatBot: 8 lines of Code
65
88
66
89
### php
Original file line number Diff line number Diff line change @@ -792,6 +792,9 @@ function ($metadata,
792
792
return $ metadataCopy ;
793
793
};
794
794
Logger::DEBUG ($ updateMetadata );
795
+ // WECHATY_PUPPET_SERVICE_NO_TLS_INSECURE_CLIENT
796
+ // WECHATY_PUPPET_SERVICE_TLS_CA_CERT
797
+ // WECHATY_PUPPET_SERVICE_TLS_SERVER_NAME
795
798
$ this ->_grpcClient = new \Wechaty \PuppetClient ($ hostname , [
796
799
'credentials ' => \Grpc \ChannelCredentials::createInsecure (),
797
800
'update_metadata ' => $ updateMetadata ,
You can’t perform that action at this time.
0 commit comments