Skip to content

Instantly share code, notes, and snippets.

@sudarshansb143
Created July 10, 2023 04:15
Show Gist options
  • Select an option

  • Save sudarshansb143/59ff7a13a41907a829a982b3cdeff39b to your computer and use it in GitHub Desktop.

Select an option

Save sudarshansb143/59ff7a13a41907a829a982b3cdeff39b to your computer and use it in GitHub Desktop.
#!/bin/bash
# Clone or pull the code from the GitHub repository
if [ -d "your-app-folder" ]; then
# If the app folder already exists, perform a git pull to update the code
cd your-app-folder
git pull
else
# If the app folder doesn't exist, clone the repository
git clone your-github-repo-url your-app-folder
cd your-app-folder
fi
# Install dependencies
npm install
# Build the Angular application
npm run aws
# Move the contents of the dist folder to /var/www/html
sudo cp -R dist/* /var/www/html
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment