]> granicus.if.org Git - icinga2/commitdiff
Windows Agent: Refine setup wizard text and add docs URL
authorMichael Friedrich <michael.friedrich@icinga.com>
Wed, 31 Jul 2019 11:35:42 +0000 (13:35 +0200)
committerMichael Friedrich <michael.friedrich@icinga.com>
Wed, 31 Jul 2019 11:47:31 +0000 (13:47 +0200)
Note for others: DO NOT manually fix whitespaces with sed
and variants. Ensure that tabs (4 spaces, keep tabs) are
set inside Visual Studio.

agent/windows-setup-agent/ServiceStatus.Designer.cs
agent/windows-setup-agent/ServiceStatus.cs
agent/windows-setup-agent/SetupWizard.Designer.cs
agent/windows-setup-agent/SetupWizard.cs

index 874f29672eabc3d186016f6ef3380b9630b2789e..cda0fd4182214b22821ab124c8a4cf29bcd11bd7 100644 (file)
                /// </summary>
                private void InitializeComponent()
                {
-            System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(ServiceStatus));
-            this.picBanner = new System.Windows.Forms.PictureBox();
-            this.lblStatus = new System.Windows.Forms.Label();
-            this.txtStatus = new System.Windows.Forms.TextBox();
-            this.btnReconfigure = new System.Windows.Forms.Button();
-            this.btnOK = new System.Windows.Forms.Button();
-            this.btnOpenConfigDir = new System.Windows.Forms.Button();
-            ((System.ComponentModel.ISupportInitialize)(this.picBanner)).BeginInit();
-            this.SuspendLayout();
-            // 
-            // picBanner
-            // 
-            this.picBanner.Image = global::Icinga.Properties.Resources.icinga_banner;
-            this.picBanner.Location = new System.Drawing.Point(0, 0);
-            this.picBanner.Name = "picBanner";
-            this.picBanner.Size = new System.Drawing.Size(625, 77);
-            this.picBanner.TabIndex = 2;
-            this.picBanner.TabStop = false;
-            // 
-            // lblStatus
-            // 
-            this.lblStatus.AutoSize = true;
-            this.lblStatus.Location = new System.Drawing.Point(12, 105);
-            this.lblStatus.Name = "lblStatus";
-            this.lblStatus.Size = new System.Drawing.Size(79, 13);
-            this.lblStatus.TabIndex = 3;
-            this.lblStatus.Text = "Service Status:";
-            // 
-            // txtStatus
-            // 
-            this.txtStatus.Location = new System.Drawing.Point(97, 102);
-            this.txtStatus.Name = "txtStatus";
-            this.txtStatus.ReadOnly = true;
-            this.txtStatus.Size = new System.Drawing.Size(278, 20);
-            this.txtStatus.TabIndex = 3;
-            // 
-            // btnReconfigure
-            // 
-            this.btnReconfigure.Location = new System.Drawing.Point(195, 143);
-            this.btnReconfigure.Name = "btnReconfigure";
-            this.btnReconfigure.Size = new System.Drawing.Size(89, 23);
-            this.btnReconfigure.TabIndex = 1;
-            this.btnReconfigure.Text = "Reconfigure";
-            this.btnReconfigure.UseVisualStyleBackColor = true;
-            this.btnReconfigure.Click += new System.EventHandler(this.btnReconfigure_Click);
-            // 
-            // btnOK
-            // 
-            this.btnOK.DialogResult = System.Windows.Forms.DialogResult.Cancel;
-            this.btnOK.Location = new System.Drawing.Point(290, 143);
-            this.btnOK.Name = "btnOK";
-            this.btnOK.Size = new System.Drawing.Size(89, 23);
-            this.btnOK.TabIndex = 0;
-            this.btnOK.Text = "OK";
-            this.btnOK.UseVisualStyleBackColor = true;
-            this.btnOK.Click += new System.EventHandler(this.btnOK_Click);
-            // 
-            // btnOpenConfigDir
-            // 
-            this.btnOpenConfigDir.DialogResult = System.Windows.Forms.DialogResult.Cancel;
-            this.btnOpenConfigDir.Location = new System.Drawing.Point(100, 143);
-            this.btnOpenConfigDir.Name = "btnOpenConfigDir";
-            this.btnOpenConfigDir.Size = new System.Drawing.Size(89, 23);
-            this.btnOpenConfigDir.TabIndex = 2;
-            this.btnOpenConfigDir.Text = "Examine Config";
-            this.btnOpenConfigDir.UseVisualStyleBackColor = true;
-            this.btnOpenConfigDir.Click += new System.EventHandler(this.btnOpenConfigDir_Click);
-            // 
-            // ServiceStatus
-            // 
-            this.AcceptButton = this.btnOK;
-            this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
-            this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
-            this.CancelButton = this.btnOK;
-            this.ClientSize = new System.Drawing.Size(391, 186);
-            this.Controls.Add(this.btnOpenConfigDir);
-            this.Controls.Add(this.btnOK);
-            this.Controls.Add(this.btnReconfigure);
-            this.Controls.Add(this.txtStatus);
-            this.Controls.Add(this.lblStatus);
-            this.Controls.Add(this.picBanner);
-            this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedSingle;
-            this.Icon = ((System.Drawing.Icon)(resources.GetObject("$this.Icon")));
-            this.MaximizeBox = false;
-            this.Name = "ServiceStatus";
-            this.Text = "Icinga 2 Service Status";
-            ((System.ComponentModel.ISupportInitialize)(this.picBanner)).EndInit();
-            this.ResumeLayout(false);
-            this.PerformLayout();
+                       System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(ServiceStatus));
+                       this.picBanner = new System.Windows.Forms.PictureBox();
+                       this.lblStatus = new System.Windows.Forms.Label();
+                       this.txtStatus = new System.Windows.Forms.TextBox();
+                       this.btnReconfigure = new System.Windows.Forms.Button();
+                       this.btnOK = new System.Windows.Forms.Button();
+                       this.btnOpenConfigDir = new System.Windows.Forms.Button();
+                       ((System.ComponentModel.ISupportInitialize)(this.picBanner)).BeginInit();
+                       this.SuspendLayout();
+                       // 
+                       // picBanner
+                       // 
+                       this.picBanner.Image = global::Icinga.Properties.Resources.icinga_banner;
+                       this.picBanner.Location = new System.Drawing.Point(0, 0);
+                       this.picBanner.Name = "picBanner";
+                       this.picBanner.Size = new System.Drawing.Size(625, 77);
+                       this.picBanner.TabIndex = 2;
+                       this.picBanner.TabStop = false;
+                       // 
+                       // lblStatus
+                       // 
+                       this.lblStatus.AutoSize = true;
+                       this.lblStatus.Location = new System.Drawing.Point(12, 105);
+                       this.lblStatus.Name = "lblStatus";
+                       this.lblStatus.Size = new System.Drawing.Size(79, 13);
+                       this.lblStatus.TabIndex = 3;
+                       this.lblStatus.Text = "Service Status:";
+                       // 
+                       // txtStatus
+                       // 
+                       this.txtStatus.Location = new System.Drawing.Point(97, 102);
+                       this.txtStatus.Name = "txtStatus";
+                       this.txtStatus.ReadOnly = true;
+                       this.txtStatus.Size = new System.Drawing.Size(278, 20);
+                       this.txtStatus.TabIndex = 3;
+                       // 
+                       // btnReconfigure
+                       // 
+                       this.btnReconfigure.Location = new System.Drawing.Point(195, 143);
+                       this.btnReconfigure.Name = "btnReconfigure";
+                       this.btnReconfigure.Size = new System.Drawing.Size(89, 23);
+                       this.btnReconfigure.TabIndex = 1;
+                       this.btnReconfigure.Text = "Reconfigure";
+                       this.btnReconfigure.UseVisualStyleBackColor = true;
+                       this.btnReconfigure.Click += new System.EventHandler(this.btnReconfigure_Click);
+                       // 
+                       // btnOK
+                       // 
+                       this.btnOK.DialogResult = System.Windows.Forms.DialogResult.Cancel;
+                       this.btnOK.Location = new System.Drawing.Point(290, 143);
+                       this.btnOK.Name = "btnOK";
+                       this.btnOK.Size = new System.Drawing.Size(89, 23);
+                       this.btnOK.TabIndex = 0;
+                       this.btnOK.Text = "OK";
+                       this.btnOK.UseVisualStyleBackColor = true;
+                       this.btnOK.Click += new System.EventHandler(this.btnOK_Click);
+                       // 
+                       // btnOpenConfigDir
+                       // 
+                       this.btnOpenConfigDir.DialogResult = System.Windows.Forms.DialogResult.Cancel;
+                       this.btnOpenConfigDir.Location = new System.Drawing.Point(100, 143);
+                       this.btnOpenConfigDir.Name = "btnOpenConfigDir";
+                       this.btnOpenConfigDir.Size = new System.Drawing.Size(89, 23);
+                       this.btnOpenConfigDir.TabIndex = 2;
+                       this.btnOpenConfigDir.Text = "Examine Config";
+                       this.btnOpenConfigDir.UseVisualStyleBackColor = true;
+                       this.btnOpenConfigDir.Click += new System.EventHandler(this.btnOpenConfigDir_Click);
+                       // 
+                       // ServiceStatus
+                       // 
+                       this.AcceptButton = this.btnOK;
+                       this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
+                       this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
+                       this.CancelButton = this.btnOK;
+                       this.ClientSize = new System.Drawing.Size(391, 186);
+                       this.Controls.Add(this.btnOpenConfigDir);
+                       this.Controls.Add(this.btnOK);
+                       this.Controls.Add(this.btnReconfigure);
+                       this.Controls.Add(this.txtStatus);
+                       this.Controls.Add(this.lblStatus);
+                       this.Controls.Add(this.picBanner);
+                       this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedSingle;
+                       this.Icon = ((System.Drawing.Icon)(resources.GetObject("$this.Icon")));
+                       this.MaximizeBox = false;
+                       this.Name = "ServiceStatus";
+                       this.Text = "Icinga Windows Agent Service Status";
+                       ((System.ComponentModel.ISupportInitialize)(this.picBanner)).EndInit();
+                       this.ResumeLayout(false);
+                       this.PerformLayout();
 
                }
 
