mirror of
https://github.com/kubeshark/kubeshark.git
synced 2025-08-13 06:08:15 +00:00
Small fixes - permission + har writing exception (#17)
This commit is contained in:
parent
2c5cd39cec
commit
96a6ac3251
@ -18,7 +18,7 @@ import (
|
|||||||
)
|
)
|
||||||
|
|
||||||
func StartReadingFiles(workingDir string) {
|
func StartReadingFiles(workingDir string) {
|
||||||
err := os.MkdirAll(workingDir, 777)
|
err := os.MkdirAll(workingDir, os.ModePerm)
|
||||||
utils.CheckErr(err)
|
utils.CheckErr(err)
|
||||||
|
|
||||||
for true {
|
for true {
|
||||||
|
@ -39,6 +39,10 @@ type HarFile struct {
|
|||||||
}
|
}
|
||||||
|
|
||||||
func (f *HarFile) WriteEntry(request *http.Request, requestTime time.Time, response *http.Response, responseTime time.Time) {
|
func (f *HarFile) WriteEntry(request *http.Request, requestTime time.Time, response *http.Response, responseTime time.Time) {
|
||||||
|
// TODO: quick fix until TRA-3212 is implemented
|
||||||
|
if request.URL == nil || request.Method == "" {
|
||||||
|
return
|
||||||
|
}
|
||||||
harRequest, err := har.NewRequest(request, true)
|
harRequest, err := har.NewRequest(request, true)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
SilentError("convert-request-to-har", "Failed converting request to HAR %s (%v,%+v)\n", err, err, err)
|
SilentError("convert-request-to-har", "Failed converting request to HAR %s (%v,%+v)\n", err, err, err)
|
||||||
|
Loading…
Reference in New Issue
Block a user