Enables frozen string for some vestigial files as
well as the following:
* app/controllers/projects/**/*.rb
* app/controllers/sherlock/**/*.rb
* app/controllers/snippets/**/*.rb
* app/controllers/users/**/*.rb
Partially addresses #47424.
Since Rails 5 request.format gets set by extension if it's not explicitly
set.
That means artifacts_controller#file no longer works as expected.
This commit explicitly sets request.format for artifacts_controller#file.
Rename other URL generators
admin_builds_path -> admin_jobs_path
Fix tests and more renaming
Fix more tests
Also change build_id to job_id in the controller
* master: (335 commits)
Disable transaction when adding index for Ci::Pipeline
added changelog
allow empty repos on import/export
Modify test for Build tabs
Add tests to project builds for pending tab
Remove unused .js-running-count class
Add test for new pending tab and update tests for running tab
Add Pending Tab to Admin Builds
added changelog
limit project expor retry to only 3
use method in validates statement
Fix spec to set import_url before attempting to create import_data
Allow a project import URL to be blank to prevent false positives preventing settings from being saved
Refactor gitlab_ci_yaml_processor variables tests
Fix CI yaml example
Align cancel and retry buttons
Remove deploy to production button
Remove irrelevant comments
Fix gitlab_ci_yaml_processor_spec.rb
Fix AddWhenAndYamlVariablesToCiBuilds migration
...
It turns out they are different:
builds.success.latest.first
and
builds.latest.success.first
If we put success first, that latest would also filter via success,
and which is what we want here.
So we redirect from ref and build_name to the particular build, namely:
* /u/r/artifacts/ref/build_name/* -> /u/r/builds/:build_id/artifacts/*
For:
* download
* browse
* file
This MR simplifies CI permission model:
- read_build: allows to read a list of builds, artifacts and trace
- update_build: allows to cancel and retry builds
- create_build: allows to create builds from gitlab-ci.yml (not yet implemented)
- admin_build: allows to manage triggers, runners and variables
- read_commit_status: allows to read a list of commit statuses (including the overall of builds)
- create_commit_status: allows to create a new commit status using API
Remove all extra methods to manage permission.
Made all controllers to use explicitly the new permissions.