index e9782fe1d528f6ed0b90b7de7469d4aa9568915d..c1272a98d72c1b10210b0defb7c142194c8bf6a3 100644 (file)
@@ -1,9 +1,4 @@
 using System;
-using System.Collections.Generic;
-using System.ComponentModel;
-using System.Data;
-using System.Drawing;
-using System.Text;
 using System.Windows.Forms;
 using System.ServiceProcess;
 using System.Diagnostics;
index 090e34d37eadbe09c147abac003bdc608289ed53..7dc52d1c497b6bd86ea1babb53d686a854b4119c 100644 (file)
@@ -46,6 +46,7 @@
                        this.colGlobalZoneName = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader()));
                        this.introduction1 = new System.Windows.Forms.Label();
                        this.groupBox3 = new System.Windows.Forms.GroupBox();
+                       this.chkDisableConf = new System.Windows.Forms.CheckBox();
                        this.txtUser = new System.Windows.Forms.TextBox();
                        this.chkRunServiceAsThisUser = new System.Windows.Forms.CheckBox();
                        this.chkInstallNSCP = new System.Windows.Forms.CheckBox();
@@ -87,7 +88,7 @@
                        this.txtError = new System.Windows.Forms.TextBox();
                        this.lblError = new System.Windows.Forms.Label();
                        this.picBanner = new System.Windows.Forms.PictureBox();
