Compare commits

..

No commits in common. "master" and "fr/analytics" have entirely different histories.

2 changed files with 15 additions and 20 deletions

View File

@ -6,28 +6,22 @@ on:
- master - master
- dev - dev
env:
ZOLA_VERSION: "0.19.2"
HOST: ${{ secrets.SERVER_IP }}
SSH_USERNAME: ${{ secrets.USERNAME }}
SSH_PRIVATE_KEY: ${{ secrets.DEPLOY_KEY }}
jobs: jobs:
build_and_deploy: build_and_deploy:
runs-on: ubuntu-latest runs-on: ubuntu-latest
steps: steps:
- name: Checkout Repository - name: Checkout Repository
uses: actions/checkout@v4 uses: actions/checkout@v2
- name: Set up Zola - name: Set up Zola
run: | uses: taiki-e/install-action@v2
wget https://github.com/getzola/zola/releases/download/v${ZOLA_VERSION}/zola-v${ZOLA_VERSION}-x86_64-unknown-linux-gnu.tar.gz with:
tar -xvzf *.tar.gz tool: zola@0.17.2
- name: Build Zola Website - name: Build Zola Website
run: | run: |
./zola build zola build
- name: Set Destination Folder if MASTER - name: Set Destination Folder if MASTER
if: ${{ github.ref == 'refs/heads/master' }} if: ${{ github.ref == 'refs/heads/master' }}
@ -37,12 +31,14 @@ jobs:
if: ${{ github.ref == 'refs/heads/dev' }} if: ${{ github.ref == 'refs/heads/dev' }}
run: echo "DEST_FOLDER=/srv/www/cz/filiprojek/dev" >> $GITHUB_ENV run: echo "DEST_FOLDER=/srv/www/cz/filiprojek/dev" >> $GITHUB_ENV
- name: Deploy - name: Deploy to server
run: | uses: AEnterprise/rsync-deploy@v1.0.2
apt update -y && apt-get install -y --no-install-recommends rsync env:
eval "$(ssh-agent -s)" DEPLOY_KEY: ${{ secrets.DEPLOY_KEY }}
ssh-add - <<< "${SSH_PRIVATE_KEY}" ARGS: "-e -c -r --delete"
mkdir -p ~/.ssh/ SERVER_PORT: 22
ssh-keyscan -H ${HOST} >> ~/.ssh/known_hosts FOLDER: "./public/"
rsync -r --delete-after public/* "${SSH_USERNAME}@${HOST}:${{ env.DEST_FOLDER }}" SERVER_IP: ${{ secrets.SERVER_IP }}
USERNAME: ${{ secrets.USERNAME }}
SERVER_DESTINATION: ${{ env.DEST_FOLDER }}

View File

@ -23,7 +23,6 @@
<link rel="stylesheet" href="/content.css"> <link rel="stylesheet" href="/content.css">
<link rel="stylesheet" href="/style.css"> <link rel="stylesheet" href="/style.css">
<link rel="stylesheet" href="/home.css"> <link rel="stylesheet" href="/home.css">
<script defer src="https://analytics.fofrweb.com/script.js" data-website-id="2b326fdd-6c87-4627-b1f1-d0afb40aeef6"></script>
{% block styles %} {% block styles %}
{% endblock styles %} {% endblock styles %}
<script defer data-domain="filiprojek.cz" src="https://analytics.fofrweb.com/js/script.js"></script> <script defer data-domain="filiprojek.cz" src="https://analytics.fofrweb.com/js/script.js"></script>