Agnostic Automation Center - Integration Quickstart
Connect your test automation project to the platform and run your first test in minutes.
Prerequisitesโ
- Docker Hub account with a pushed automation image
- Platform account at automation.keinar.com
Step 1: Prepare Your Projectโ
Your automation container must follow the Container Protocol. At minimum, you need:
1.1 Create entrypoint.shโ
#!/bin/sh
FOLDER_PATH=$1
echo "๐ Starting Agnostic Automation..."
# Handle environment enforcement
if [ -f .env ]; then
echo "๐งน Removing local .env to enforce Worker configuration..."
rm .env
fi
# Execution Logic
if [ -z "$FOLDER_PATH" ] || [ "$FOLDER_PATH" = "all" ]; then
echo "โถ๏ธ Running ALL tests against $BASE_URL..."
npx playwright test
else
echo "โถ๏ธ Running tests in: $FOLDER_PATH against $BASE_URL..."
npx playwright test "$FOLDER_PATH"
fi
# Report Generation
echo "๐ Generating Allure Report..."
npx allure generate allure-results --clean -o allure-report
1.2 Create Dockerfileโ
FROM mcr.microsoft.com/playwright:v1.40.0-jammy
WORKDIR /app
COPY package*.json ./
RUN npm ci
RUN npm install -g allure-commandline
COPY . .
RUN chmod +x /app/entrypoint.sh
ENTRYPOINT ["/bin/sh", "/app/entrypoint.sh"]
CMD ["all"]
1.3 Configure Your Frameworkโ
Ensure your test framework reads BASE_URL from environment:
playwright.config.ts:
export default defineConfig({
use: {
baseURL: process.env.BASE_URL || 'http://localhost:3000',
},
reporter: [
['html', { outputFolder: 'playwright-report' }],
['allure-playwright', { outputFolder: 'allure-results' }],
],
});
Step 2: Build & Push Your Imageโ
# Build your image
docker build -t your-dockerhub-user/my-automation:latest .
# Push to Docker Hub
docker push your-dockerhub-user/my-automation:latest
Step 3: Register on the Platformโ
- Go to https://automation.keinar.com
- Click Sign Up and create your account
- Your organization is created automatically (you're the admin)
Step 4: Generate an API Keyโ
For CI/CD integration, generate an API Key (no username/password required):
- Login to https://automation.keinar.com
- Go to Settings โ Profile
- Scroll to API Access section
- Click Generate New Key
- Give it a name (e.g., "GitHub Actions")
- Copy the key immediately - it's only shown once!
Store the API key securely in your CI/CD secrets (e.g., AAC_API_KEY).
Step 5: Execute Testsโ
Option A: Via Dashboardโ
- Login to https://automation.keinar.com
- Click "Run New Test"
- Enter your Docker image name
- Select environment and folder
- Click Run
Option B: Via APIโ
curl -X POST "https://api.automation.keinar.com/api/executions" \
-H "x-api-key: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"image": "your-dockerhub-user/my-automation:latest",
"command": "npx playwright test",
"environment": "staging",
"baseUrl": "https://staging.automation.keinar.com",
"folder": "tests/e2e"
}'
Option C: CI/CD Integration (GitHub Actions)โ
name: Run E2E Tests
on: [push]
jobs:
test:
runs-on: ubuntu-latest
steps:
- name: Trigger Tests
run: |
curl -X POST https://api.automation.keinar.com/api/executions \
-H "Content-Type: application/json" \
-H "x-api-key: ${{ secrets.AAC_API_KEY }}" \
-d '{
"image": "your-dockerhub-user/my-automation:latest",
"folder": "tests",
"baseUrl": "${{ secrets.TARGET_URL }}"
}'
Step 6: Monitor & Review Resultsโ
- Live Dashboard - Watch tests execute in real-time
- WebSocket Logs - See console output streaming live
- AI Analysis - When tests fail, AI analyzes root cause automatically
- Reports - Access HTML and Allure reports at:
https://api.automation.keinar.com/reports/{organizationId}/{taskId}/
Environment Variables Referenceโ
Your container receives these environment variables:
| Variable | Description |
|---|---|
BASE_URL | Target application URL (from your config or platform default) |
TASK_ID | Unique execution identifier |
CI | Always true in platform execution |
FRAMEWORK_AGNOSTIC | Always true |
Troubleshootingโ
Container Fails to Startโ
- Verify
entrypoint.shexists at/app/entrypoint.sh - Check file has executable permissions (
chmod +x) - Ensure Unix line endings (not Windows CRLF)
Tests Not Foundโ
- Verify folder path matches your project structure
- Check that test files are included in Docker image
- Review logs for path-related errors
Reports Not Visibleโ
- Reports must be written to
/app/<report-folder> - Wait for execution to complete (status:
PASSEDorFAILED) - Check that report generation step succeeded in logs
Next Stepsโ
- Docker Setup Guide - Detailed container protocol
- API Reference - Complete API documentation
- Authentication API - Token management