Skip to content

Commit

Permalink
remove a bit of excessive logging
Browse files Browse the repository at this point in the history
  • Loading branch information
aditsachde committed Oct 23, 2024
1 parent f11e598 commit c44eaf3
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 9 deletions.
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -36,4 +36,5 @@ stuff_test.go
devcontainer.json
dependabot.yml
bin/
pkg/
pkg/
fixerupper/
15 changes: 14 additions & 1 deletion fastly.toml
Original file line number Diff line number Diff line change
Expand Up @@ -5,4 +5,17 @@ service_id = "X7QzVa4t0wXcAvoOMoXzA5"

[scripts]
env_vars = ["GOARCH=wasm", "GOOS=wasip1"]
build = "go build -o bin/main.wasm ./cmd/fastly-monitor"
build = "go build -o bin/main.wasm ./cmd/fastly-monitor"

[local_server]
[local_server.config_stores]
[local_server.config_stores.hostmap]
format = "inline-toml"
[local_server.config_stores.hostmap.contents]
"itko-translate-25.edgecompute.app" = "store-ct2025.itko.dev"
"127.0.0.1:7676" = "ct2025.itko.dev"
[local_server.backends]
[local_server.backends."store-ct2025.itko.dev"]
url = "https://store-ct2025.itko.dev"
[local_server.backends."ct2025.itko.dev"]
url = "https://ct2025.itko.dev"
8 changes: 1 addition & 7 deletions internal/ctsubmit/logic.go
Original file line number Diff line number Diff line change
Expand Up @@ -107,13 +107,7 @@ func (d *stageZeroData) stageZero(ctx context.Context, reqBody io.ReadCloser, pr

chain, err := ctfe.ValidateChain(req.Chain, validationOpts)
if err != nil {
var base64Array []string
for _, item := range req.Chain {
encoded := base64.StdEncoding.EncodeToString(item)
base64Array = append(base64Array, encoded)
}

return nil, http.StatusBadRequest, fmt.Errorf("unable to validate chain: %w. Chain: %+v", err, base64Array)
return nil, http.StatusBadRequest, fmt.Errorf("unable to validate chain: %w", err)
}

isPrecert, err := ctfe.IsPrecertificate(chain[0])
Expand Down

0 comments on commit c44eaf3

Please sign in to comment.