From d73b4e5ecace3bc96ebd8926ee04e2a6db0942f9 Mon Sep 17 00:00:00 2001 From: FragginWagon Date: Wed, 28 Jan 2026 04:37:50 +0000 Subject: [PATCH] =?UTF-8?q?=F0=9F=9B=A0=EF=B8=8F=20Update=20Docker=20confi?= =?UTF-8?q?guration=20and=20documentation=20for=20Pokedex=20Online?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- code/websites/pokedex.online/Dockerfile | 30 +++++ code/websites/pokedex.online/README.md | 112 ++++++++++++++++++ .../pokedex.online/docker-compose.yml | 10 ++ 3 files changed, 152 insertions(+) create mode 100644 code/websites/pokedex.online/Dockerfile create mode 100644 code/websites/pokedex.online/README.md create mode 100644 code/websites/pokedex.online/docker-compose.yml diff --git a/code/websites/pokedex.online/Dockerfile b/code/websites/pokedex.online/Dockerfile new file mode 100644 index 0000000..bfb7d73 --- /dev/null +++ b/code/websites/pokedex.online/Dockerfile @@ -0,0 +1,30 @@ +# Build stage +FROM node:20-alpine AS build + +WORKDIR /app + +# Copy package files +COPY package*.json ./ + +# Install dependencies +RUN npm ci + +# Copy source code +COPY . . + +# Build the app +RUN npm run build + +# Production stage +FROM nginx:alpine + +# Copy built assets from build stage +COPY --from=build /app/dist /usr/share/nginx/html + +# Copy nginx configuration if needed +# COPY nginx.conf /etc/nginx/conf.d/default.conf + +# Expose both HTTP and HTTPS ports +EXPOSE 80 443 + +CMD ["nginx", "-g", "daemon off;"] diff --git a/code/websites/pokedex.online/README.md b/code/websites/pokedex.online/README.md new file mode 100644 index 0000000..6956403 --- /dev/null +++ b/code/websites/pokedex.online/README.md @@ -0,0 +1,112 @@ +# Pokedex Online + +A modern Vue 3 web application for exploring PokΓ©mon data, tracking collections, and managing your PokΓ©mon journey. + +## πŸš€ Local Development + +### Prerequisites + +- Node.js 20+ +- npm or yarn + +### Quick Start + +```bash +# Install dependencies +npm install + +# Start development server +npm run dev + +# Open browser to http://localhost:5173 +``` + +### Build for Production + +```bash +# Build the app +npm run build + +# Preview production build +npm run preview +``` + +## 🐳 Docker Deployment + +### Build and Run Locally + +```bash +# Build the image +docker build -t pokedex-online . + +# Run the container +docker run -d -p 8080:80 --name pokedex-online pokedex-online + +# View in browser +open http://localhost:8080 +``` + +### Using Docker Compose + +```bash +# Start the service +docker-compose up -d + +# Stop the service +docker-compose down + +# View logs +docker-compose logs -f +``` + +## πŸ“¦ Automated Deployment + +Deploy to Synology NAS using the deployment script: + +```bash +# Deploy to internal network (10.0.0.81) +npm run deploy:pokedex:internal + +# Deploy to external network (home.gregrjacobs.com) +npm run deploy:pokedex:external + +# Deploy with custom ports +npm run deploy:pokedex -- --target internal --port 8080 --ssl-port 8443 +``` + +## πŸ“ Project Structure + +``` +pokedex.online/ +β”œβ”€β”€ src/ +β”‚ β”œβ”€β”€ main.js # Application entry point +β”‚ β”œβ”€β”€ App.vue # Root component +β”‚ β”œβ”€β”€ style.css # Global styles +β”‚ └── components/ +β”‚ └── Pokeball.vue # Pokeball component +β”œβ”€β”€ apps/ # Subdomain apps (app.pokedex.online) +β”œβ”€β”€ index.html # HTML entry point +β”œβ”€β”€ vite.config.js # Vite configuration +β”œβ”€β”€ package.json # Dependencies +β”œβ”€β”€ Dockerfile # Multi-stage Docker build +└── docker-compose.yml # Docker Compose config +``` + +## πŸ› οΈ Tech Stack + +- **Vue 3** - Progressive JavaScript framework +- **Vite** - Next generation frontend tooling +- **Docker** - Containerization +- **nginx** - Web server + +## πŸ”— Related Apps + +- **apps/** - Additional apps accessible at app.pokedex.online + +## πŸ“ Development Notes + +This project uses: +- Vue 3 Composition API with `