-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathappspec.yml
More file actions
53 lines (47 loc) · 1.28 KB
/
appspec.yml
File metadata and controls
53 lines (47 loc) · 1.28 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
version: 0.0
os: linux
files:
# Copy deployment package files to application directory
# The destination is modified by the GitHub Actions workflow based on environment
- source: /
destination: /opt/trendsearth-api
overwrite: true
# File permissions
permissions:
- object: /opt/trendsearth-api
pattern: "**"
owner: ubuntu
group: ubuntu
mode: 755
- object: /opt/trendsearth-api/scripts
pattern: "**/*.sh"
owner: ubuntu
group: ubuntu
mode: 755
# Lifecycle hooks
hooks:
# Stop existing application before deployment
ApplicationStop:
- location: scripts/codedeploy/application-stop.sh
timeout: 120
runas: root
# Prepare environment for new deployment
BeforeInstall:
- location: scripts/codedeploy/before-install.sh
timeout: 300
runas: root
# Pull Docker images and prepare application
AfterInstall:
- location: scripts/codedeploy/after-install.sh
timeout: 600
runas: root
# Start the application
ApplicationStart:
- location: scripts/codedeploy/application-start.sh
timeout: 600
runas: root
# Validate the deployment
ValidateService:
- location: scripts/codedeploy/validate-service.sh
timeout: 300
runas: root