Skip to content

Commit

Permalink
update : folder path
Browse files Browse the repository at this point in the history
  • Loading branch information
mofahsan committed Feb 3, 2025
1 parent 132befb commit c3db0bd
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions .github/workflows/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ jobs:
ssh-keyscan -H ${{ secrets.SSH_HOST }} >> ~/.ssh/known_hosts
ssh -i ./key.pem ${{ secrets.SSH_USERNAME }}@${{ secrets.SSH_HOST }} -T <<EOF
REPO_DIR=~/ONDC-automation-framework/automation-mock-service
REPO_DIR=~/ONDC-automation-framework-staging/automation-mock-service
echo "Removing existing repository directory if exists"
rm -rf \$REPO_DIR
echo "Cloning repository from staging branch"
Expand All @@ -49,7 +49,7 @@ jobs:
run: |
echo "Writing secrets to .env file"
ssh -i ./key.pem ${{ secrets.SSH_USERNAME }}@${{ secrets.SSH_HOST }} <<EOF
REPO_DIR=~/ONDC-automation-framework/automation-mock-service
REPO_DIR=~/ONDC-automation-framework-staging/automation-mock-service
echo "Writing environment variables to .env file"
echo "REDIS_USERNAME=${{ secrets.REDIS_USERNAME }}" >> \$REPO_DIR/.env
echo "REDIS_HOST=${{ secrets.REDIS_HOST }}" >> \$REPO_DIR/.env
Expand All @@ -63,7 +63,7 @@ jobs:
- name: Verify .env and docker-compose.yml files
run: |
ssh -i ./key.pem ${{ secrets.SSH_USERNAME }}@${{ secrets.SSH_HOST }} <<EOF
REPO_DIR=~/ONDC-automation-framework/automation-mock-service
REPO_DIR=~/ONDC-automation-framework-staging/automation-mock-service
# Check if .env and docker-compose.yml files exist
if [ ! -f \$REPO_DIR/.env ]; then
echo ".env file not found in \$REPO_DIR!"
Expand All @@ -80,7 +80,7 @@ jobs:
run: |
echo "Deploying with Docker Compose"
ssh -i ./key.pem ${{ secrets.SSH_USERNAME }}@${{ secrets.SSH_HOST }} <<EOF
REPO_DIR=~/ONDC-automation-framework/automation-mock-service
REPO_DIR=~/ONDC-automation-framework-staging/automation-mock-service
cd \$REPO_DIR
# Ensure the .env and docker-compose.yml files exist
Expand Down

0 comments on commit c3db0bd

Please sign in to comment.