change -exportTofuBundle to -exportServerBundle
This commit is contained in:
parent
206b5782ae
commit
44da3fd95f
|
@ -8,7 +8,7 @@
|
||||||
|
|
||||||
The app takes the following arguments
|
The app takes the following arguments
|
||||||
- -debug: enabled debug logging
|
- -debug: enabled debug logging
|
||||||
- -exportTofuBundle: Export the tofubundle to a file called tofubundle
|
- -exportServerBundle: Export the server bundle to a file called serverbundle
|
||||||
|
|
||||||
|
|
||||||
The app takes the following environment variables
|
The app takes the following environment variables
|
||||||
|
|
|
@ -19,7 +19,7 @@ import (
|
||||||
|
|
||||||
func main() {
|
func main() {
|
||||||
flagDebug := flag.Bool("debug", false, "Enable debug logging")
|
flagDebug := flag.Bool("debug", false, "Enable debug logging")
|
||||||
flagExportTofu := flag.Bool("exportTofuBundle", false, "Export the tofubundle to a file called tofubundle")
|
flagExportServer := flag.Bool("exportServerBundle", false, "Export the server bundle to a file called serverbundle")
|
||||||
flag.Parse()
|
flag.Parse()
|
||||||
|
|
||||||
log.AddEverythingFromPattern("server/app/main")
|
log.AddEverythingFromPattern("server/app/main")
|
||||||
|
@ -85,9 +85,9 @@ func main() {
|
||||||
|
|
||||||
log.Infof("Server bundle (import into client to use server): %s\n", log.Magenta(server.ServerBundle()))
|
log.Infof("Server bundle (import into client to use server): %s\n", log.Magenta(server.ServerBundle()))
|
||||||
|
|
||||||
if *flagExportTofu {
|
if *flagExportServer {
|
||||||
// Todo: change all to server export
|
// Todo: change all to server export
|
||||||
ioutil.WriteFile(path.Join(serverConfig.ConfigDir, "tofubundle"), []byte(server.TofuBundle()), 0600)
|
ioutil.WriteFile(path.Join(serverConfig.ConfigDir, "serverbundle"), []byte(server.TofuBundle()), 0600)
|
||||||
}
|
}
|
||||||
|
|
||||||
// Graceful Shutdown
|
// Graceful Shutdown
|
||||||
|
|
|
@ -64,5 +64,5 @@ COPY ./docker/docker-entrypoint /usr/local/bin/
|
||||||
VOLUME /etc/tor /var/lib/tor /var/lib/cwtch
|
VOLUME /etc/tor /var/lib/tor /var/lib/cwtch
|
||||||
|
|
||||||
ENTRYPOINT ["docker-entrypoint"]
|
ENTRYPOINT ["docker-entrypoint"]
|
||||||
CMD ["/usr/local/bin/cwtch","--exportTofuBundle"]
|
CMD ["/usr/local/bin/cwtch","--exportServerBundle"]
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue