Skip to content

Commit 581e858

Browse files
update readme
1 parent 7859ee8 commit 581e858

File tree

2 files changed

+39
-2
lines changed

2 files changed

+39
-2
lines changed

.DS_Store

0 Bytes
Binary file not shown.

README.md

Lines changed: 39 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ This web application facilitates connections between restaurants looking to prom
99
## Tech Stack
1010

1111
- **Backend**: PHP
12-
- **Database**: MySQL (MariaDB)
12+
- **Database**: MySQL (MariaDB) / AWS RDS
1313
- **Frontend**: HTML, CSS, JavaScript
1414
- **Server**: Nginx
1515
- **Containerization**: Docker & Docker Compose
@@ -86,6 +86,28 @@ This web application facilitates connections between restaurants looking to prom
8686
└── php.ini # PHP configuration
8787
```
8888

89+
## Database Configuration
90+
91+
The application can use either a local Docker-based MariaDB instance or AWS RDS:
92+
93+
### Local Docker Database (Development)
94+
95+
- Database: MariaDB
96+
- Host: `db` (Docker service name)
97+
- Username: `mktuser`
98+
- Password: `mkpass`
99+
- Database name: `marketplace`
100+
101+
### AWS RDS (Production)
102+
103+
- Database: MariaDB/MySQL on AWS RDS
104+
- Host: `ourawork.ckb40aqwiavq.us-east-1.rds.amazonaws.com` (or your RDS endpoint)
105+
- Username: `admin` (or your RDS username)
106+
- Password: Your RDS password
107+
- Database name: `marketplace`
108+
109+
The database connection is configured in `html/includes/db_connect.php`. To switch between environments, update the connection parameters in this file.
110+
89111
## Database Schema
90112

91113
The application uses the following database tables:
@@ -385,10 +407,25 @@ If experiencing "413 Request Entity Too Large" errors:
385407
If experiencing database connection problems:
386408

387409
- Verify database credentials in db_connect.php
388-
- Check if the database container is running
410+
- Check if the database container is running (for local development)
389411
- Ensure the schema has been imported
390412
- **If you get an error about the 'role' column not accepting 'admin', see the Seeding section above for how to alter the table.**
391413

414+
#### AWS RDS Specific Issues
415+
416+
- Make sure your server's IP address is allowed in the RDS security group
417+
- Verify that the RDS instance is publicly accessible
418+
- Check that the required database exists on RDS:
419+
```sql
420+
CREATE DATABASE marketplace;
421+
```
422+
- Import the schema and seed data:
423+
```sh
424+
mariadb -h your-rds-endpoint.amazonaws.com -u admin -p marketplace < db/schema.sql
425+
mariadb -h your-rds-endpoint.amazonaws.com -u admin -p marketplace < db/enhanced_seed.sql
426+
mariadb -h your-rds-endpoint.amazonaws.com -u admin -p marketplace < db/admin_setup.sql
427+
```
428+
392429
### Instagram Integration Issues
393430

394431
If experiencing Instagram connection problems:

0 commit comments

Comments
 (0)