MCPcopy Create free account
hub / github.com/1Panel-dev/1Panel / ExportSSHLogs

Method ExportSSHLogs

agent/app/api/v2/ssh.go:214–225  ·  view source on GitHub ↗

@Tags SSH @Summary Export host SSH logs @Accept json @Param request body dto.SearchSSHLog true "request" @Success 200 {string} path @Security ApiKeyAuth @Security Timestamp @Router /hosts/ssh/log/export [post]

(c *gin.Context)

Source from the content-addressed store, hash-verified

212// @Security Timestamp
213// @Router /hosts/ssh/log/export [post]
214func (b *BaseApi) ExportSSHLogs(c *gin.Context) {
215 var req dto.SearchSSHLog
216 if err := helper.CheckBindAndValidate(&req, c); err != nil {
217 return
218 }
219 tmpFile, err := sshService.ExportLog(c, req)
220 if err != nil {
221 helper.InternalServer(c, err)
222 return
223 }
224 helper.SuccessWithData(c, tmpFile)
225}
226
227// @Tags SSH
228// @Summary Load host SSH conf

Callers 1

ExportLogMethod · 0.80

Calls 1

ExportLogMethod · 0.65

Tested by

no test coverage detected