This repository has been archived by the owner on Apr 23, 2024. It is now read-only.
-
-
Notifications
You must be signed in to change notification settings - Fork 943
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #451 from mgilangjanuar/staging
Staging
- Loading branch information
Showing
8 changed files
with
139 additions
and
87 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
#!/bin/bash | ||
|
||
set -e | ||
|
||
echo "Node Version: $(node -v)" | ||
echo "Yarn Version: $(yarn -v)" | ||
|
||
if [ ! -f docker/.env ] | ||
then | ||
echo "Generating docker/.env file..." | ||
|
||
ENV="develop" | ||
|
||
echo "Preparing your keys from https://my.telegram.org/" | ||
read -p "Enter your TG_API_ID: " TG_API_ID | ||
read -p "Enter your TG_API_HASH: " TG_API_HASH | ||
|
||
echo "ENV=$ENV" > docker/.env | ||
echo "TG_API_ID=$TG_API_ID" >> docker/.env | ||
echo "TG_API_HASH=$TG_API_HASH" >> docker/.env | ||
fi | ||
|
||
git reset --hard | ||
git clean -f | ||
git pull origin main | ||
|
||
export $(cat docker/.env | xargs) | ||
|
||
echo | ||
echo "Build and deploy to CapRover..." | ||
docker build --build-arg REACT_APP_TG_API_ID=$TG_API_ID --build-arg REACT_APP_TG_API_HASH=$TG_API_HASH -t myapp . | ||
caprover deploy --appName myapp --imageName myapp |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters