Skip to content

Commit

Permalink
Update main.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
mr-robertamoah authored Aug 25, 2024
1 parent 7c7ece6 commit 374e539
Showing 1 changed file with 10 additions and 2 deletions.
12 changes: 10 additions & 2 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,17 @@ jobs:
- name: Deploy and build
env:
DIR_PATH: /var/www/TalkTherapy
run:
run: |
aws ssm send-command \
--instance-ids "i-0ceef8e041cbec9af" \
--document-name "AWS-RunShellScript" \
--parameters 'commands:["cd $DIR_PATH", "git pull origin main", "sudo chown -R $USER:$USER $DIR_PATH", "npm run build", "php composer install", "php artisan cache:clear", "sudo chown -R www-data:www-data storage", "sudo chown -R www-data:www-data bootstrap/cache", "sudo service nginx restart"]' \
--parameters 'commands:[\
"cd $DIR_PATH",\
"git pull origin main", \
"sudo chown -R $USER:$USER .", \
"npm run build", "php composer install", \
"php artisan cache:clear", \
"sudo chown -R www-data:www-data storage", \
"sudo chown -R www-data:www-data bootstrap/cache", "sudo service nginx restart" \
]' \
--comment "Deploying application code"

0 comments on commit 374e539

Please sign in to comment.