Merge pull request 'Use git directly instead of actions/checkout in workflow' (#4) from master into production
Some checks failed
Deploy / deploy (push) Failing after 0s
Some checks failed
Deploy / deploy (push) Failing after 0s
Reviewed-on: #4
This commit was merged in pull request #4.
This commit is contained in:
@@ -8,10 +8,19 @@ jobs:
|
|||||||
deploy:
|
deploy:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v4
|
- name: Checkout
|
||||||
|
run: |
|
||||||
|
if [ -d /var/lib/act_runner/dusa.cz ]; then
|
||||||
|
cd /var/lib/act_runner/dusa.cz && git fetch origin && git reset --hard origin/production
|
||||||
|
else
|
||||||
|
git clone https://git.dusa.cz/vdusa/dusa.cz.git /var/lib/act_runner/dusa.cz && cd /var/lib/act_runner/dusa.cz && git checkout production
|
||||||
|
fi
|
||||||
|
|
||||||
- run: npm ci
|
- name: Build
|
||||||
- run: npm run build
|
run: |
|
||||||
|
cd /var/lib/act_runner/dusa.cz
|
||||||
|
npm ci
|
||||||
|
npm run build
|
||||||
|
|
||||||
- name: Deploy
|
- name: Deploy
|
||||||
run: rsync -a --delete dist/ /var/www/dusa.cz/
|
run: rsync -a --delete /var/lib/act_runner/dusa.cz/dist/ /var/www/dusa.cz/
|
||||||
|
|||||||
Reference in New Issue
Block a user