Fix Jeakyll preview cleanup step
Jekyll cleanup / jekyll_cleanup (pull_request) Failing after 6s Details
Jekyll / jekyll (pull_request) Successful in 20s Details

Signed-off-by: Benoit Donneaux <benoit@leastauthority.com>
This commit is contained in:
bEn 2024-05-24 14:19:45 +02:00
parent 5eb87a6bf5
commit 52b555d925
1 changed files with 6 additions and 1 deletions

View File

@ -18,6 +18,12 @@ jobs:
actions: read
contents: read
steps:
- name: Install requirements
id: install_requirements
run: |
apt-get -q update
apt-get -q install -y lftp
apt-get -q clean
- name: Cleanup Jeyll preview
id: cleanup_preview
run: |
@ -25,6 +31,5 @@ jobs:
echo "${{ secrets.WWW_DEPLOY_KEY }}" > ~/.ssh/id_ed25519
chmod 600 ~/.ssh/id_ed25519
# Delete preview context from the remote site
sudo apt install -y lftp
echo -e "set sftp:connect-program ssh -a -x -o StrictHostKeyChecking=no; rm -r -f ${WEB_ROOT}${WEB_CONTEXT}\nbye" \
| lftp sftp://${WEB_USER}:unused@${WEB_DOMAN}