This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| # Quick fix - restore working names without fancy quotes | |
| sudo tee /opt/kittycam/web/index.html > /dev/null << 'HTMLEOF' | |
| <!DOCTYPE html> | |
| <html lang="en"> | |
| <head> | |
| <meta charset="UTF-8"> | |
| <meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=no, viewport-fit=cover"> | |
| <meta name="theme-color" content="#0a0a0a"> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| # KittyCam Trading Cards Update Script | |
| set -e | |
| cd /opt/kittycam/web | |
| echo "🎴 Downloading trading cards..." | |
| curl -L "https://tmpfiles.org/dl/28383140/trading-cards-bundle.zip" -o /tmp/tc.zip | |
| echo "📦 Extracting..." | |
| sudo unzip -o /tmp/tc.zip -d /opt/kittycam/web/ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <!DOCTYPE html> | |
| <html lang="en"> | |
| <head> | |
| <meta charset="UTF-8"> | |
| <meta name="viewport" content="width=device-width, initial-scale=1.0"> | |
| <title>Pet Trading Cards</title> | |
| <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/swiper@11/swiper-bundle.min.css"> | |
| <style> | |
| * { margin: 0; padding: 0; box-sizing: border-box; } | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| # Kevin & Todd Cam - Themes + Name Fix Update | |
| # Run on Pi: bash upgrade-themes-v2.sh | |
| echo "🐱 Upgrading with themes + name fix..." | |
| # Update the index.html | |
| sudo tee /opt/kittycam/web/index.html > /dev/null << 'HTMLEOF' | |
| <!DOCTYPE html> | |
| <html lang="en"> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| # Kevin & Todd Cam - Themes v3 (HD in settings, fixed colors) | |
| # Run on Pi: bash upgrade-themes-v3.sh | |
| echo "🐱 Upgrading..." | |
| sudo tee /opt/kittycam/web/index.html > /dev/null << 'HTMLEOF' | |
| <!DOCTYPE html> | |
| <html lang="en"> | |
| <head> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| # Kevin & Todd Cam - Gacha System | |
| # Run on Pi: bash upgrade-gacha.sh | |
| echo "🎰 Installing gacha system..." | |
| # Install Flask if needed | |
| pip3 install flask --quiet 2>/dev/null || sudo pip3 install flask --quiet | |
| # Create gacha server |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| # Kevin & Todd Cam - Gacha UI | |
| # Run on Pi AFTER upgrade-gacha.sh | |
| echo "🎴 Installing gacha UI..." | |
| sudo tee /opt/kittycam/web/trading-cards.html > /dev/null << 'HTMLEOF' | |
| <!DOCTYPE html> | |
| <html lang="en"> | |
| <head> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| # Kevin & Todd Cam - Daily Viewing Report | |
| # Run on Pi | |
| echo "📊 Installing daily viewing report..." | |
| # Update gacha server to include view tracking | |
| sudo tee /opt/kittycam/gacha_server.py > /dev/null << 'PYEOF' | |
| #!/usr/bin/env python3 | |
| from flask import Flask, jsonify, request |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| # Add view tracking to the main page | |
| # Run AFTER upgrade-daily-report.sh | |
| echo "📊 Adding view tracking to frontend..." | |
| # Add view logging to the index.html init function | |
| sudo sed -i 's|async function init(){|async function init(){\n // Log view\n fetch("/api/log-view", {method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({page:"live"})}).catch(()=>{});|' /opt/kittycam/web/index.html | |
| echo "✅ View tracking added!" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| server { | |
| listen 8080; | |
| server_name _; | |
| root /opt/kittycam/web; | |
| index index.html; | |
| proxy_buffering off; | |
| proxy_request_buffering off; | |
| location = /auth { |