diff --git a/client/client.go b/client/client.go index 7fb722c1..5fe61008 100644 --- a/client/client.go +++ b/client/client.go @@ -69,15 +69,15 @@ func (c *Client) SetSSLVerification(verify bool) { // public-private key-pair. It outputs configuration information // for the user. func (c *Client) BootstrapRemote(repoName string) error { - fmt.Fprintf(c.out, "Setting up remote %s at %s\n", c.Name, c.IP) + fmt.Fprintf(c.out, "Setting up remote %s at %s", c.Name, c.IP) - fmt.Fprintln(c.out, ">> Step 1/4: Installing docker...") + fmt.Fprint(c.out, ">> Step 1/4: Installing docker...") err := c.installDocker(c.sshRunner) if err != nil { return err } - fmt.Fprintln(c.out, "\n>> Step 2/4: Building deploy key...") + fmt.Fprint(c.out, "\n>> Step 2/4: Building deploy key...") if err != nil { return err } @@ -88,7 +88,7 @@ func (c *Client) BootstrapRemote(repoName string) error { // This step needs to run before any other commands that rely on // the daemon image, since the daemon is loaded here. - fmt.Fprintln(c.out, "\n>> Step 3/4: Starting daemon...") + fmt.Fprint(c.out, "\n>> Step 3/4: Starting daemon...") if err != nil { return err } @@ -97,32 +97,32 @@ func (c *Client) BootstrapRemote(repoName string) error { return err } - fmt.Fprintln(c.out, "\n>> Step 4/4: Fetching daemon API token...") + fmt.Fprint(c.out, "\n>> Step 4/4: Fetching daemon API token...") token, err := c.getDaemonAPIToken(c.sshRunner, c.version) if err != nil { return err } c.Daemon.Token = token - fmt.Fprintln(c.out, "\nInertia has been set up and daemon is running on remote!") - fmt.Fprintln(c.out, "You may have to wait briefly for Inertia to set up some dependencies.") + fmt.Fprint(c.out, "\nInertia has been set up and daemon is running on remote!") + fmt.Fprint(c.out, "You may have to wait briefly for Inertia to set up some dependencies.") fmt.Fprintf(c.out, "Use 'inertia %s logs --stream' to check on the daemon's setup progress.\n\n", c.Name) fmt.Fprint(c.out, "=============================\n") // Output deploy key to user. - fmt.Fprintf(c.out, ">> GitHub Deploy Key (add to https://www.github.com/%s/settings/keys/new):\n", repoName) + fmt.Fprintf(c.out, ">> GitHub Deploy Key (add to https://www.github.com/%s/settings/keys/new): ", repoName) fmt.Fprint(c.out, pub.String()) // Output Webhook url to user. - fmt.Fprintf(c.out, ">> GitHub WebHook URL (add to https://www.github.com/%s/settings/hooks/new):\n", repoName) - fmt.Fprintf(c.out, "WebHook Address: https://%s:%s/webhook\n", c.IP, c.Daemon.Port) - fmt.Fprintln(c.out, "WebHook Secret: "+c.Daemon.WebHookSecret) + fmt.Fprintf(c.out, ">> GitHub WebHook URL (add to https://www.github.com/%s/settings/hooks/new): ", repoName) + fmt.Fprintf(c.out, "WebHook Address: https://%s:%s/webhook", c.IP, c.Daemon.Port) + fmt.Fprint(c.out, "WebHook Secret: "+c.Daemon.WebHookSecret) fmt.Fprint(c.out, `Note that you will have to disable SSH verification in your webhook settings - Inertia uses self-signed certificates that GitHub won't be able to verify.`+"\n") - fmt.Fprintln(c.out, `Inertia daemon successfully deployed! Add your webhook url and deploy + fmt.Fprint(c.out, `Inertia daemon successfully deployed! Add your webhook url and deploy key to enable continuous deployment.`) fmt.Fprintf(c.out, "Then run 'inertia %s up' to deploy your application.\n", c.Name) diff --git a/daemon/inertiad/auth/permissions.go b/daemon/inertiad/auth/permissions.go index 36eed0a8..2c1f497e 100644 --- a/daemon/inertiad/auth/permissions.go +++ b/daemon/inertiad/auth/permissions.go @@ -254,7 +254,7 @@ func (h *PermissionsHandler) listUsersHandler(w http.ResponseWriter, r *http.Req if len(users) != 0 { fmt.Fprintf(w, "[SUCCESS %d] Users: \n%s\n", http.StatusOK, userList) } else { - fmt.Fprintf(w, "[SUCCESS %d] No users registered.\n", http.StatusOK) + fmt.Fprintf(w, "[SUCCESS %d] No users registered.", http.StatusOK) } } diff --git a/provision/ec2.go b/provision/ec2.go index 7e40a17c..3c188c83 100644 --- a/provision/ec2.go +++ b/provision/ec2.go @@ -210,7 +210,7 @@ func (p *EC2Provisioner) CreateInstance(opts EC2CreateInstanceOptions) (*cfg.Rem }, }) if err != nil { - fmt.Fprintf(p.out, "Failed to set tags: %s\n", err.Error()) + fmt.Fprintf(p.out, "Failed to set tags: %s", err.Error()) } // Poll for SSH port to open