-                       this.chkDisableConf = new System.Windows.Forms.CheckBox();
+                       this.linkLabelDocs = new System.Windows.Forms.LinkLabel();
                        this.tabFinish.SuspendLayout();
                        this.tabConfigure.SuspendLayout();
                        this.tabParameters.SuspendLayout();
                        this.tabFinish.Location = new System.Drawing.Point(4, 5);
                        this.tabFinish.Name = "tabFinish";
                        this.tabFinish.Padding = new System.Windows.Forms.Padding(3);
-                       this.tabFinish.Size = new System.Drawing.Size(617, 471);
+                       this.tabFinish.Size = new System.Drawing.Size(617, 495);
                        this.tabFinish.TabIndex = 5;
                        this.tabFinish.Text = "Finish";
                        this.tabFinish.UseVisualStyleBackColor = true;
                        this.lblSetupCompleted.AutoSize = true;
                        this.lblSetupCompleted.Location = new System.Drawing.Point(34, 35);
                        this.lblSetupCompleted.Name = "lblSetupCompleted";
-                       this.lblSetupCompleted.Size = new System.Drawing.Size(259, 13);
+                       this.lblSetupCompleted.Size = new System.Drawing.Size(252, 13);
                        this.lblSetupCompleted.TabIndex = 0;
                        this.lblSetupCompleted.Text = "The Icinga Windows agent was set up successfully.";
                        // 
                        this.tabConfigure.Location = new System.Drawing.Point(4, 5);
                        this.tabConfigure.Name = "tabConfigure";
                        this.tabConfigure.Padding = new System.Windows.Forms.Padding(3);
