Files
hostingdelsur.net/scripts/deploy.sh
T
Mauricio López Coria 9aeaeafa3f feat: Awwwards transformation Phases 1-6
Phase 1 — Design System:
- Glassmorphism tokens (--glass-bg, --glass-border, --blur-glass)
- Gradient tokens (--hds-gradient-hero, --hds-gradient-section)
- Motion tokens (--ease-spring, --ease-out-expo)
- .glass-card component class with hover uplift + mouse-tracking glow
- .noise-overlay: SVG feTurbulence texture at 0.025 opacity
- Buttons with spring easing, prefers-reduced-motion support

Phase 2 — Preloader + Hero:
- Preloader.astro: vanilla JS logo fade-in + loading bar + slide-up
- Uses sessionStorage to skip on repeat visits
- Hero.astro: full-bleed 100dvh, GSAP timeline, glass ring decoration
- Parallax floating SVG shapes (sine yoyo animation)
- i18n: hero.scrollDown key

Phase 3 — 'Por qué elegirnos' Bento Grid:
- DifferenceCards.astro: asymmetric 3-column bento grid
- Glass cards with mouse-tracking glow (--mouse-x/--mouse-y)
- GSAP ScrollTrigger stagger reveal (opacity 0→1, y: 40→0)

Phase 4 — Pricing + Process:
- planes.astro: 5 visible + 4 in details accordion
- Empresarial as hero card, price annual only (no toggle)
- ProcessSteps.astro: timeline + ScrollTrigger progress bar

Phase 5 — Global Polish:
- LenisScroll.astro: smooth scroll (duration 1.2, cubic easing)
- GSAP ticker sync, noise overlay in BaseLayout

Phase 6 — Deploy:
- deploy.sh: auto-detects repo path, auto-builds if stale
- Relative paths instead of hardcoded /root/opencode/development
2026-07-01 23:16:36 -03:00

49 lines
1.4 KiB
Bash
Executable File

#!/bin/bash
set -e
SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
REPO="$(dirname "$SCRIPT_DIR")"
DIST="$REPO/dist"
REMOTE="server1"
REMOTE_PATH="/home/hostingd/public_html"
echo "=== Deploy hostingdelsur.net (rsync) ==="
echo "Repo: $REPO"
echo "Dist: $DIST"
echo "Remote: $REMOTE:$REMOTE_PATH"
echo ""
# Build if dist doesn't exist or is stale
if [ ! -d "$DIST" ] || [ "$REPO/package.json" -nt "$DIST" ]; then
echo "→ Building..."
npm run build --prefix "$REPO"
fi
# Copy PHP endpoints into dist (they don't go through Astro)
mkdir -p "$DIST/api"
cp "$REPO/src/forms/contact.php" "$DIST/api/contact.php"
cp "$REPO/src/forms/deploy-webhook.php" "$DIST/api/deploy-webhook.php"
cp "$REPO/src/forms/api-htaccess" "$DIST/api/.htaccess"
# Copy root .htaccess (HTTPS forzado, security headers)
cp "$REPO/scripts/htaccess.conf" "$DIST/.htaccess"
# cPanel recognizes 404.shtml specifically (Server-Side Includes)
# Astro generates 404.html — duplicate as .shtml for cPanel
if [ -f "$DIST/404.html" ]; then
cp "$DIST/404.html" "$DIST/404.shtml"
fi
# rsync with --delete to mirror (preserva mwp/, .well-known/, etc.)
rsync -avz --delete \
--exclude='mwp' \
--exclude='.well-known' \
--exclude='.smtp-credentials.json' \
-e ssh \
"$DIST/" \
"$REMOTE:$REMOTE_PATH/"
echo ""
echo "=== Verificación ==="
ssh $REMOTE "ls -la /home/hostingd/public_html/api/ && echo '---' && ls /home/hostingd/public_html/mwp/ | head -3"