public static JenkensApi OnJenkinsDeloyer(ISettingsManager settings) { var api = new JenkensApi( settings.Get("jenkins_deployer_host", "http://therig1231:9999"), settings.Get("jenkins_deployer_user",null), settings.Get("jenkins_deployer_password",null) ); if (!string.IsNullOrEmpty(settings.GetDefaultProxy())) { api.Proxy = new WebProxy(new Uri(settings.GetDefaultProxy())); } return api; }
public static Task<JenkensProjectsResult> AllProjects() { if (_allProjects == null) { var jenkenPassword = string.IsNullOrEmpty(AppSettings.Default.JenkenPassword) ? null : new SimpleCrypt().Decrypt(AppSettings.Default.JenkenPassword); var jenkensApi = new JenkensApi(AppSettings.Default.JenkenServer,AppSettings.Default.JenkenUsername,jenkenPassword); _allProjects = jenkensApi.GetAllProjects(); } return _allProjects; }
public void Setup() { _jenkensApi = new JenkensApi(_hostApi, "rolfw", Environment.GetEnvironmentVariable("pssword")); }