Repository: Azure/ARO-RP
Pull request #1956 (2022-02-10 13:49:18)

quick fixes in docs
### Which issue this PR addresses:

N/A just cleaning up

### What this PR does / why we need it:

minor doc fixes

### Test plan for issue:

The instructions now work in the docs

### Is there any documentation that needs to be updated for this PR?
N/A


Patch:
diff --git a/.config/CredScanSuppressions.json b/.config/CredScanSuppressions.json
index b18523171..d1aaccd12 100644
--- a/.config/CredScanSuppressions.json
+++ b/.config/CredScanSuppressions.json
@@ -36,6 +36,14 @@
         {
             "file": "verify_test_dsa.go",
             "_justification": "sample login for testing"
+        },
+        {
+            "file": "vendor/google.golang.org/api/compute/v1/compute-api.json",
+            "_justification": "example secret in comment on line 33112"
+        },
+        {
+            "file": "vendor/google.golang.org/api/compute/v1/compute-gen.go",
+            "_justification": "example secret in comment on line 8048"
         }
     ]
 }
diff --git a/.config/tsaoptions.json b/.config/tsaoptions.json
new file mode 100644
index 000000000..2210d40d5
--- /dev/null
+++ b/.config/tsaoptions.json
@@ -0,0 +1,11 @@
+{
+    "instanceUrl": "https://msazure.visualstudio.com/",
+    "projectName": "AzureRedHatOpenShift",
+    "areaPath": "AzureRedHatOpenShift\\MS ARO",
+    "iterationPath": "AzureRedHatOpenShift",
+    "codebaseName": "TFSMSAzureOneAgile_ARO-RP",
+    "template": "TFSMSAzureOneAgile",
+    "notificationAliases": [
+      "aromsfteng@microsoft.com"
+    ]
+}
\ No newline at end of file
diff --git a/.pipelines/onebranch/pipeline.buildrp.official.yml b/.pipelines/onebranch/pipeline.buildrp.official.yml
index 17e2d2302..4d1041d09 100644
--- a/.pipelines/onebranch/pipeline.buildrp.official.yml
+++ b/.pipelines/onebranch/pipeline.buildrp.official.yml
@@ -33,8 +33,8 @@ extends:
   template: v2/OneBranch.Official.CrossPlat.yml@templates # https://aka.ms/obpipelines/templates
   parameters:
     globalSdl: # https://aka.ms/obpipelines/sdl
-      # tsa:
-      #  enabled: true # SDL results of non-official builds aren't uploaded to TSA by default.
+      tsa:
+        enabled: true # SDL results of non-official builds aren't uploaded to TSA by default.
       # credscan:
       #   suppressionsFile: $(Build.SourcesDirectory)\.config\CredScanSuppressions.json
       disableLegacyManifest: true