-                       this.tabConfigure.Size = new System.Drawing.Size(617, 471);
+                       this.tabConfigure.Size = new System.Drawing.Size(617, 495);
                        this.tabConfigure.TabIndex = 4;
                        this.tabConfigure.Text = "Configure Icinga 2";
                        this.tabConfigure.UseVisualStyleBackColor = true;
                        // 
                        // tabParameters
                        // 
+                       this.tabParameters.Controls.Add(this.linkLabelDocs);
                        this.tabParameters.Controls.Add(this.groupBox4);
                        this.tabParameters.Controls.Add(this.introduction1);
                        this.tabParameters.Controls.Add(this.groupBox3);
                        this.introduction1.AutoSize = true;
                        this.introduction1.Location = new System.Drawing.Point(11, 3);
                        this.introduction1.Name = "introduction1";
-                       this.introduction1.Size = new System.Drawing.Size(269, 13);
+                       this.introduction1.Size = new System.Drawing.Size(262, 13);
                        this.introduction1.TabIndex = 6;
                        this.introduction1.Text = "Welcome to the Icinga Windows Agent Setup Wizard!";
                        // 
                        this.groupBox3.TabStop = false;
                        this.groupBox3.Text = "Advanced Options";
                        // 
+                       // chkDisableConf
+                       // 
+                       this.chkDisableConf.AutoSize = true;
+                       this.chkDisableConf.Checked = true;
+                       this.chkDisableConf.CheckState = System.Windows.Forms.CheckState.Checked;
+                       this.chkDisableConf.Location = new System.Drawing.Point(9, 137);
+                       this.chkDisableConf.Name = "chkDisableConf";
+                       this.chkDisableConf.Size = new System.Drawing.Size(211, 17);
+                       this.chkDisableConf.TabIndex = 9;
+                       this.chkDisableConf.Text = "Disable including local \'conf.d\' directory";
+                       this.chkDisableConf.UseVisualStyleBackColor = true;
+                       // 
                        // txtUser
                        // 
                        this.txtUser.Enabled = false;
                        // 
                        // txtTicket
                        // 
-                       this.txtTicket.Location = new System.Drawing.Point(136, 56);
+                       this.txtTicket.Location = new System.Drawing.Point(164, 56);
                        this.txtTicket.Name = "txtTicket";
