* Reverting PR 1650
https://github.com/gomods/athens/pull/1650 was a big change to the
authentication/authorization code, which we have decided to pull
out and potentially move into a separate process/project
Signed-off-by: Aaron Schlesinger <aaron@ecomaz.net>
* removing commented, unused code
Signed-off-by: Aaron Schlesinger <aaron@ecomaz.net>
* removing more commented, unused code
Signed-off-by: Aaron Schlesinger <aaron@ecomaz.net>
* removing more unused code
Signed-off-by: Aaron Schlesinger <aaron@ecomaz.net>
* cmd/proxy/actions: pass NoSumPatterns to GoGetFetcher
* add gosum unit tests
* upgrade appveyor to 1.13
* fix test typo
* check appveyor version
* AppVeyor has no 1.13
* use logger
* pkg/module: include SSH_AUTH_SOCK in go get env
When running locally, it's convenient to use a user's ssh-agent. For
that to work, we need to propagate SSH_AUTH_SOCK.
* pkg/module: Verify existence for SSH_AUTH_SOCK
SSH_AUTH_SOCK is expected to indicate a unix socket on the local
filesystem. If it isn't a unix socket (after symlink resolution) we can
ignore it. (although ssh will ignore it as well)
* Working tests
* More tests, a bugfix (yay tests) and docs
* Changed filter description adding v prefix to versions
* Updated docs to be more precise
* More robust, changed docs
* Fixed copy paste bug
* extend filtering logic and configuration to include version lists
Module filtering is very useful, but many deployments will need to
satisfy even more granular constrainsts. Enterprises may need
approved lists specific down to the minor (or patch) version element.
Version filtering logic is similar to the module filtering, in that
it's a prefix match of the version requested against each entry in the
version filter list.
Closes#1045
* include version filtering in documentation with example
* allow filtering when version is missing
Endpoints that do not specify a version, such as "@v/list", only need
to be filtered by module rules.
* File permissions on config files allow more restrictive setting
* Make the tests a bit more readable
* Bring back the tests dude
* Update error message
* remove else
* Add more test cases
* Change Lstat to Stat
* Add note for umask
* Make sure the permissions are 0600 or lower
* Update config file
* Do not check for windows
* Fix CI errors
* Fix CI test
* When the filter file is missing throw a fatal
* Ignore path when file is not specified
* Fix build failure on ci
* Remove logs
* Fix propagate and handle errors
* Fix build error
* Actually check filter file
* Check for errors in the test suite as well
* Improve test coverage
* Add more tests
* Simplify NewFilter function
* Make file format rules pretty stringent
* Fix test failure
* Show line numbers on errors as well
* Fix typo
* Fix typo again
* When the filter file is missing throw a fatal
* Ignore path when file is not specified
* Fix build failure on ci
* Remove logs
* Fix propagate and handle errors
* Fix build error
* Actually check filter file
* Check for errors in the test suite as well
* Improve test coverage
* Add more tests
* Simplify NewFilter function
* Address review comments
* switch proxy to config file
pull in single flight changes
* changes for single-flight
* intermediate stage. All tests passing. pkg still has env refs
* remove all env references
* delete config/env entirely
* fix failing tests
* create the config.toml file as part of dev setup
* create config file only if it doesn't exist
* update Dockerfiles to use config file
* move composing elements to the top
* verbose parameter naming
* newline
* add flag for config file path
* update docs with config file flag
* remove unnecessary nil check
* use filepath.join
* rename redis port to address
* fix path.join
* fix issues after merge
* add vendor dir
* Initial chanages for observability
* Fix some panics to start testing
* Export tracing properly
* First example of child spans using opencensus
* Add spans to download protocol
* Add url to traces
* Remove opentracing
* Remove gopkg.* files
* Start deprecating opentracing
* Resolve stupid build errors
* Use observability package
* Fix test errors
* Convert buffalo spans to observercontext
* change package name
* defer flush to the end of the app execution
* Change op names to the correct package
* Rename pkg/observability to pkg/observ
* Show traces for the package
* Keep tracing in the earlier way
* Add info from request headers
* Remove whitespace
* Move exporter url to env var
* Add to env file for documentation
* Remove opentracing stuff
* Use stdlib
* Shorten service name
* Add a service name to olympus as well
* Add test to test if there is a recursion or not
* Add Ops Suite
* Move around code
* Make sure the service is not instantiated if the exporter is not found
* pkg/module: Remove unused file parser.go
PR #618 removed the last remaining user of the functions/types defined
in parser.go
* go.mod: update
The last user of github.com/sabhiram/go-gitignore was removed. Run 'go
mod tidy' to remove the dependency.
* vendor: remove unused dependency
The last user of github.com/sabhiram/go-gitignore was removed. Remove
the vendored copy as well by running 'go mod vendor'.
* Added filter for private repos. Non private repos get redirected to
olympus
* Changed filter to allow private modules
* Changed config file name function
* Added filter tests
* The middleware returns 200 for privates, redirects public, 404 for
disabled repos
* Removed printf
* Removed forgotten printf
* Removed logger from the middleware func, not used anymore
* Removed unused (uncommented) function
* Replaced 404 with 403 in case of banned modules
* Fixed test path / cleaned olympus endpoint suffix
* Added error operation to GetVersion
* Moved filter test in custom file, reverted injection of the filter into
the app
* Removed white line
* Clarified comment for ignoring getversion error
* Added todo comment to fill the cache and serve the request with the
cache
* Added error handling to filter
* Removed commented early version of the test