Commit Graph
19 Commits
Author SHA1 Message Date
rosstimothy 2cced62805 Fix violations of non-constant format strings linter (#51812)
Depends on https://github.com/gravitational/teleport.e/pull/6006.
Now that we are compliant, the ignore rule was removed from the
golangci-lint config to prevent future regressions.
2025-02-04 16:43:35 +00:00
rosstimothy 95e3d608b7 Migrate lib/events to slog (#46875)
Converts all events backend logging from logrus to slog.
2024-09-30 13:13:47 +00:00
rosstimothy 1aec5414f1 Replace constants from trace with equivalents defined in teleport (#39307)
* Remove logging from circuit breaker

The logging is never output, and if it was would be very verbose.
Instead of dropping the level down to trace the logger is removed
entirely.

* Add constants from trace library

The logging functionality in trace is being removed in an upcoming
release. To prepare the logging component keys are copied from trace
into teleport.

* Convert trace.ComponentFields to teleport.ComponentFields

* Replace trace.Component with teleport.ComponentKey

* Replace trace logging constants
2024-03-14 13:04:29 +00:00
rosstimothy b7318b5c7e Enable errorlint via golangci-lint (#37669)
Adds the new linter and configures it to prevent direct error
comparisions and type assertions in favor of errors.Is and errors.As.
All current violations caught by the linter have been updated
accordingly.
2024-02-02 15:59:24 +00:00
fheinecke b178b8b732 Updated Teleport codebase to AGPL3 license (#35259)
Signed-off-by: Fred Heinecke <[email protected]>
2023-12-01 17:48:14 +00:00
Zac Bergquist 5e31fbea45 GCS: don't swallow cleanup errors (#18670)
This fixes two issues with the GCS session handler.

1. The "pass through" function wasn't actually passing through anything.
   It always ignores errors from the delete call.
2. Prefer path over filepath here, since we always want paths delimited
   by `/`. This isn't a critical issue now, but would result in all
   sorts of failures if we were to try and run Teleport on systems like
   windows where the filepath separator is not `/`.
2022-11-22 22:49:17 +00:00
Jakub Nyckowski 0ee91f6c37 Enable GCI linter (#17894) 2022-10-28 20:20:28 +00:00
rosstimothy c469a34994 Move prometheus collectors from utils to metrics (#15288) 2022-08-09 17:35:19 +00:00
rosstimothy 95d0f0d27f Update google.golang.org/grpc to v1.43.0 (#9656)
Update grpc dependency to the latest version. Needed to fix the client side hang that
prevents TwoClustersTunnel from running succesfully, see #9655.
2022-01-10 15:36:50 -05:00
rosstimothy 8f783cf952 use aws sdk withcontext variants where possible (#8355)
use aws api withcontext variants where possible
2021-10-06 15:27:13 -04:00
NajiObeid 86a6abcfcb lazy init of prometheus collectors (#6561)
* lazy init of prometheus collectors

* incorporate metrics intorduced in #6271

* linting

* tests

* pr changes

* tests

* pr changes
2021-05-19 11:53:36 -04:00
Sasha Klizhentas d160507430 Session streaming
This commit introduces GRPC API for streaming sessions.

It adds structured events and sync streaming
that avoids storing events on disk.

You can find design in rfd/0002-streaming.md RFD.
2020-09-28 23:08:56 -07:00
Andrew Lytvynov 675cce20c3 s3sessions,gcssessions: don't fail when ensureBucket fails
When S3/GCS credentials given to teleport have write-only access,
fetching the bucket attributes will fail. This shouldn't prevent
Teleport from starting and uploading sessions.
Print a helpful error message instead.
2020-06-11 00:03:22 +00:00
Andrew Lytvynov 460c434eb7 gcssessions: don't overwrite sessions and protect auto-created buckets
- before uploading a session, check that it doesn't already exist; we
  don't want to lose an existing session
- when auto-creating a missing bucket at startup, set predefined ACLs to
  `projectPrivate`, which means "Project team members get access
  according to their roles." See
  https://cloud.google.com/storage/docs/json_api/v1/buckets/insert#parameters
2020-05-27 18:37:34 +00:00
Andrew Lytvynov 552d3e623c Cleanup of GCP backend implementation
- close all io.Closers where missing
- add error handling where missing
- improve error messages
2020-05-27 18:37:34 +00:00
Andrew Lytvynov a48c40ad78 gosimple: replace time.Now().Sub(x) with time.Since(x) 2020-05-15 16:32:45 +00:00
Andrew Lytvynov f8661edea3 Clean up dead code across the codebase
Spring cleaning!
A very mechanical cleanup using several linters (unused, deadcode,
structcheck). Build and tests still pass so no behavior should be
affected.
2020-04-09 21:10:12 +00:00
Sasha Klizhentas 408ee26083 Fix context leaks 2019-09-24 11:39:44 -07:00
Joshua Durbin d346f2b124 adds support for GCP HA environments with gcs recording storage, firestore-backed events, and firestore backend storage 2019-09-05 13:09:55 -07:00