-                       this.txtTicket.Size = new System.Drawing.Size(378, 20);
+                       this.txtTicket.Size = new System.Drawing.Size(350, 20);
                        this.txtTicket.TabIndex = 1;
                        // 
                        // lblTicket
                        this.lblTicket.AutoSize = true;
                        this.lblTicket.Location = new System.Drawing.Point(9, 59);
                        this.lblTicket.Name = "lblTicket";
-                       this.lblTicket.Size = new System.Drawing.Size(117, 13);
+                       this.lblTicket.Size = new System.Drawing.Size(149, 13);
                        this.lblTicket.TabIndex = 4;
-                       this.lblTicket.Text = "Setup Ticket (optional):";
+                       this.lblTicket.Text = "CSR Signing Ticket (optional):";
                        // 
                        // txtInstanceName
                        // 
-                       this.txtInstanceName.Location = new System.Drawing.Point(136, 27);
+                       this.txtInstanceName.Location = new System.Drawing.Point(164, 27);
                        this.txtInstanceName.Name = "txtInstanceName";
-                       this.txtInstanceName.Size = new System.Drawing.Size(378, 20);
+                       this.txtInstanceName.Size = new System.Drawing.Size(350, 20);
                        this.txtInstanceName.TabIndex = 0;
                        // 
                        // lblInstanceName
                        this.tabRetrieveCertificate.Location = new System.Drawing.Point(4, 5);
                        this.tabRetrieveCertificate.Name = "tabRetrieveCertificate";
                        this.tabRetrieveCertificate.Padding = new System.Windows.Forms.Padding(3);
-                       this.tabRetrieveCertificate.Size = new System.Drawing.Size(617, 471);
+                       this.tabRetrieveCertificate.Size = new System.Drawing.Size(617, 495);
                        this.tabRetrieveCertificate.TabIndex = 7;
                        this.tabRetrieveCertificate.Text = "Checking Certificate";
                        this.tabRetrieveCertificate.UseVisualStyleBackColor = true;
                        this.tabVerifyCertificate.Location = new System.Drawing.Point(4, 5);
                        this.tabVerifyCertificate.Name = "tabVerifyCertificate";
                        this.tabVerifyCertificate.Padding = new System.Windows.Forms.Padding(3);
-                       this.tabVerifyCertificate.Size = new System.Drawing.Size(617, 471);
+                       this.tabVerifyCertificate.Size = new System.Drawing.Size(617, 495);
                        this.tabVerifyCertificate.TabIndex = 6;
                        this.tabVerifyCertificate.Text = "Verify Certificate";
                        this.tabVerifyCertificate.UseVisualStyleBackColor = true;
                        this.tabError.Location = new System.Drawing.Point(4, 5);
                        this.tabError.Name = "tabError";
                        this.tabError.Padding = new System.Windows.Forms.Padding(3);
-                       this.tabError.Size = new System.Drawing.Size(617, 471);
+                       this.tabError.Size = new System.Drawing.Size(617, 495);
                        this.tabError.TabIndex = 8;
                        this.tabError.Text = "Error";
                        this.tabError.UseVisualStyleBackColor = true;
                        // 
                        // picBanner
                        // 
-                       this.picBanner.Image = global::Icinga.Properties.Resources.icinga_banner;
+                       this.picBanner.Image = ((System.Drawing.Image)(resources.GetObject("picBanner.Image")));
                        this.picBanner.Location = new System.Drawing.Point(0, 0);
                        this.picBanner.Name = "picBanner";
                        this.picBanner.Size = new System.Drawing.Size(625, 77);
                        this.picBanner.TabIndex = 1;
                        this.picBanner.TabStop = false;
                        // 
-                       // chkDisableConf
+                       // linkLabelDocs
                        // 
