Commit Graph

5 Commits

Author SHA1 Message Date
Dave Collins
38203c8f4d
travis: Test go1.13 and drop go1.11. 2019-09-03 15:08:35 -05:00
Dave Collins
5b8450a6e6
multi: Cleanup recent alt DNS names additions.
This cleans up code recently added to support the --altdnsnames flag and
DCRD_ALT_DNSNAMES environment variable to match the project standards,
simplify it, and correct some issues with standalone test binaries.

- Gets rid of the setup func which had several issues:
  - It was creating a file that was not needed (and without even
    checking the error)
  - Since it was parsing flags and missing with os.Args in a func, it
    was not possible to individual run the test funcs without failure
    due to the additional flags
- Performs the flag parsing and removal in an init func that only runs
  once when the tests are run (and before TestMain)
- Avoids creating empty objects when nil will suffice
- Uses full sentences and periods in the comment and properly spaces
  them out so they are consistent with the rest of the code
- Adds comments to all of the added test functions as required by the
  code contribution guidelines
- Closes the create temp files before trying to write to them in the cert
  generation
- Defers the removal of the temp files directly after they are created so
  they are removed properly if the next one fails to create
- Uses consistent camel case in the variable names
2018-10-11 14:16:51 -05:00
Corey Osman
ea54d032df rpcserver: Adds ability to allow alternative dns names for TLS.
- rpcserver: Adds ability to allow alternative dns names for TLS.
- Adds AltDNSNames config for passing additional hostnames to the
  TLS certificate generate method.  Without this change there is no
  way to pass in alternative dns names for the rpc server.
- Additionally this commit allows the user to set 'DCRD_ALT_DNSNAMES'
  as an environment variable when starting dcrd.  This is useful for
  docker and other app runtimes that require apps to be 12 factor.
2018-10-10 23:40:40 -05:00
Dave Collins
3740feb673 database: Replace with new version.
This commit removes the old database package, moves the new package into
its place, and updates all imports accordingly.
2016-08-23 17:40:38 -04:00
Dave Collins
67a1137109 Add automatic RPC configuration. (#287)
This commit is being cherry-picked from upstream btcd and has been
modified to integrate with dcrd by Dave Collins.
2016-07-15 14:09:42 -04:00