Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/laksharmaa/pixelpost

Gen-AI driven community platform where users can create AI generated Images and share them
https://github.com/laksharmaa/pixelpost

auth0 azure blob-storage cosmosdb express nodejs openai-api react

Last synced: 27 days ago
JSON representation

Gen-AI driven community platform where users can create AI generated Images and share them

Awesome Lists containing this project

README

        

# PixelPost
![Thumbnail](https://github.com/user-attachments/assets/b63814ec-3055-4bd1-8464-336617d47be1)
image

> PixelPost is a Community Platform where users can create, share, and explore AI-generated images. The application uses React for the client-side, Node.js and Express for the server-side, Azure CosmosDB for data storage, and Azure Blob Storage for image storage. Authentication and authorization are handled using Auth0.

## Features

> - AI-generated image creation using OpenAI's APIπŸ‘Ύ
> - User authentication with Auth0πŸ”‘
> - Personalized user profilesπŸ‘€
> - Like and comment on postsπŸ‘πŸ»
> - Dark mode supportπŸŒ—
> - Image storage and management with Azure Blob StorageπŸ“·
> - Community showcase for sharing and exploring imagesπŸ–Ό
> - Responsive UI for a seamless experience on all devicesπŸ“²

## Tech Stack
### Client-Side
**React**: For building the user interface
**Tailwind CSS**: For styling
**Auth0**: For authentication and authorization
### Server-Side
**Node.js**: For server-side JavaScript
**Express**: For building the API
**CosmosDB**: For data storage
**Azure Blob Storage**: For image storage
**Auth0**: For authentication and authorization

## Setup
### Prerequisites
- Node.js (v14 or higher)
- npm (v6 or higher)
- Azure account (for Blob Storage)
- Auth0 account
- CosmosDB account

### Installation
1. Clone the repository:
```
git clone https://github.com/your-username/pixelpost.git
cd pixelpost
```
2. Install dependencies for both client and server:
```# Install client dependencies
cd client
npm install

# Install server dependencies
cd ../server
npm install
```
## Environment Variables
> Create a .env file in both the client and server directories and add the following environment variables:
### *CLIENT*
```
VITE_AUTH0_DOMAIN=your-auth0-domain
VITE_AUTH0_CLIENT_ID=your-auth0-client-id
VITE_CLIENT_SECRET=your-auth0-client-secret
VITE_AUTH0_AUDIENCE=your-auth0-audience
VITE_BASE_URL=http://localhost:8080
```

### *SERVER*
```
AUTH0_DOMAIN=your-auth0-domain
AUTH0_AUDIENCE=your-auth0-audience
AZURE_BLOB_CONNECTION_STRING=your-azure-blob-connection-string
AZURE_CONTAINER_NAME=your-azure-container-name
COSMOSDB_URL=your-cosmosdb-url
OPENAI_API_KEY=your-openai-api-key
```

## Run the Application
*Client*
```
cd client
npm run dev
```
*Server*
```
cd server
npm start
```
## Folder Structure
```
pixelpost/
β”œβ”€β”€ client/
β”‚ β”œβ”€β”€ .env
β”‚ β”œβ”€β”€ .eslintrc.cjs
β”‚ β”œβ”€β”€ .gitignore
β”‚ β”œβ”€β”€ index.html
β”‚ β”œβ”€β”€ package.json
β”‚ β”œβ”€β”€ postcss.config.js
β”‚ β”œβ”€β”€ public/
β”‚ β”œβ”€β”€ README.md
β”‚ β”œβ”€β”€ src/
β”‚ β”‚ β”œβ”€β”€ App.jsx
β”‚ β”‚ β”œβ”€β”€ assets/
β”‚ β”‚ β”œβ”€β”€ components/
β”‚ β”‚ β”œβ”€β”€ constant/
β”‚ β”‚ β”œβ”€β”€ context/
β”‚ β”‚ β”œβ”€β”€ index.css
β”‚ β”‚ β”œβ”€β”€ main.jsx
β”‚ β”‚ β”œβ”€β”€ Pages/
β”‚ β”‚ β”œβ”€β”€ utils/
β”‚ β”œβ”€β”€ tailwind.config.js
β”‚ β”œβ”€β”€ vercel.json
β”‚ └── vite.config.js
β”œβ”€β”€ server/
β”‚ β”œβ”€β”€ .env
β”‚ β”œβ”€β”€ .gitignore
β”‚ β”œβ”€β”€ index.js
β”‚ β”œβ”€β”€ mongodb/
β”‚ β”‚ β”œβ”€β”€ connect.js
β”‚ β”‚ β”œβ”€β”€ models/
β”‚ β”œβ”€β”€ package.json
β”‚ β”œβ”€β”€ routes/
β”‚ β”‚ β”œβ”€β”€ dalleRoutes.js
β”‚ β”‚ β”œβ”€β”€ postRoutes.js
β”‚ β”œβ”€β”€ services/
β”‚ β”‚ β”œβ”€β”€ azureBlobService.js
β”‚ β”œβ”€β”€ utils/
β”‚ β”‚ β”œβ”€β”€ loginOrCreateUser.js
β”‚ └── vercel.json
```

## Contributing
> Contributions are welcome! Please submit a pull request for any changes. Lets make it *Creative*😎

# **Built with sleepless nightsβ˜•**