Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bsfy 214 #248

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
26 changes: 22 additions & 4 deletions lib/travis/yml/config.rb
Original file line number Diff line number Diff line change
Expand Up @@ -4,16 +4,34 @@
module Travis
module Yml
class Config < Travis::Config
class << self
def auth_keys
ENV['TRAVIS_AUTH_KEYS'].split(',') || ['abc123']
end

def auth_internal
ENV['TRAVIS_AUTH_INTERNAL'] || 'token'
end

def travis_token
ENV['TRAVIS_TOKEN'] || 'token'
end

def vcs_token
ENV['TRAVIS_VCS_TOKEN'] || 'token'
end
end

define enterprise: false,
auth_keys: ['abc123'],
auth: { internal: 'token' },
auth_keys: auth_keys,
auth: { internal: auth_internal },
oauth2: {},
github: { url: 'https://api.github.com', ssl: {} },
travis: { url: 'https://api.travis-ci.com', app: 'yml', token: 'token', ssl: {} },
travis: { url: 'https://api.travis-ci.com', app: 'yml', token: travis_token, ssl: {} },
metrics: { reporter: 'librato' },
imports: { max: 25 },
ssl: {},
vcs: { url: 'https://vcs.travis-ci.com', token: 'token' },
vcs: { url: 'https://vcs.travis-ci.com', token: vcs_token },
log_level: ENV.fetch("LOG_LEVEL", Logger::WARN)

def metrics
Expand Down