Add seed for personal access token
This commit is contained in:
parent
b4de23a687
commit
4d84d1a850
1 changed files with 15 additions and 0 deletions
15
db/fixtures/development/25_api_personal_access_token.rb
Normal file
15
db/fixtures/development/25_api_personal_access_token.rb
Normal file
|
@ -0,0 +1,15 @@
|
|||
# frozen_string_literal: true
|
||||
|
||||
require './spec/support/sidekiq'
|
||||
|
||||
# Create an api access token for root user with the value: ypCa3Dzb23o5nvsixwPA
|
||||
Gitlab::Seeder.quiet do
|
||||
PersonalAccessToken.create!(
|
||||
user_id: User.find_by(username: 'root').id,
|
||||
name: "seeded-api-token",
|
||||
scopes: ["api"],
|
||||
token_digest: "/O0jfLERYT/L5gG8nfByQxqTj43TeLlRzOtJGTzRsbQ="
|
||||
)
|
||||
|
||||
print '.'
|
||||
end
|
Loading…
Reference in a new issue