@@ -40,6 +40,8 @@ o11y-readonly local 11111111-1111-1111-1111-111111111111 2022-11-30 08:58:40
4040![ Alt text] ( ../extra/images/purefa_create_api_token.png )
4141</details >
4242
43+ ---
44+
4345# Container Deployment
4446## Container - default - http passing API token with query
4547We build container images and publish them to RedHat quay.io. Here they can be continually scanned for vulnerabilities and updated as soon as a new version are available.
@@ -63,7 +65,7 @@ In this example we will use the default port 9490, set the name as pure-fa-om-ex
63653. **Test the exporter**
6466 Use `curl` to test the exporter returns results.
6567 ```console
66- $ curl -H 'Authorization: Bearer a1b2c3d4-e5f6-1234-5678-a1b2c3d4e5f6 ' -X GET 'http://localhost:9490/metrics/array?endpoint=array01' -silent | grep ^purefa_info
68+ $ curl -H 'Authorization: Bearer 11111111-1111-1111-1111-111111111111 ' -X GET 'http://localhost:9490/metrics/array?endpoint=array01' -silent | grep ^purefa_info
6769 purefa_info{array_name="ARRAY01",os="Purity//FA",system_id="11111111-1111-1111-1111-111111111111",version="6.5.0"} 1
6870 ```
6971
@@ -80,12 +82,12 @@ In this example we will use the default port 9490, set the name as pure-fa-om-ex
8082 # FQDN or IP address of the array
8183 address: 'array01.fqdn.com'
8284 # API token of a user on the array
83- api_token: 'a1b2c3d4-e5f6-1234-5678-a1b2c3d4e5f6 '
85+ api_token: '11111111-1111-1111-1111-111111111111 '
8486
8587 # Example of a second array
8688 array02:
8789 address: 'array02.fqdn.com'
88- api_token: '11111111-1111-1111-1111-111111111111 '
90+ api_token: '22222222-2222-2222-2222-222222222222 '
8991 ```
9092
91932. **Run the container**
@@ -121,10 +123,7 @@ Deploying the binary requires [go](https://go.dev) to compile the code and runni
121123 Clear instructions: can be found here: [https://go.dev/doc/install](https://go.dev/doc/install)
122124
1231252. **Install git**
124-
125- ```console
126- $ yum install git
127- ```
126+ Install git for your specific operating system [https://github.com/git-guides/install-git](https://github.com/git-guides/install-git).
128127
1291283. **Clone git repo**
130129
@@ -141,24 +140,24 @@ Deploying the binary requires [go](https://go.dev) to compile the code and runni
141140
142141## Binary - Default - http passing API token with query
143142
144- 5 . **Binary - Default - http passing API token with query**
143+ 1 . **Binary - Default - http passing API token with query**
145144 ```console
146145 $ ls out/bin
147146 $ .out/bin/pure-fa-openmetrics-exporter
148- Start Pure FlashArray exporter v1.0.10 on 0.0.0.0:9490
147+ Start Pure FlashArray exporter v1.0.11 on 0.0.0.0:9490
149148 ```
150149
151- 6 . **Test the exporter**
150+ 2 . **Test the exporter**
152151 Use `curl` to test the exporter returns results.
153152 ```console
154- $ curl -H 'Authorization: Bearer a1b2c3d4-e5f6-1234-5678-a1b2c3d4e5f6 ' -X GET 'http://localhost:9490/metrics/array?endpoint=array01' -silent | grep ^purefa_info
153+ $ curl -H 'Authorization: Bearer 11111111-1111-1111-1111-111111111111 ' -X GET 'http://localhost:9490/metrics/array?endpoint=array01' -silent | grep ^purefa_info
155154 purefa_info{array_name="ARRAY01",os="Purity//FA",system_id="11111111-1111-1111-1111-111111111111",version="6.5.0"} 1
156155 ```
157156
158157 We expect to return a single line displaying `purefa_info` returning the name, Purity OS, system ID and the Purity version.
159158 You can remove the `' -silent | grep ^purefa_info` from the command to see a list of all results.
160159
161- 7 . **Build it as a service**
160+ 3 . **Build it as a service**
162161
163162 Copy binary to `/usr/bin`
164163 ```console
@@ -191,7 +190,7 @@ Deploying the binary requires [go](https://go.dev) to compile the code and runni
191190 WantedBy=multi-user.target
192191 ```
193192
194- 8 . **Start, enable and test the service**
193+ 4 . **Start, enable and test the service**
195194 Reload the system daemon to read in changes to services
196195
197196 ```console
@@ -214,7 +213,7 @@ Deploying the binary requires [go](https://go.dev) to compile the code and runni
214213Similar steps as basic but we just need to cover a couple of minor changes to running and testing the deployment
215214Follow steps 1-4 and 7-8 of the default binary deployment, but substitute the following steps for executing and testing.
216215
217- 4 . **Create a tokens.yaml file to pass to the exporter**
216+ 1 . **Create a tokens.yaml file to pass to the exporter**
218217
219218 ```console
220219 $ cat /directorypath/tokens.yaml
@@ -223,22 +222,22 @@ Follow steps 1-4 and 7-8 of the default binary deployment, but substitute the fo
223222 # FQDN or IP address of the array
224223 address: 'array01.fqdn.com'
225224 # API token of a user on the array
226- api_token: 'a1b2c3d4-e5f6-1234-5678-a1b2c3d4e5f6 '
225+ api_token: '11111111-1111-1111-1111-111111111111 '
227226
228227 # Example of a second array
229228 array02:
230229 address: 'array02.fqdn.com'
231- api_token: '11111111-1111-1111-1111-111111111111 '
230+ api_token: '22222222-2222-2222-2222-222222222222 '
232231 ```
233232
234- 5 . **Run the binary**
233+ 2 . **Run the binary**
235234 ```console
236235 $ ls out/bin
237236 $ .out/bin/pure-fa-openmetrics-exporter --tokens /directorypath/tokens.yaml
238- Start Pure FlashArray exporter v1.0.10 on 0.0.0.0:9490
237+ Start Pure FlashArray exporter v1.0.11 on 0.0.0.0:9490
239238 ```
240239
241- 6 . **Test the exporter**
240+ 3 . **Test the exporter**
242241 Use `curl` to test the exporter returns results.
243242 ```console
244243 $ curl -X GET 'http://localhost:9490/metrics/array?endpoint=gse-array01' -silent | grep ^purefa_info
@@ -251,13 +250,13 @@ Follow steps 1-4 and 7-8 of the default binary deployment, but substitute the fo
251250
252251Create the certificate and key and pass the exporter the files. There are many different methods of generating certificates which we won't discuss here as each organizations has different standards and requirements.
253252
254- 5 . **Pass the certificate and private key to the exporter**
253+ 1 . **Pass the certificate and private key to the exporter**
255254
256255 ```console
257256 $ pure-fa-om-exporter --port 9490 -c /etc/pki/tls/certs/purefa-ome/pure-ome.crt -k /etc/pki/tls/private/pure-ome.key
258257 ```
259258
260- 6 . **Test the exporter**
259+ 2 . **Test the exporter**
261260
262261 Use `curl` to test the exporter returns results.
263262
@@ -334,11 +333,4 @@ Create the certificate and key and pass the exporter the files. There are many d
334333 Full check using certificate.
335334 ```console
336335 $ curl --cacert pure-ome.crt -H 'Authorization: Bearer 11111111-1111-1111-1111-111111111111' -X GET 'http://pure-ome.fqdn.com:9490/metrics/array?endpoint=array01'
337- ```
338-
339-
340-
341-
342-
343-
344-
336+ ```
0 commit comments