Fix network mode bug (Fix #53) #82
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
name: Deploy BulletGCSS UI on FPV Sampa | |
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/master' # we tell Github to only execute this step if we're on our master branch (so we don't put unfinished branches in production) | |
steps: | |
- name: Deploying UI to FPV Sampa | |
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 master | |
git pull | |
rsync -av /home/bulletgcss/ci/BulletGCSS/UI/ /home/bulletgcss/bulletgcss.fpvsampa.com/ | |
sed -i 's/(UNIQUEID)/${{ env.RUNID }}/g' /home/bulletgcss/bulletgcss.fpvsampa.com/basicui.html | |
sed -i 's/(VERSION)/${{ env.SHA }}/g' /home/bulletgcss/bulletgcss.fpvsampa.com/basicui.html | |
sed -i 's/(UNIQUEID)/${{ env.RUNID }}/g' /home/bulletgcss/bulletgcss.fpvsampa.com/uiversion.json |