rename the app to scoffer...everywhere
This commit is contained in:
@@ -1,4 +1,4 @@
|
|||||||
# Docker Setup for Recipe Management App
|
# Docker Setup for Scoffer
|
||||||
|
|
||||||
## Full Stack Containerized Setup
|
## Full Stack Containerized Setup
|
||||||
|
|
||||||
@@ -32,9 +32,7 @@ Create a `.env` file in the project root with the following variables:
|
|||||||
|
|
||||||
```bash
|
```bash
|
||||||
# MongoDB Configuration
|
# MongoDB Configuration
|
||||||
MONGODB_USERNAME=admin
|
MONGODB_DATABASE=scoffer
|
||||||
MONGODB_PASSWORD=password123
|
|
||||||
MONGODB_DATABASE=recipe-management
|
|
||||||
|
|
||||||
# JWT Secret for Backend Authentication
|
# JWT Secret for Backend Authentication
|
||||||
JWT_SECRET=your-super-secret-jwt-key-change-this-in-production
|
JWT_SECRET=your-super-secret-jwt-key-change-this-in-production
|
||||||
|
|||||||
16
README.md
16
README.md
@@ -1,4 +1,4 @@
|
|||||||
# Recipe Management App
|
# Scoffer
|
||||||
|
|
||||||
A full-stack recipe management application that allows users to browse recipes, select them for their menu, and automatically generate aggregated shopping lists.
|
A full-stack recipe management application that allows users to browse recipes, select them for their menu, and automatically generate aggregated shopping lists.
|
||||||
|
|
||||||
@@ -30,7 +30,7 @@ A full-stack recipe management application that allows users to browse recipes,
|
|||||||
## Project Structure
|
## Project Structure
|
||||||
|
|
||||||
```
|
```
|
||||||
recipe-management-app/
|
scoffer/
|
||||||
├── backend/
|
├── backend/
|
||||||
│ ├── models/ # Database models
|
│ ├── models/ # Database models
|
||||||
│ ├── routes/ # API routes
|
│ ├── routes/ # API routes
|
||||||
@@ -48,11 +48,11 @@ recipe-management-app/
|
|||||||
└── README.md
|
└── README.md
|
||||||
```
|
```
|
||||||
|
|
||||||
## Setup Instructions
|
## Installation and Setup
|
||||||
|
|
||||||
### Prerequisites
|
### Prerequisites
|
||||||
- Node.js (v14 or higher)
|
- Node.js (v16 or higher)
|
||||||
- MongoDB (running locally or MongoDB Atlas)
|
- MongoDB (local installation or MongoDB Atlas)
|
||||||
- npm or yarn
|
- npm or yarn
|
||||||
|
|
||||||
### Backend Setup
|
### Backend Setup
|
||||||
@@ -70,11 +70,9 @@ recipe-management-app/
|
|||||||
3. Create a `.env` file with your configuration using a copy of the `.envtemplate` file (for example):
|
3. Create a `.env` file with your configuration using a copy of the `.envtemplate` file (for example):
|
||||||
```
|
```
|
||||||
PORT=5000
|
PORT=5000
|
||||||
MONGODB_URI=mongodb://localhost:27017/recipe-management
|
MONGODB_HOST=localhost
|
||||||
MONGODB_USERNAME=admin
|
|
||||||
MONGODB_PASSWORD=password123
|
|
||||||
MONGODB_PORT=27017
|
MONGODB_PORT=27017
|
||||||
MONGODB_DATABASE=recipe-management
|
MONGODB_DATABASE=scoffer
|
||||||
JWT_SECRET=your-super-secret-jwt-key-change-this-in-production
|
JWT_SECRET=your-super-secret-jwt-key-change-this-in-production
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
PORT=5000 #port for the app
|
PORT=5000 #port for the app
|
||||||
MONGODB_HOST=localhost #host for the mongodb connection (localhost for local and mongodb for docker)
|
MONGODB_HOST=localhost #host for the mongodb connection (localhost for local and mongodb for docker)
|
||||||
MONGODB_PORT=27017 #port for the mongodb connection
|
MONGODB_PORT=27017 #port for the mongodb connection
|
||||||
MONGODB_DATABASE=recipe-management #database for the mongodb connection
|
MONGODB_DATABASE=scoffer #database for the mongodb connection
|
||||||
JWT_SECRET=your-super-secret-jwt-key-change-this-in-production #jwt secret for the app
|
JWT_SECRET=your-super-secret-jwt-key-change-this-in-production #jwt secret for the app
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
{
|
{
|
||||||
"name": "recipe-backend",
|
"name": "scoffer-backend",
|
||||||
"version": "1.0.0",
|
"version": "1.0.0",
|
||||||
"description": "Backend for recipe management app",
|
"description": "Backend for Scoffer recipe management app",
|
||||||
"main": "server.js",
|
"main": "server.js",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"start": "node server.js",
|
"start": "node server.js",
|
||||||
|
|||||||
@@ -152,7 +152,7 @@ const sampleRecipes = [
|
|||||||
async function seedDatabase() {
|
async function seedDatabase() {
|
||||||
try {
|
try {
|
||||||
// Connect to MongoDB
|
// Connect to MongoDB
|
||||||
await mongoose.connect(process.env.MONGODB_URI || 'mongodb://localhost:27017/recipe-management');
|
await mongoose.connect(process.env.MONGODB_URI || 'mongodb://localhost:27017/scoffer');
|
||||||
console.log('Connected to MongoDB');
|
console.log('Connected to MongoDB');
|
||||||
|
|
||||||
// Clear existing recipes
|
// Clear existing recipes
|
||||||
|
|||||||
@@ -13,7 +13,7 @@ app.use(express.json());
|
|||||||
// MongoDB connection
|
// MongoDB connection
|
||||||
const MONGODB_HOST = process.env.MONGODB_HOST || 'mongodb';
|
const MONGODB_HOST = process.env.MONGODB_HOST || 'mongodb';
|
||||||
const MONGODB_PORT = process.env.MONGODB_PORT || '27017';
|
const MONGODB_PORT = process.env.MONGODB_PORT || '27017';
|
||||||
const MONGODB_DATABASE = process.env.MONGODB_DATABASE || 'recipe-management';
|
const MONGODB_DATABASE = process.env.MONGODB_DATABASE || 'scoffer';
|
||||||
|
|
||||||
const MONGODB_URI = `mongodb://${MONGODB_HOST}:${MONGODB_PORT}/${MONGODB_DATABASE}`;
|
const MONGODB_URI = `mongodb://${MONGODB_HOST}:${MONGODB_PORT}/${MONGODB_DATABASE}`;
|
||||||
|
|
||||||
@@ -39,7 +39,7 @@ app.use('/api/users', require('./routes/users'));
|
|||||||
app.use('/api/selections', require('./routes/selections'));
|
app.use('/api/selections', require('./routes/selections'));
|
||||||
|
|
||||||
app.get('/', (req, res) => {
|
app.get('/', (req, res) => {
|
||||||
res.json({ message: 'Recipe Management API is running!' });
|
res.json({ message: 'Scoffer API is running!' });
|
||||||
});
|
});
|
||||||
|
|
||||||
app.listen(PORT, () => {
|
app.listen(PORT, () => {
|
||||||
|
|||||||
@@ -4,7 +4,7 @@ services:
|
|||||||
# MongoDB Database
|
# MongoDB Database
|
||||||
mongodb:
|
mongodb:
|
||||||
image: mongo:7.0
|
image: mongo:7.0
|
||||||
container_name: recipe-management-mongodb
|
container_name: scoffer-mongodb
|
||||||
restart: unless-stopped
|
restart: unless-stopped
|
||||||
ports:
|
ports:
|
||||||
- "27017:27017"
|
- "27017:27017"
|
||||||
@@ -25,13 +25,13 @@ services:
|
|||||||
build:
|
build:
|
||||||
context: ./backend
|
context: ./backend
|
||||||
dockerfile: Dockerfile
|
dockerfile: Dockerfile
|
||||||
container_name: recipe-management-backend
|
container_name: scoffer-backend
|
||||||
restart: unless-stopped
|
restart: unless-stopped
|
||||||
environment:
|
environment:
|
||||||
- PORT=5000
|
- PORT=5000
|
||||||
- MONGODB_HOST=mongodb
|
- MONGODB_HOST=mongodb
|
||||||
- MONGODB_PORT=27017
|
- MONGODB_PORT=27017
|
||||||
- MONGODB_DATABASE=recipe-management
|
- MONGODB_DATABASE=scoffer
|
||||||
- JWT_SECRET=${JWT_SECRET}
|
- JWT_SECRET=${JWT_SECRET}
|
||||||
ports:
|
ports:
|
||||||
- "5000:5000"
|
- "5000:5000"
|
||||||
@@ -49,7 +49,7 @@ services:
|
|||||||
build:
|
build:
|
||||||
context: ./frontend
|
context: ./frontend
|
||||||
dockerfile: Dockerfile
|
dockerfile: Dockerfile
|
||||||
container_name: recipe-management-frontend
|
container_name: scoffer-frontend
|
||||||
restart: unless-stopped
|
restart: unless-stopped
|
||||||
ports:
|
ports:
|
||||||
- "3000:80"
|
- "3000:80"
|
||||||
@@ -63,7 +63,7 @@ services:
|
|||||||
# Optional: MongoDB Express for database management
|
# Optional: MongoDB Express for database management
|
||||||
mongo-express:
|
mongo-express:
|
||||||
image: mongo-express:1.0.0
|
image: mongo-express:1.0.0
|
||||||
container_name: recipe-management-mongo-express
|
container_name: scoffer-mongo-express
|
||||||
restart: unless-stopped
|
restart: unless-stopped
|
||||||
ports:
|
ports:
|
||||||
- "8081:8081"
|
- "8081:8081"
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
# MongoDB Configuration for Docker Compose (no authentication)
|
# MongoDB Configuration for Docker Compose (no authentication)
|
||||||
MONGODB_HOST=mongodb
|
MONGODB_HOST=mongodb
|
||||||
MONGODB_PORT=27017
|
MONGODB_PORT=27017
|
||||||
MONGODB_DATABASE=recipe-management
|
MONGODB_DATABASE=scoffer
|
||||||
|
|
||||||
# JWT Secret for Backend
|
# JWT Secret for Backend
|
||||||
JWT_SECRET=your-super-secret-jwt-key-change-this-in-production
|
JWT_SECRET=your-super-secret-jwt-key-change-this-in-production
|
||||||
@@ -1,5 +1,5 @@
|
|||||||
{
|
{
|
||||||
"name": "recipe-frontend",
|
"name": "scoffer-frontend",
|
||||||
"version": "0.1.0",
|
"version": "0.1.0",
|
||||||
"private": true,
|
"private": true,
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
|
|||||||
@@ -27,7 +27,7 @@ const Dashboard: React.FC = () => {
|
|||||||
<header className="dashboard-header">
|
<header className="dashboard-header">
|
||||||
<div className="header-content">
|
<div className="header-content">
|
||||||
<div className="header-left">
|
<div className="header-left">
|
||||||
<h1 className="app-title">Recipe Manager</h1>
|
<h1 className="app-title">Scoffer</h1>
|
||||||
<p className="welcome-text">Welcome back, {user?.username}!</p>
|
<p className="welcome-text">Welcome back, {user?.username}!</p>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|||||||
@@ -37,7 +37,7 @@ const Login: React.FC = () => {
|
|||||||
<div className="auth-card">
|
<div className="auth-card">
|
||||||
<div className="auth-header">
|
<div className="auth-header">
|
||||||
<h1>Welcome Back</h1>
|
<h1>Welcome Back</h1>
|
||||||
<p>Sign in to your recipe management account</p>
|
<p>Sign in to your scoffer account</p>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<form onSubmit={handleSubmit} className="auth-form">
|
<form onSubmit={handleSubmit} className="auth-form">
|
||||||
|
|||||||
Reference in New Issue
Block a user