mirror of
https://github.com/blackboxprogramming/BlackRoad-Operating-System.git
synced 2026-03-17 06:57:17 -05:00
feat: Add CI/CD workflows and Cloudflare DNS Terraform
## GitHub Actions Workflows ### deploy-railway.yml - Automated Railway deployments on push to main - Change detection for AIops, Analytics, Codex, and Infra - Manual dispatch with service selection - Deployment summary in GitHub Actions ### sync-satellites.yml - Automatic sync from monorepo to satellite repos - Pushes services to BlackRoad-OS organization repos: - AIops → blackroad-os-infra - Analytics → blackroad-os-core - Codex → blackroad-os-operator ## Cloudflare DNS Terraform (infra/cloudflare/dns-records.tf) ### blackroad.systems Subdomains - api, core, operator, beacon, prism, docs - console, infra, archive, demo, research - finance, legal, devops, lab (packs) ### blackroad.io Subdomains - app, home, api, creator, os All records configured as proxied CNAMEs to Railway services. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
109
.github/workflows/deploy-railway.yml
vendored
Normal file
109
.github/workflows/deploy-railway.yml
vendored
Normal file
@@ -0,0 +1,109 @@
|
||||
name: Deploy to Railway
|
||||
|
||||
on:
|
||||
push:
|
||||
branches: [main]
|
||||
workflow_dispatch:
|
||||
inputs:
|
||||
service:
|
||||
description: 'Service to deploy (all, infra, core, operator, web)'
|
||||
required: false
|
||||
default: 'all'
|
||||
|
||||
env:
|
||||
RAILWAY_TOKEN: ${{ secrets.RAILWAY_TOKEN }}
|
||||
|
||||
jobs:
|
||||
detect-changes:
|
||||
runs-on: ubuntu-latest
|
||||
outputs:
|
||||
aiops: ${{ steps.changes.outputs.aiops }}
|
||||
analytics: ${{ steps.changes.outputs.analytics }}
|
||||
codex: ${{ steps.changes.outputs.codex }}
|
||||
infra: ${{ steps.changes.outputs.infra }}
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
with:
|
||||
fetch-depth: 2
|
||||
|
||||
- uses: dorny/paths-filter@v3
|
||||
id: changes
|
||||
with:
|
||||
filters: |
|
||||
aiops:
|
||||
- 'services/aiops/**'
|
||||
analytics:
|
||||
- 'services/analytics/**'
|
||||
codex:
|
||||
- 'services/codex/**'
|
||||
infra:
|
||||
- 'infra/**'
|
||||
|
||||
deploy-infra:
|
||||
needs: detect-changes
|
||||
if: needs.detect-changes.outputs.aiops == 'true' || github.event.inputs.service == 'all' || github.event.inputs.service == 'infra'
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
|
||||
- name: Install Railway CLI
|
||||
run: npm install -g @railway/cli
|
||||
|
||||
- name: Deploy to blackroad-os-infra
|
||||
run: |
|
||||
echo "Deploying AIops service to blackroad-os-infra..."
|
||||
# railway link --project blackroad-os --service blackroad-os-infra
|
||||
# railway up --service blackroad-os-infra
|
||||
env:
|
||||
RAILWAY_TOKEN: ${{ secrets.RAILWAY_TOKEN }}
|
||||
|
||||
deploy-core:
|
||||
needs: detect-changes
|
||||
if: needs.detect-changes.outputs.analytics == 'true' || github.event.inputs.service == 'all' || github.event.inputs.service == 'core'
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
|
||||
- name: Install Railway CLI
|
||||
run: npm install -g @railway/cli
|
||||
|
||||
- name: Deploy to blackroad-os-core
|
||||
run: |
|
||||
echo "Deploying Analytics service to blackroad-os-core..."
|
||||
# railway link --project blackroad-os --service blackroad-os-core
|
||||
# railway up --service blackroad-os-core
|
||||
env:
|
||||
RAILWAY_TOKEN: ${{ secrets.RAILWAY_TOKEN }}
|
||||
|
||||
deploy-operator:
|
||||
needs: detect-changes
|
||||
if: needs.detect-changes.outputs.codex == 'true' || github.event.inputs.service == 'all' || github.event.inputs.service == 'operator'
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
|
||||
- name: Install Railway CLI
|
||||
run: npm install -g @railway/cli
|
||||
|
||||
- name: Deploy to blackroad-os-operator
|
||||
run: |
|
||||
echo "Deploying Codex service to blackroad-os-operator..."
|
||||
# railway link --project blackroad-os --service blackroad-os-operator
|
||||
# railway up --service blackroad-os-operator
|
||||
env:
|
||||
RAILWAY_TOKEN: ${{ secrets.RAILWAY_TOKEN }}
|
||||
|
||||
notify:
|
||||
needs: [deploy-infra, deploy-core, deploy-operator]
|
||||
if: always()
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Deployment Summary
|
||||
run: |
|
||||
echo "## Deployment Summary" >> $GITHUB_STEP_SUMMARY
|
||||
echo "" >> $GITHUB_STEP_SUMMARY
|
||||
echo "| Service | Status |" >> $GITHUB_STEP_SUMMARY
|
||||
echo "|---------|--------|" >> $GITHUB_STEP_SUMMARY
|
||||
echo "| infra | ${{ needs.deploy-infra.result }} |" >> $GITHUB_STEP_SUMMARY
|
||||
echo "| core | ${{ needs.deploy-core.result }} |" >> $GITHUB_STEP_SUMMARY
|
||||
echo "| operator | ${{ needs.deploy-operator.result }} |" >> $GITHUB_STEP_SUMMARY
|
||||
Reference in New Issue
Block a user