74 lines
1.7 KiB
Markdown
74 lines
1.7 KiB
Markdown
# Pet Picture Queue
|
|
|
|
A web application to manage pet pictures from subscribers. Built with Flask, SQLite, and Jinja2 templates.
|
|
|
|
## Features
|
|
|
|
- Upload pet pictures with subscriber information
|
|
- View all uploaded pictures in a grid layout
|
|
- Mark pictures as posted
|
|
- Modern, responsive UI using Tailwind CSS
|
|
- Click to view full-size images
|
|
- Download original images
|
|
|
|
## Setup
|
|
|
|
### Local Development
|
|
|
|
1. Install dependencies:
|
|
|
|
```bash
|
|
uv pip install -e .
|
|
```
|
|
|
|
2. Run the application:
|
|
|
|
```bash
|
|
python main.py
|
|
```
|
|
|
|
The application will be available at `http://localhost:5000`
|
|
|
|
### Docker Deployment
|
|
|
|
1. Build the Docker image:
|
|
|
|
```bash
|
|
docker build -t pet-picture-queue .
|
|
```
|
|
|
|
2. Run the container:
|
|
|
|
```bash
|
|
docker run -d \
|
|
-p 5000:5000 \
|
|
-v $(pwd)/static/uploads:/app/static/uploads \
|
|
-v $(pwd)/pet_pictures.db:/app/pet_pictures.db \
|
|
--name pet-picture-queue \
|
|
pet-picture-queue
|
|
```
|
|
|
|
The application will be available at `http://localhost:5000`
|
|
|
|
## Usage
|
|
|
|
1. Visit the homepage to see all uploaded pet pictures
|
|
2. Click "Upload New" to add a new pet picture
|
|
3. Fill in the subscriber name and select a picture
|
|
4. View uploaded pictures on the homepage
|
|
5. Click on any picture to view it in full size
|
|
6. Use the "Download Original" button to download the original file
|
|
7. Mark pictures as posted using the "Mark as Posted" button
|
|
|
|
## File Structure
|
|
|
|
- `main.py` - Main Flask application
|
|
- `templates/` - Jinja2 templates
|
|
- `base.html` - Base template with common layout
|
|
- `index.html` - Homepage with picture grid
|
|
- `upload.html` - Upload form
|
|
- `static/uploads/` - Directory for uploaded pictures
|
|
- `pet_pictures.db` - SQLite database (created automatically)
|
|
- `Dockerfile` - Docker configuration
|
|
- `.dockerignore` - Docker build exclusions
|