Addying deployment step to pipeline; also added imei and iccid to /network_info
This commit is contained in:
@@ -37,4 +37,39 @@ jobs:
|
||||
run: |
|
||||
echo "Initiating unit tests..."
|
||||
# Busted will automatically find and run files in the 'spec/' directory
|
||||
busted --lua=lua5.1 --verbose spec/
|
||||
busted --lua=lua5.1 --verbose spec/
|
||||
|
||||
deploy-to-device:
|
||||
name: Deploy to Roof Unit
|
||||
needs: test-and-lint
|
||||
runs-on: ubuntu-latest
|
||||
if: github.event_name == 'push' && github.ref == 'refs/heads/master'
|
||||
|
||||
steps:
|
||||
- name: 1. Checkout Repository Code
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: 2. Prepare SSH Environment
|
||||
run: |
|
||||
echo "Preparing the sacred keys and crypto-litany for SSH communion..."
|
||||
mkdir -p ~/.ssh/
|
||||
echo "${{ secrets.ROOF_UNIT_SSH_KEY }}" > ~/.ssh/id_rsa
|
||||
chmod 600 ~/.ssh/id_rsa
|
||||
|
||||
ssh-keyscan -H "${{ secrets.ROOF_UNIT_HOSTNAME }}" >> ~/.ssh/known_hosts
|
||||
|
||||
# Recreate the SSH alias, now including the required legacy crypto options
|
||||
echo "Host roof-unit" > ~/.ssh/config
|
||||
echo " HostName ${{ secrets.ROOF_UNIT_HOSTNAME }}" >> ~/.ssh/config
|
||||
echo " User ${{ secrets.ROOF_UNIT_USER }}" >> ~/.ssh/config
|
||||
echo " IdentityFile ~/.ssh/id_rsa" >> ~/.ssh/config
|
||||
echo " KexAlgorithms +diffie-hellman-group1-sha1" >> ~/.ssh/config
|
||||
echo " HostKeyAlgorithms +ssh-rsa" >> ~/.ssh/config
|
||||
echo " MACs +hmac-sha1" >> ~/.ssh/config
|
||||
echo " PubkeyAcceptedAlgorithms +ssh-rsa" >> ~/.ssh/config
|
||||
|
||||
- name: 3. Execute Deployment Ritual
|
||||
run: |
|
||||
echo "Initiating deployment sequence..."
|
||||
chmod +x ./skyweave_deploy.sh
|
||||
./skyweave_deploy.sh
|
||||
Reference in New Issue
Block a user