debug #339
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Integration | |
| on: [push, pull_request, workflow_dispatch] | |
| jobs: | |
| test: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Copy .env file | |
| working-directory: .devcontainer | |
| run: cp .env.example ../.env | |
| - name: Start dev container and test | |
| uses: devcontainers/ci@v0.3 | |
| with: | |
| configFile: .devcontainer/devcontainer.json | |
| runCmd: | | |
| composer install --no-interaction --no-progress --prefer-dist --no-autoloader --no-scripts | |
| echo "Checking database status..." | |
| docker ps | |
| docker logs database || echo "No database container logs available" | |
| timeout=60 | |
| while [ $timeout -gt 0 ] && ! mysqladmin ping -h"database" --silent; do | |
| echo "Waiting for database... ($timeout seconds remaining)" | |
| sleep 1 | |
| timeout=$((timeout - 1)) | |
| done | |
| if [ $timeout -eq 0 ]; then | |
| echo "Database failed to start within 60 seconds" | |
| docker logs database || echo "No database container logs available" | |
| exit 1 | |
| fi | |
| wp core install --url=http://localhost:8080 --title=Bedrock --admin_user=admin --admin_password=admin --admin_email=admin@example.com --skip-email --allow-root | |
| - name: Verify installation | |
| run: | | |
| curl -s http://localhost:8080 | grep "<title>Bedrock" |