-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathMakefile
More file actions
141 lines (120 loc) · 3.52 KB
/
Makefile
File metadata and controls
141 lines (120 loc) · 3.52 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
# Adobe Enterprise Automation Makefile
.PHONY: help install test build deploy clean docs monitor
# Default target
help:
@echo "Adobe Enterprise Automation - Available Commands:"
@echo " make install - Install all dependencies"
@echo " make test - Run all tests"
@echo " make build - Build Docker containers"
@echo " make deploy - Deploy the system"
@echo " make monitor - Start monitoring stack"
@echo " make clean - Clean build artifacts"
@echo " make docs - Generate documentation"
# Install dependencies
install:
@echo "Installing Python dependencies..."
pip install -r requirements.txt
@echo "Installing Node.js dependencies..."
npm install
@echo "Installing PowerShell modules..."
pwsh -Command "Install-Module -Name Az,Pester,PSScriptAnalyzer -Force"
# Run tests
test:
@echo "Running PowerShell tests..."
pwsh -Command "Invoke-Pester -Path ./tests -OutputFormat NUnitXml -OutputFile ./test-results-ps.xml"
@echo "Running Python tests..."
python -m pytest python-automation/tests --junitxml=test-results-py.xml
@echo "Running Node.js tests..."
npm test
# Build Docker containers
build:
@echo "Building Docker containers..."
docker-compose build --parallel
# Deploy the system
deploy: build
@echo "Starting deployment..."
docker-compose up -d
@echo "Waiting for services to be ready..."
sleep 10
@echo "Running health checks..."
./scripts/health-check.sh
@echo "Deployment complete!"
# Start monitoring
monitor:
@echo "Starting monitoring stack..."
docker-compose up -d prometheus grafana elasticsearch kibana
@echo "Monitoring available at:"
@echo " Grafana: http://localhost:3000"
@echo " Prometheus: http://localhost:9090"
@echo " Kibana: http://localhost:5601"
# Clean build artifacts
clean:
@echo "Cleaning build artifacts..."
rm -rf node_modules
rm -rf __pycache__
rm -rf .pytest_cache
rm -rf logs/*
rm -rf reports/*
docker-compose down -v
@echo "Clean complete!"
# Generate documentation
docs:
@echo "Generating documentation..."
python scripts/generate_docs.py
@echo "Documentation generated in ./docs/"
# Development environment
dev:
@echo "Starting development environment..."
docker-compose -f docker-compose.dev.yml up
# Production deployment
prod:
@echo "Deploying to production..."
./scripts/deploy-production.sh
# Backup system
backup:
@echo "Creating backup..."
./scripts/backup.sh
# Restore from backup
restore:
@echo "Restoring from backup..."
./scripts/restore.sh
# Security scan
security:
@echo "Running security scan..."
npm audit
pip-audit
pwsh -Command "Invoke-ScriptAnalyzer -Path . -Recurse"
# Performance test
perf:
@echo "Running performance tests..."
python python-automation/tests/performance_test.py
# License optimization
optimize:
@echo "Running license optimization..."
pwsh -File ./creative-cloud/license-optimization/Optimize-Licenses.ps1
# User sync
sync:
@echo "Syncing users..."
pwsh -File ./creative-cloud/user-provisioning/Sync-Users.ps1
# Generate reports
reports:
@echo "Generating reports..."
pwsh -File ./creative-cloud/reporting/Generate-Reports.ps1
python python-automation/reporting.py
# View logs
logs:
docker-compose logs -f
# System status
status:
@echo "System Status:"
@docker-compose ps
@echo ""
@echo "Health Checks:"
@curl -s http://localhost:8000/health | jq '.'
# Quick start
quickstart: install build deploy monitor
@echo "Adobe Automation System is ready!"
@echo "Access points:"
@echo " API: http://localhost:8000"
@echo " Grafana: http://localhost:3000"
@echo " Kibana: http://localhost:5601"