Make sure your system meets the following requirements:
- Ruby version: 3.2.2
- Rails version: 6.1.7.4
- Node version:16.20.1
- Yarn version: 1.22.19
- PostgresSQL version: 15.1
- Database: PostgreSQL (or the database specified in
config/database.yml
) - Node.js and Yarn (for JavaScript dependencies)
Follow these steps to set up the application:
During this setup if it ask for password please provide it. It would mainly ask administrative privilage to run elastic search.
-
Copy and paste the below curl command.
curl -fsSL https://raw.githubusercontent.com/satrujit-kreeti/Professional-Social-Platform-Rails_Final-Project/main/setup.sh | bash
If curl command is not working or showing some peer to peer connection error please try to run this command again.
-
To run the dev server
bin/dev
Follow these steps to set up the application:
-
Clone the repository to your local machine:
git clone https://github.com/satrujit-kreeti/Professional-Social-Platform-Rails_Final-Project.git cd Professional-Social-Platform-Rails_Final-Project
-
Install required dependency
bundle install
-
Install JavaScript dependencies:
yarn install
-
Create the database:
rails db:create
-
Run database migration:
rails db:migrate
-
Start Elasticsearch:
systemctl restart elasticsearch
-
Seed the database with sample data:
rails db:seed
-
Create Index for data in elastic search:
rails c User.import
To start the Rails server, use the following command:
rails s
Role | Password | |
---|---|---|
Admin | [email protected] |
Super@71 |
User | [email protected] |
Super@71 |
User | [email protected] |
Super@71 |
User | [email protected] |
Super@71 |
For other data follow seeds.rb file