-                       this.chkDisableConf.AutoSize = true;
-                       this.chkDisableConf.Checked = true;
-                       this.chkDisableConf.CheckState = System.Windows.Forms.CheckState.Checked;
-                       this.chkDisableConf.Location = new System.Drawing.Point(9, 137);
-                       this.chkDisableConf.Name = "chkDisableConf";
-                       this.chkDisableConf.Size = new System.Drawing.Size(138, 17);
-                       this.chkDisableConf.TabIndex = 9;
-                       this.chkDisableConf.Text = "Disable conf.d inclusion";
-                       this.chkDisableConf.UseVisualStyleBackColor = true;
-                       this.chkDisableConf.CheckedChanged += new System.EventHandler(this.checkBox1_CheckedChanged);
+                       this.linkLabelDocs.AutoSize = true;
+                       this.linkLabelDocs.LinkColor = System.Drawing.Color.FromArgb(((int)(((byte)(0)))), ((int)(((byte)(149)))), ((int)(((byte)(191)))));
+                       this.linkLabelDocs.Location = new System.Drawing.Point(525, 3);
+                       this.linkLabelDocs.Name = "linkLabelDocs";
+                       this.linkLabelDocs.Size = new System.Drawing.Size(79, 13);
+                       this.linkLabelDocs.TabIndex = 10;
+                       this.linkLabelDocs.TabStop = true;
+                       this.linkLabelDocs.Text = "Documentation";
+                       this.linkLabelDocs.VisitedLinkColor = System.Drawing.Color.FromArgb(((int)(((byte)(0)))), ((int)(((byte)(149)))), ((int)(((byte)(191)))));
+                       this.linkLabelDocs.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.linkLabelDocs_LinkClicked);
                        // 
                        // SetupWizard
                        // 
                        this.Icon = ((System.Drawing.Icon)(resources.GetObject("$this.Icon")));
                        this.MaximizeBox = false;
                        this.Name = "SetupWizard";
-                       this.Text = "Icinga 2 Setup Wizard";
+                       this.Text = "Icinga Windows Agent Setup Wizard";
+                       this.Load += new System.EventHandler(this.SetupWizard_Load);
                        this.tabFinish.ResumeLayout(false);
                        this.tabFinish.PerformLayout();
                        this.tabConfigure.ResumeLayout(false);
                        this.tabError.PerformLayout();
                        ((System.ComponentModel.ISupportInitialize)(this.picBanner)).EndInit();
                        this.ResumeLayout(false);
-                       this.Load += new System.EventHandler(this.SetupWizard_Load);
+
                }
 
                #endregion
                private System.Windows.Forms.ListView lvwGlobalZones;
                private System.Windows.Forms.ColumnHeader colGlobalZoneName;
                private System.Windows.Forms.CheckBox chkDisableConf;
+               private System.Windows.Forms.LinkLabel linkLabelDocs;
        }
 }
 
index b28fd53c85160d016ba1c9b3b367398c0f7a6bd7..84d322704b3f5fb245d8ea94d1d96ca336b5fd15 100644 (file)
@@ -1,16 +1,11 @@
 using System;
 using System.IO;
 using System.Text;
-using System.Collections.Generic;
-using System.ComponentModel;
 using System.Windows.Forms;
-using System.Runtime.InteropServices;
 using System.Security.Cryptography.X509Certificates;
 using System.Threading;
 using System.Net.NetworkInformation;
-using System.IO.Compression;
 using System.Diagnostics;
-using System.ServiceProcess;
 using System.Security.AccessControl;
 
 namespace Icinga
@@ -572,16 +567,18 @@ namespace Icinga
                        lvwGlobalZones.Items.Add(lvi2);
                }
 
-               private void checkBox1_CheckedChanged(object sender, EventArgs e)
-               {
-
-               }
-
                private void SetupWizard_Load(object sender, EventArgs e)
                {
                        this.MinimumSize = this.Size;
                        this.MaximumSize = this.Size;
                }
+
+               private void linkLabelDocs_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e)
+               {
+                       linkLabelDocs.LinkVisited = true;
+
+                       Process.Start("https://icinga.com/docs/icinga2/latest/");
+               }
        }
 }