private Dictionary <string, dynamic> CreateParameters(IRemoteSettings remoteSettings) { return(new Dictionary <string, dynamic> { { "Activity", Settings.Initialize.ProgressActivityName }, { "RemoteHost", remoteSettings.RemoteHost }, { "Credentials", new PSCredential(remoteSettings.RemoteUsername, remoteSettings.RemotePassword.ToSecureString()) }, { "RemoteDirectory", Settings.RemoteDirectory }, { "ModuleFiles", Modules.ToBeCopiedToRemote }, }); }
public IProfile CreateProfile(IRemoteSettings remoteSettings) { var profile = CreateProfile(); profile.RemotingEnabled = remoteSettings.RemotingEnabled; profile.RemoteHost = remoteSettings.RemoteHost; profile.RemoteUsername = remoteSettings.RemoteUsername; profile.RemotePassword = remoteSettings.RemotePassword; profile.RemoteFolder = remoteSettings.RemoteFolder; return(profile); }
// fake profile is initially passed: always runs local, also passes credentials internal InitRemotePresenter(InitRemoteView view, IRemoteSettings remoteSettings) { _view = view; _parameters = CreateParameters(remoteSettings); _view.FormLoaded += FormLoaded; var localProfile = Create.New <IProfilesProvider>().CreateLocal(); _scriptWrapper = Create.WithParam(_view, d => d?.ToString(), localProfile); _scriptWrapper.ProgressReady += ProgressReady; _scriptWrapper.ErrorReady += ErrorReady; }
public RemoteService() { _client = new HttpClient(); Settings = DependencyService.Get <IRemoteSettings>(); }
public ChaosConfigurationChangedHookController(IRemoteSettings remoteSettings, HttpConfiguration configuration) { this.remoteSettings = remoteSettings; this.configuration = configuration; }
public RemoteTarget(IRemoteSettings settings) { _settings = settings; }