-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #17 from ova777/master
Added the db command
- Loading branch information
Showing
5 changed files
with
37 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
// Copyright 1999-2023. Plesk International GmbH. | ||
|
||
package cmd | ||
|
||
import ( | ||
"github.com/plesk/pleskapp/plesk/internal/actions" | ||
"github.com/plesk/pleskapp/plesk/internal/config" | ||
"github.com/plesk/pleskapp/plesk/internal/locales" | ||
"github.com/spf13/cobra" | ||
) | ||
|
||
var dbCmd = &cobra.Command{ | ||
Use: "db [SERVER]", | ||
Short: locales.L.Get("server.db.description"), | ||
RunE: func(cmd *cobra.Command, args []string) error { | ||
server, err := config.GetServerByArgs(args) | ||
if err != nil { | ||
return err | ||
} | ||
|
||
return actions.ServerSSH(*server, "plesk db", true) | ||
}, | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters