Skip to content

debug: run server without timeout to see output #5

debug: run server without timeout to see output

debug: run server without timeout to see output #5

name: Test CommandBox
on:
push:
branches:
- feat/docker-local-testing
jobs:
test:
runs-on: ubuntu-latest
steps:
- name: Setup Java
uses: actions/setup-java@v4
with:
distribution: "temurin"
java-version: "11"
- name: Setup CommandBox
uses: Ortus-Solutions/setup-commandbox@v2.0.1
with:
version: "6.2.1"
- name: Test CommandBox
run: |
echo "=== Environment ==="
java -version
echo "PATH: $PATH"
echo -e "\n=== CommandBox Test ==="
which box || echo "box not found"
box version || echo "box version failed"
echo -e "\n=== Simple Server Test ==="
mkdir test
cd test
echo '<cfoutput>Hello World!</cfoutput>' > index.cfm
# Start server with explicit timeout
timeout 60s box server start port=8080 --console || {
echo "Server start failed or timed out"
box server list
}
# Test the server
sleep 10
curl -f http://localhost:8080/ || echo "Server test failed"
# Stop server
box server stop