mirror of
https://github.com/coder/registry.git
synced 2026-06-05 14:08:15 +00:00
Compare commits
11 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 1dbdad101d | |||
| 2ecdbddf8f | |||
| fa8147e1bb | |||
| 4aa4448d81 | |||
| 3829a20756 | |||
| 15a16f279b | |||
| a6aca54728 | |||
| b2c1ff0770 | |||
| 41e86b8715 | |||
| 4f22907ed4 | |||
| 65ccc6ff48 |
@@ -1,6 +1,7 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
set -o errexit
|
#set -o errexit
|
||||||
set -o pipefail
|
set -o pipefail
|
||||||
|
set -x
|
||||||
|
|
||||||
port=${1:-3284}
|
port=${1:-3284}
|
||||||
|
|
||||||
@@ -10,18 +11,30 @@ port=${1:-3284}
|
|||||||
agentapi_started=false
|
agentapi_started=false
|
||||||
|
|
||||||
echo "Waiting for agentapi server to start on port $port..."
|
echo "Waiting for agentapi server to start on port $port..."
|
||||||
for i in $(seq 1 150); do
|
start=$(date +%s)
|
||||||
for j in $(seq 1 3); do
|
while true; do
|
||||||
sleep 0.1
|
if curl -f "http://localhost:$port/status"; then
|
||||||
if curl -fs -o /dev/null "http://localhost:$port/status"; then
|
agentapi_started=true
|
||||||
echo "agentapi response received ($j/3)"
|
elapsed=$(($(date +%s) - start))
|
||||||
|
echo "$(date): agentapi server started after $elapsed seconds"
|
||||||
|
break
|
||||||
else
|
else
|
||||||
echo "agentapi server not responding ($i/15)"
|
echo "$(date): agentapi server not responding"
|
||||||
continue 2
|
agentapi_pid=$(pidof agentapi)
|
||||||
|
if [ -z "$agentapi_pid" ]; then
|
||||||
|
echo "$(date): agentapi process not found"
|
||||||
|
else
|
||||||
|
echo "$(date): agentapi pid: $agentapi_pid"
|
||||||
|
fi
|
||||||
|
boundary_pid=$(pidof boundary)
|
||||||
|
if [ -z "$boundary_pid" ]; then
|
||||||
|
echo "$(date): boundary process not found"
|
||||||
|
else
|
||||||
|
echo "$(date): boundary pid: $boundary_pid"
|
||||||
|
fi
|
||||||
|
sleep 1
|
||||||
|
continue
|
||||||
fi
|
fi
|
||||||
done
|
|
||||||
agentapi_started=true
|
|
||||||
break
|
|
||||||
done
|
done
|
||||||
|
|
||||||
if [ "$agentapi_started" != "true" ]; then
|
if [ "$agentapi_started" != "true" ]; then
|
||||||
|
|||||||
@@ -1,6 +1,7 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
set -o errexit
|
set -o errexit
|
||||||
set -o pipefail
|
set -o pipefail
|
||||||
|
set -x
|
||||||
|
|
||||||
use_prompt=${1:-false}
|
use_prompt=${1:-false}
|
||||||
port=${2:-3284}
|
port=${2:-3284}
|
||||||
|
|||||||
@@ -338,8 +338,8 @@ locals {
|
|||||||
}
|
}
|
||||||
|
|
||||||
module "agentapi" {
|
module "agentapi" {
|
||||||
source = "registry.coder.com/coder/agentapi/coder"
|
source = "github.com/coder/registry//registry/coder/modules/agentapi?ref=cj%2Fagentapi%2Fdebug"
|
||||||
version = "2.0.0"
|
# version = "2.0.0"
|
||||||
|
|
||||||
agent_id = var.agent_id
|
agent_id = var.agent_id
|
||||||
web_app_slug = local.app_slug
|
web_app_slug = local.app_slug
|
||||||
|
|||||||
@@ -1,6 +1,7 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
|
|
||||||
set -euo pipefail
|
set -euo pipefail
|
||||||
|
set -x
|
||||||
|
|
||||||
BOLD='\033[0;1m'
|
BOLD='\033[0;1m'
|
||||||
|
|
||||||
|
|||||||
@@ -1,6 +1,7 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
|
|
||||||
set -euo pipefail
|
set -euo pipefail
|
||||||
|
set -x
|
||||||
|
|
||||||
command_exists() {
|
command_exists() {
|
||||||
command -v "$1" > /dev/null 2>&1
|
command -v "$1" > /dev/null 2>&1
|
||||||
|
|||||||
Reference in New Issue
Block a user