diff --git a/.pipelines/onebranch/pipeline.logging.geneva.bootstrapper.pullrequest.yml b/.pipelines/onebranch/pipeline.logging.geneva.bootstrapper.pullrequest.yml
deleted file mode 100644
index a6a32cd2f..000000000
--- a/.pipelines/onebranch/pipeline.logging.geneva.bootstrapper.pullrequest.yml
+++ /dev/null
@@ -1,52 +0,0 @@
-#################################################################################
-#                               OneBranch Pipelines                             #
-# This pipeline was created by EasyStart from a sample located at:              #
-#   https://aka.ms/obpipelines/easystart/samples                                #
-# Documentation:  https://aka.ms/obpipelines                                    #
-# Yaml Schema:    https://aka.ms/obpipelines/yaml/schema                        #
-# Retail Tasks:   https://aka.ms/obpipelines/tasks                              #
-# Support:        https://aka.ms/onebranchsup                                   #
-#################################################################################
-
-trigger: none
-pr: none
-
-variables:
-  Cdp_Definition_Build_Count: $[counter('', 0)] # needed for onebranch.pipeline.version task https://aka.ms/obpipelines/versioning
-  LinuxContainerImage: cdpxlinux.azurecr.io/user/aro/ubi8-gotoolset-1.14.12:2021.10.12   # Docker image which is used to build the project https://aka.ms/obpipelines/containers
-  Debian_Frontend: noninteractive
-
-resources:
-  repositories:
-  - repository: templates
-    type: git
-    name: OneBranch.Pipelines/GovernedTemplates
-    ref: refs/heads/main
-  - repository: rhado
-    type: git
-    name: ARO.Pipelines
-  - repository: rpconfig
-    type: git
-    name: RP-Config
-
-extends:
-  template: v2/OneBranch.NonOfficial.CrossPlat.yml@templates # https://aka.ms/obpipelines/templates
-  parameters:
-    globalSdl: # https://aka.ms/obpipelines/sdl
-      # tsa:
-      #  enabled: true # SDL results of non-official builds aren't uploaded to TSA by default.
-      # credscan:
-      #   suppressionsFile: $(Build.SourcesDirectory)\.config\CredScanSuppressions.json
-      disableLegacyManifest: true
-      sbom:
-        enabled: true
-      policheck:
-        break: true # always break the build on policheck issues. You can disable it by setting to 'false'
-      suppression:
-        suppressionFile: $(Build.SourcesDirectory)\.gdn\.gdnsuppress
-        suppressionSet: default
-
-    stages:
-    - stage: LoggingGenevaBootstrapper
-      jobs:
-      - template: .pipelines/onebranch/templates/template-logging-geneva-bootstrapper.yml@self
diff --git a/.pipelines/onebranch/pipeline.logging.geneva.pullrequest.yml b/.pipelines/onebranch/pipeline.logging.geneva.pullrequest.yml
deleted file mode 100644
index 8fa0a38cf..000000000
--- a/.pipelines/onebranch/pipeline.logging.geneva.pullrequest.yml
+++ /dev/null
@@ -1,52 +0,0 @@
-#################################################################################
-#                               OneBranch Pipelines                             #
-# This pipeline was created by EasyStart from a sample located at:              #
-#   https://aka.ms/obpipelines/easystart/samples                                #
-# Documentation:  https://aka.ms/obpipelines                                    #
-# Yaml Schema:    https://aka.ms/obpipelines/yaml/schema                        #
-# Retail Tasks:   https://aka.ms/obpipelines/tasks                              #
-# Support:        https://aka.ms/onebranchsup                                   #
-#################################################################################
-
-trigger: none
-pr: none
-
-variables:
-  Cdp_Definition_Build_Count: $[counter('', 0)] # needed for onebranch.pipeline.version task https://aka.ms/obpipelines/versioning
-  LinuxContainerImage: cdpxlinux.azurecr.io/user/aro/ubi8-gotoolset-1.14.12:2021.10.12   # Docker image which is used to build the project https://aka.ms/obpipelines/containers
-  Debian_Frontend: noninteractive
-
-resources:
-  repositories:
-  - repository: templates
-    type: git
-    name: OneBranch.Pipelines/GovernedTemplates
-    ref: refs/heads/main
-  - repository: rhado
-    type: git
-    name: ARO.Pipelines
-  - repository: rpconfig
-    type: git
-    name: RP-Config
-
-extends:
-  template: v2/OneBranch.NonOfficial.CrossPlat.yml@templates # https://aka.ms/obpipelines/templates
-  parameters:
-    globalSdl: # https://aka.ms/obpipelines/sdl
-      # tsa:
-      #  enabled: true # SDL results of non-official builds aren't uploaded to TSA by default.
-      # credscan:
-      #   suppressionsFile: $(Build.SourcesDirectory)\.config\CredScanSuppressions.json
-      disableLegacyManifest: true
-      sbom:
-        enabled: true
-      policheck:
-        break: true # always break the build on policheck issues. You can disable it by setting to 'false'
-      suppression:
-        suppressionFile: $(Build.SourcesDirectory)\.gdn\.gdnsuppress
-        suppressionSet: default
-
-    stages:
-    - stage: LoggingGeneva
-      jobs:
-      - template: .pipelines/onebranch/templates/template-logging-geneva.yml@self
diff --git a/.pipelines/onebranch/pipeline.logging.kusto.pullrequest.yml b/.pipelines/onebranch/pipeline.logging.kusto.pullrequest.yml
deleted file mode 100644
index 1ba418116..000000000
--- a/.pipelines/onebranch/pipeline.logging.kusto.pullrequest.yml
+++ /dev/null
@@ -1,52 +0,0 @@
-#################################################################################
-#                               OneBranch Pipelines                             #
-# This pipeline was created by EasyStart from a sample located at:              #
-#   https://aka.ms/obpipelines/easystart/samples                                #
-# Documentation:  https://aka.ms/obpipelines                                    #
-# Yaml Schema:    https://aka.ms/obpipelines/yaml/schema                        #
-# Retail Tasks:   https://aka.ms/obpipelines/tasks                              #
-# Support:        https://aka.ms/onebranchsup                                   #
-#################################################################################
-
-trigger: none
-pr: none
-
-variables:
-  Cdp_Definition_Build_Count: $[counter('', 0)] # needed for onebranch.pipeline.version task https://aka.ms/obpipelines/versioning
-  LinuxContainerImage: cdpxlinux.azurecr.io/user/aro/ubi8-gotoolset-1.14.12:2021.10.12   # Docker image which is used to build the project https://aka.ms/obpipelines/containers
-  Debian_Frontend: noninteractive
-
-resources:
-  repositories:
-  - repository: templates
-    type: git
-    name: OneBranch.Pipelines/GovernedTemplates
-    ref: refs/heads/main
-  - repository: rhado
-    type: git
-    name: ARO.Pipelines
-  - repository: rpconfig
-    type: git
-    name: RP-Config
-
-extends:
-  template: v2/OneBranch.NonOfficial.CrossPlat.yml@templates # https://aka.ms/obpipelines/templates
-  parameters:
-    globalSdl: # https://aka.ms/obpipelines/sdl
-      # tsa:
-      #  enabled: true # SDL results of non-official builds aren't uploaded to TSA by default.
-      # credscan:
-      #   suppressionsFile: $(Build.SourcesDirectory)\.config\CredScanSuppressions.json
-      disableLegacyManifest: true
-      sbom:
-        enabled: true
-      policheck:
-        break: true # always break the build on policheck issues. You can disable it by setting to 'false'
-      suppression:
-        suppressionFile: $(Build.SourcesDirectory)\.gdn\.gdnsuppress
-        suppressionSet: default
-
-    stages:
-    - stage: LoggingKusto
-      jobs:
-      - template: .pipelines/onebranch/templates/template-logging-kusto.yml@self
diff --git a/.pipelines/onebranch/scripts/geneva-bootstrapper.sh b/.pipelines/onebranch/scripts/geneva-bootstrapper.sh
deleted file mode 100644
index 1810a70f3..000000000
--- a/.pipelines/onebranch/scripts/geneva-bootstrapper.sh
+++ /dev/null
@@ -1,5 +0,0 @@
-SERVICE_GROUP_ROOT=$BUILD_SOURCESDIRECTORY/ARO.Pipelines/ev2/Logging/Geneva-Bootstrapper/ServiceGroupRoot
-
-mkdir $OB_OUTPUTDIRECTORY
-
-cp -r $SERVICE_GROUP_ROOT $OB_OUTPUTDIRECTORY/ServiceGroupRoot/
diff --git a/.pipelines/onebranch/scripts/geneva.sh b/.pipelines/onebranch/scripts/geneva.sh
deleted file mode 100644
index 8e9b24631..000000000
--- a/.pipelines/onebranch/scripts/geneva.sh
+++ /dev/null
@@ -1,5 +0,0 @@
-SERVICE_GROUP_ROOT=$BUILD_SOURCESDIRECTORY/ARO.Pipelines/ev2/Logging/Geneva/ServiceGroupRoot
-
-mkdir $OB_OUTPUTDIRECTORY
-
-cp -r $SERVICE_GROUP_ROOT $OB_OUTPUTDIRECTORY/ServiceGroupRoot/
diff --git a/.pipelines/onebranch/scripts/kusto.sh b/.pipelines/onebranch/scripts/kusto.sh
deleted file mode 100644
index 10c0f565a..000000000
--- a/.pipelines/onebranch/scripts/kusto.sh
+++ /dev/null
@@ -1,5 +0,0 @@
-SERVICE_GROUP_ROOT=$BUILD_SOURCESDIRECTORY/ARO.Pipelines/ev2/Logging/Kusto/ServiceGroupRoot
-
-mkdir $OB_OUTPUTDIRECTORY
-
-cp -r $SERVICE_GROUP_ROOT $OB_OUTPUTDIRECTORY/ServiceGroupRoot/
diff --git a/.pipelines/onebranch/templates/template-logging-geneva-bootstrapper.yml b/.pipelines/onebranch/templates/template-logging-geneva-bootstrapper.yml
deleted file mode 100644
index a4cebd473..000000000
--- a/.pipelines/onebranch/templates/template-logging-geneva-bootstrapper.yml
+++ /dev/null
@@ -1,14 +0,0 @@
-jobs:
-- job: LoggingGenevaBootstrapper
-  timeoutInMinutes: 30
-  pool:
-    type: linux
-
-  variables:   # More settings at https://aka.ms/obpipelines/yaml/jobs
-    ob_outputDirectory: $(Build.SourcesDirectory)/out     # this directory is uploaded to pipeline artifacts, reddog and cloudvault. More info at https://aka.ms/obpipelines/artifacts
-
-  steps:
-  - checkout: rhado
-  - template: ./template-generate-ev2-manifests.yml
-    parameters:
-      generationType: geneva-bootstrapper
diff --git a/.pipelines/onebranch/templates/template-logging-geneva.yml b/.pipelines/onebranch/templates/template-logging-geneva.yml
deleted file mode 100644
index 2bf5c11f1..000000000
--- a/.pipelines/onebranch/templates/template-logging-geneva.yml
+++ /dev/null
@@ -1,14 +0,0 @@
-jobs:
-- job: LoggingGeneva
-  timeoutInMinutes: 30
-  pool:
-    type: linux
-
-  variables:   # More settings at https://aka.ms/obpipelines/yaml/jobs
-    ob_outputDirectory: $(Build.SourcesDirectory)/out     # this directory is uploaded to pipeline artifacts, reddog and cloudvault. More info at https://aka.ms/obpipelines/artifacts
-
-  steps:
-  - checkout: rhado
-  - template: ./template-generate-ev2-manifests.yml
-    parameters:
-      generationType: geneva
diff --git a/.pipelines/onebranch/templates/template-logging-kusto.yml b/.pipelines/onebranch/templates/template-logging-kusto.yml
deleted file mode 100644
index 0220e03be..000000000
--- a/.pipelines/onebranch/templates/template-logging-kusto.yml
+++ /dev/null
@@ -1,14 +0,0 @@
-jobs:
-- job: LoggingKusto
-  timeoutInMinutes: 30
-  pool:
-    type: linux
-
-  variables:   # More settings at https://aka.ms/obpipelines/yaml/jobs
-    ob_outputDirectory: $(Build.SourcesDirectory)/out     # this directory is uploaded to pipeline artifacts, reddog and cloudvault. More info at https://aka.ms/obpipelines/artifacts
-
-  steps:
-  - checkout: rhado
-  - template: ./template-generate-ev2-manifests.yml
-    parameters:
-      generationType: kusto
diff --git a/pkg/operator/README.md b/pkg/operator/README.md
index 40ca5003d..e44291663 100644
--- a/pkg/operator/README.md
+++ b/pkg/operator/README.md
@@ -67,7 +67,7 @@ make admin.kubeconfig
 export KUBECONFIG=$(pwd)/admin.kubeconfig
 oc scale -n openshift-azure-operator deployment/aro-operator-master --replicas=0
 make generate
