✨ Build PWA
This commit is contained in:
parent
275b17b117
commit
324469816d
@ -32,3 +32,19 @@ jobs:
|
|||||||
# On regarde si les fichiers sont là
|
# On regarde si les fichiers sont là
|
||||||
- name: List files
|
- name: List files
|
||||||
run: ls -l ./dist
|
run: ls -l ./dist
|
||||||
|
# On installe Rsync
|
||||||
|
- name: Install Rsync
|
||||||
|
run: sudo apt-get install rsync -y
|
||||||
|
# On ajoute la clé SSH
|
||||||
|
- name: Add SSH key
|
||||||
|
run: echo "$DEPLOY_KEY" > $HOME/.ssh/test_private_key && chmod 600 $HOME/.ssh/test_private_key
|
||||||
|
# On utilise Rsync pour copier les fichiers (On fait en sorte de supprimer les ancien fichiers)
|
||||||
|
- name: Deploy files
|
||||||
|
run: rsync -av -e "ssh -i $HOME/.ssh/test_private_key" --delete ./dist/ $DEPLOY_URL
|
||||||
|
# On supprime la clé SSH
|
||||||
|
- name: Remove SSH key
|
||||||
|
run: rm $HOME/.ssh/test_private_key
|
||||||
|
|
||||||
|
variables:
|
||||||
|
DEPLOY_URL: ${{ secrets.DEPLOY_URL }}
|
||||||
|
DEPLOY_KEY: ${{ secrets.DEPLOY_KEY }}
|
||||||
|
Loading…
Reference in New Issue
Block a user