Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-pages.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2020-05-28Revert goconst changes in auth_test.goJaime Martinez
2020-05-28Add .golangci.yml linter configurationJaime Martinez
As part of https://gitlab.com/gitlab-org/gitlab-pages/-/issues/385 we have introduced the use of a custom `.golangci.yml` file with some custom rules for linting. This replaces the need of downloading and using `golint`, `gofmt` `go vet` and `gocyclo` manually. We take advantage of the custom `golangci-lint` docker image as stated in the [Automatic lintinb] (https://docs.gitlab.com/ee/development/go_guide/#automatic-linting) section of the Go standards and style guidelines. This iteration enables a subset of linters, with the remaining of them enabled on a separate MR as described in the issue above. The main changes introduced by this linter include: - gosec: potential hardcoded credentials - goconst: DRY by declaring and using constants - gosimple: reduce statements complexity and improve return statements
2020-05-25Only use gosect-sast and secrets-sast scansJaime Martinez
2020-05-19Rename flag to domain-config-sourceJaime Martinez
2020-05-18Add domain-source config flagJaime Martinez
This is an incremental step for adding `-domain-source` as described in https://gitlab.com/gitlab-org/gitlab/-/issues/217912. We are only adding the flag here but it's not doing anything at the moment. Add TODO for implementation
2020-05-12Merge branch 'fix/gb/gitlab-api-reuse-http-connections' into 'master'Vladimir Shushlin
Ensure that we always close GitLab API response body See merge request gitlab-org/gitlab-pages!275
2020-05-12Ensure that we always close GitLab API response bodyGrzegorz Bizon
This change is important because in case of receiving a JSON payload from GitLab API that is invalid, and is larger than 512, deserializer will stop reading it after 512 bytes and will not close the reader. This will result in HTTP connection not being reused. This commit ensures that we always read reasponse body until EOF and that we close the reader afterwards.
2020-05-08Test that standart arguments are allowed260-secrets-from-file-onlyVladimir Shushlin
2020-05-08Consolidate args validationJaime Martinez
2020-05-08Enforce loading secrets from fileJaime Martinez
Passing secrets via command line is not allowed anymore. A config file should be used instead. The default filename is `gitlab-pages-config`. The following command line options will throw an error and prevent pages from running if set explicitly: - `-auth-client-id` - `-auth-client-secret` - `-auth-secret`
2020-05-08Fix deprecated args validationJaime Martinez
Fixes check for deprecated arguments to cater for key=value arugments. It also logs the warning if a deprecated flag is used.
2020-05-08explicitly set MaxIdleConns, so that it is clear we need to update it when ↵Igor
increasing MaxIdleConnsPerHost
2020-04-30change back to internal-gitlab-server as per @@vshushlinIgor Wiedler
2020-04-30rename GitlabServerURL to GitlabAPIServerURL (as per @@krasio)Igor Wiedler
2020-04-30rename internal-gitlab-server to gitlab-api-server (as per @@krasio)Igor Wiedler
2020-04-29introduce separate config flag internal-gitlab-serverIgor Wiedler
2020-03-30Remove obsolete test case for gitlab source cacheGrzegorz Bizon
2020-03-27Fix gitlab source cache tests durationGrzegorz Bizon
This reduces tests duration from 30sec to milliseconds.
2020-03-10Update special characters test to lowercaseCatalin Irimie
2020-03-06Encode artifact path to fix wrongly generated URLsCatalin Irimie
2020-03-05Merge branch 'support-go-1-14' into 'master'Vladimir Shushlin
Add golang:1.14 tests in CI and fix GitLab source client test See merge request gitlab-org/gitlab-pages!250
2020-03-04Merge branch '350-healthcheck-middleware' into 'master'Alessio Caiazza
Extract health check in its own middleware See merge request gitlab-org/gitlab-pages!247
2020-03-04Increase GitLab internal API response timeoutGrzegorz Bizon
2020-03-03Add default cache configuration and pass down to memstore and Entry.Jaime Martinez
Wrap global variables into one default struct. Update test steps so that tests run every time so we don't get the cached results.
2020-02-28Merge branch 'backstage/gb/add-ensure-certs-benchmark' into 'master'Alessio Caiazza
Add benchmark for throughput on ensuring domain certs See merge request gitlab-org/gitlab-pages!251
2020-02-28Merge branch 'feature/gb/serverless-serving-enable' into 'master'Alessio Caiazza
Enable serverless serving See merge request gitlab-org/gitlab-pages!232
2020-02-28Add benchmark for throughput on ensuring domain certsGrzegorz Bizon
2020-02-28Avoid implicit delegation in disk servingGrzegorz Bizon
2020-02-28Add golang:1.14 tests in CI and fix GitLab source client testJaime Martinez
2020-02-28Extract health check in its own middlewareKrasimir Angelov
This way we short-circuit health check requests and avoid doing domain lookup for them. We also do not report them in exported Prometheus metrics and this way avoid trigger alerts during deploys. Related to: * https://gitlab.com/gitlab-org/gitlab-pages/issues/350 * https://gitlab.com/gitlab-com/gl-infra/production/issues/1681
2020-02-27Improve comments and code readabilityGrzegorz Bizon
2020-02-26Skip racy testAlessio Caiazza
2020-02-26Fix data race on cache.client structAlessio Caiazza
2020-02-24Log an error when a serving can not be fabricatedGrzegorz Bizon
2020-02-24Move serving and lookup path factory to source packageGrzegorz Bizon
2020-02-24Improve code quality and add a few missing commentsGrzegorz Bizon
2020-02-19Remove request.WithHTTPSFlag and set directly in testsJaime Martinez
2020-02-18Fix go imports in factory lookup_path.go fileGrzegorz Bizon
2020-02-18Simplify serverless serving and add a few testsGrzegorz Bizon
2020-02-18Add tests for gitlab source lookup path factoryGrzegorz Bizon
2020-02-18Enable serverless domains sourceGrzegorz Bizon
2020-02-18Ensure that we not do return nil serving.RequestGrzegorz Bizon
2020-02-17Remove ctxHTTPSKey from the context completelyJaime Martinez
2020-02-12Merge branch 'master' into feature/gb/serverless-serving-enableGrzegorz Bizon
* master: Add prometheus metrics for GitLab API client Fix benchmarks Freeze tools version Add acceptance test for serverless metrics Update documentation on using Gorilla ProxyHeaders use gorilla/handlers.ProxyHeaders to get the X-Forwarded-* headers and set them in the appropriate http.Request fields Apply suggestion to metrics/metrics.go Add serverless serving metrics Conflicts: internal/serving/serverless/serverless.go
2020-02-12Make it possible to fabricate a serverless servingGrzegorz Bizon
2020-02-12Add GitLab API definition for serverless servingGrzegorz Bizon
2020-02-11Memoize disk serving on a package levelGrzegorz Bizon
2020-02-11Make it possible to fabricate serving per requestGrzegorz Bizon
2020-02-11Add prometheus metrics for GitLab API clientJaime Martinez
Refactor metrics initialization removing init function from the metrics package.
2020-02-07Rename lookup variable in domain struct functionGrzegorz Bizon