-go run ./cmd/aro operator master
+go run -tags aro ./cmd/aro operator master
 ```
 
 ### How to run a custom operator image


Test patch:
diff --git a/docs/testing.md b/docs/testing.md
index 4e334f03c..cac756424 100644
--- a/docs/testing.md
+++ b/docs/testing.md
@@ -8,6 +8,14 @@ To run RP unit tests:
 make test-go
 ```
 
+To Run Go tests with coverage:
+
+```bash
+# first navigate to your directory with the code you'd like to see coverage on
+t="/tmp/go-cover.$$.tmp" 
+go test -coverprofile=$t $@ && go tool cover -html=$t && unlink $t
+```
+
 To run python client and `az aro` CLI tests:
 
 ```bash
diff --git a/hack/local-monitor-testing/deploy_MDM_VM.sh b/hack/local-monitor-testing/deploy_MDM_VM.sh
index 07350dd98..783b5040a 100755
--- a/hack/local-monitor-testing/deploy_MDM_VM.sh
+++ b/hack/local-monitor-testing/deploy_MDM_VM.sh
@@ -45,7 +45,7 @@ PUBLICIP=$( az vm list-ip-addresses --name $VMName -g $RESOURCEGROUP | jq -r '.[
 echo "Found IP $PUBLICIP"
 
 scp $BASE/secrets/rp-metrics-int.pem $CLOUDUSER@$PUBLICIP:mdm.pem
-scp $BASE/hack/local-monitor-testing-MACOS/2configureRemote.sh $CLOUDUSER@$PUBLICIP:
+scp $BASE/hack/local-monitor-testing/configureRemote.sh $CLOUDUSER@$PUBLICIP:
 
 ssh $CLOUDUSER@$PUBLICIP "sudo cp mdm.pem /etc/mdm.pem"
 ssh $CLOUDUSER@$PUBLICIP "sudo ./configureRemote.sh"