Skip to content

Commit d648d3f

Browse files
committed
add % to cpu usage
1 parent 7fb6e5a commit d648d3f

File tree

13 files changed

+13
-13
lines changed

13 files changed

+13
-13
lines changed

examples/templates/aws-ecs-container/main.tf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -128,7 +128,7 @@ resource "coder_agent" "coder" {
128128
script = <<-EOT
129129
#!/bin/bash
130130
set -e
131-
top -bn1 | grep "Cpu(s)" | awk '{print $2 + $4}'
131+
top -bn1 | grep "Cpu(s)" | awk '{print $2 + $4 "%"}'
132132
EOT
133133
}
134134
metadata {

examples/templates/aws-linux/main.tf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -180,7 +180,7 @@ resource "coder_agent" "main" {
180180
script = <<-EOT
181181
#!/bin/bash
182182
set -e
183-
top -bn1 | grep "Cpu(s)" | awk '{print $2 + $4}'
183+
top -bn1 | grep "Cpu(s)" | awk '{print $2 + $4 "%"}'
184184
EOT
185185
}
186186
metadata {

examples/templates/azure-linux/main.tf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -238,7 +238,7 @@ resource "coder_agent" "main" {
238238
script = <<-EOT
239239
#!/bin/bash
240240
set -e
241-
top -bn1 | grep "Cpu(s)" | awk '{print $2 + $4}'
241+
top -bn1 | grep "Cpu(s)" | awk '{print $2 + $4 "%"}'
242242
EOT
243243
}
244244
metadata {

examples/templates/do-linux/main.tf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -255,7 +255,7 @@ resource "coder_agent" "main" {
255255
script = <<-EOT
256256
#!/bin/bash
257257
set -e
258-
top -bn1 | grep "Cpu(s)" | awk '{print $2 + $4}'
258+
top -bn1 | grep "Cpu(s)" | awk '{print $2 + $4 "%"}'
259259
EOT
260260
}
261261
metadata {

examples/templates/docker-code-server/main.tf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ resource "coder_agent" "main" {
4949
script = <<-EOT
5050
#!/bin/bash
5151
set -e
52-
top -bn1 | grep "Cpu(s)" | awk '{print $2 + $4}'
52+
top -bn1 | grep "Cpu(s)" | awk '{print $2 + $4 "%"}'
5353
EOT
5454
}
5555
metadata {

examples/templates/docker-image-builds/main.tf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ resource "coder_agent" "main" {
4242
script = <<-EOT
4343
#!/bin/bash
4444
set -e
45-
top -bn1 | grep "Cpu(s)" | awk '{print $2 + $4}'
45+
top -bn1 | grep "Cpu(s)" | awk '{print $2 + $4 "%"}'
4646
EOT
4747
}
4848
metadata {

examples/templates/docker-with-dotfiles/main.tf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ resource "coder_agent" "main" {
7272
script = <<-EOT
7373
#!/bin/bash
7474
set -e
75-
top -bn1 | grep "Cpu(s)" | awk '{print $2 + $4}'
75+
top -bn1 | grep "Cpu(s)" | awk '{print $2 + $4 "%"}'
7676
EOT
7777
}
7878
metadata {

examples/templates/docker/main.tf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ resource "coder_agent" "main" {
5656
script = <<-EOT
5757
#!/bin/bash
5858
set -e
59-
top -bn1 | grep "Cpu(s)" | awk '{print $2 + $4}'
59+
top -bn1 | grep "Cpu(s)" | awk '{print $2 + $4 "%"}'
6060
EOT
6161
}
6262
metadata {

examples/templates/fly-docker-image/main.tf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -299,7 +299,7 @@ resource "coder_agent" "main" {
299299
script = <<-EOT
300300
#!/bin/bash
301301
set -e
302-
top -bn1 | grep "Cpu(s)" | awk '{print $2 + $4}'
302+
top -bn1 | grep "Cpu(s)" | awk '{print $2 + $4 "%"}'
303303
EOT
304304
}
305305
metadata {

examples/templates/gcp-linux/main.tf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -97,7 +97,7 @@ resource "coder_agent" "main" {
9797
script = <<-EOT
9898
#!/bin/bash
9999
set -e
100-
top -bn1 | grep "Cpu(s)" | awk '{print $2 + $4}'
100+
top -bn1 | grep "Cpu(s)" | awk '{print $2 + $4 "%"}'
101101
EOT
102102
}
103103
metadata {

0 commit comments

Comments
 (0)