fixed post links
This commit is contained in:
17
deploy.sh
17
deploy.sh
@@ -1,6 +1,7 @@
|
||||
#!/bin/bash
|
||||
# Deployment script for Hugo site on LXC container
|
||||
# Run this script after SSH-ing into the container and navigating to the site directory
|
||||
# This script updates the site and restarts the Hugo server systemd service
|
||||
|
||||
set -e # Exit on error
|
||||
|
||||
@@ -10,13 +11,13 @@ echo "Starting deployment at $(date)"
|
||||
echo "Pulling latest changes from git..."
|
||||
git pull
|
||||
|
||||
# Build the site with minification
|
||||
echo "Building site with Hugo..."
|
||||
hugo --minify
|
||||
# Update theme submodule (required for hello-friend-ng theme)
|
||||
echo "Updating theme submodule..."
|
||||
git submodule update --init --recursive
|
||||
|
||||
# Restart Hugo server to pick up changes
|
||||
echo "Restarting Hugo server..."
|
||||
sudo systemctl restart hugo-dustin
|
||||
|
||||
echo "Deployment completed successfully at $(date)"
|
||||
echo "Site updated in ./public directory"
|
||||
|
||||
# Optional: Reload nginx if configuration changed
|
||||
# echo "Reloading nginx..."
|
||||
# sudo systemctl reload nginx
|
||||
echo "Hugo server restarted and changes are live."
|
||||
Reference in New Issue
Block a user