diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2019-12-06 18:07:44 +0000 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2019-12-06 18:07:44 +0000 |
commit | e1867c38fc5a4b931b4b2256d4909182e94f1051 (patch) | |
tree | 3047b637f7f9a31e74c62d3fe054b24c95e3534e /app/controllers/projects/raw_controller.rb | |
parent | 63894d59abd34f76f399d755012cdcd32c5b1103 (diff) | |
download | gitlab-ce-e1867c38fc5a4b931b4b2256d4909182e94f1051.tar.gz |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'app/controllers/projects/raw_controller.rb')
-rw-r--r-- | app/controllers/projects/raw_controller.rb | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/app/controllers/projects/raw_controller.rb b/app/controllers/projects/raw_controller.rb index 985587268c5..f39d98be516 100644 --- a/app/controllers/projects/raw_controller.rb +++ b/app/controllers/projects/raw_controller.rb @@ -4,11 +4,15 @@ class Projects::RawController < Projects::ApplicationController include ExtractsPath include SendsBlob + include StaticObjectExternalStorage + + prepend_before_action(only: [:show]) { authenticate_sessionless_user!(:blob) } before_action :require_non_empty_project before_action :assign_ref_vars before_action :authorize_download_code! - before_action :show_rate_limit, only: [:show] + before_action :show_rate_limit, only: [:show], unless: :external_storage_request? + before_action :redirect_to_external_storage, only: :show, if: :static_objects_external_storage_enabled? def show @blob = @repository.blob_at(@commit.id, @path) |