-
Notifications
You must be signed in to change notification settings - Fork 10
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
1 changed file
with
29 additions
and
0 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
name: Deploy BulletGCSS UI on FPV Sampa (develop) | ||
|
||
on: [push] # tells github to run this on any push to the repository | ||
|
||
jobs: | ||
|
||
deploy: | ||
runs-on: ubuntu-latest | ||
env: | ||
SHA: ${{ github.sha }} | ||
RUNID: ${{ github.run_id }} | ||
if: github.ref == 'refs/heads/develop' # we tell Github to only execute this step if we're on our develop branch | ||
steps: | ||
- name: Deploying UI to FPV Sampa Develop | ||
uses: appleboy/ssh-action@master # An action made to control Linux servers | ||
with: # We set all our secrets here for the action, these won't be shown in the action logs | ||
host: ${{ secrets.HOST }} | ||
username: ${{ secrets.USERNAME }} | ||
password: ${{ secrets.PASSWORD }} | ||
port: ${{ secrets.PORT }} | ||
script: | | ||
cd /home/bulletgcss/ci/BulletGCSS/ | ||
git checkout develop | ||
git pull | ||
rsync -av /home/bulletgcss/ci/BulletGCSS/UI/ /home/bulletgcss/bulletgcss.fpvsampa.com/dev/ | ||
sed -i 's/(UNIQUEID)/${{ env.RUNID }}/g' /home/bulletgcss/bulletgcss.fpvsampa.com/dev/basicui.html | ||
sed -i 's/(VERSION)/${{ env.SHA }}/g' /home/bulletgcss/bulletgcss.fpvsampa.com/dev/basicui.html | ||
sed -i 's/(UNIQUEID)/${{ env.RUNID }}/g' /home/bulletgcss/bulletgcss.fpvsampa.com/dev/uiversion.json | ||