-
Notifications
You must be signed in to change notification settings - Fork 0
Home
Atoui Abderahman Yakoub edited this page Sep 15, 2024
·
8 revisions
This project is a Django application integrated with HubSpot. It includes a CI/CD pipeline using GitHub Actions to ensure code quality and automate testing.
- Python 3.12 or higher
- Docker
- Git
-
Clone the Repository:
git clone https://github.com/ATOUIYakoub/Django-hubspot-integration.git cd crm_analytics
-
Create a Virtual Environment:
python -m venv venv source venv/bin/activate # On Windows use `venv\Scripts\activate`
-
Install Dependencies:
pip install --upgrade pip pip install -r requirements.txt
-
Run Migrations:
python manage.py migrate
-
Run the Development Server:
python manage.py runserver
-
Access the Application:
- Open your browser and go to
http://localhost:8000
.
- Open your browser and go to
This section provides instructions on how to use the application.
- Open your browser and go to
http://localhost:8000
.
- Lead Management: View, create, update, and delete leads.
- Integration with HubSpot: Sync leads with HubSpot.
-
View Leads:
- Navigate to the leads page to view all leads.
-
Update a Lead:
- Click on a lead to update its details.
-
Sync with HubSpot:
- Use the provided API endpoints to sync leads with HubSpot.
This project uses GitHub Actions for Continuous Integration (CI) and Continuous Deployment (CD).
The CI/CD pipeline is defined in the .github/workflows/ci.yml
file.
--health-timeout 5s
--health-retries 5
env:
DATABASE_URL: postgres://postgres:postgres@localhost:5432/test_db
steps:
- name: Checkout code
uses: actions/checkout@v2
- name: Set up Python
uses: actions/setup-python@v2
with:
python-version: '3.12'
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -r requirements.txt
- name: Run tests
run: |
python manage.py migrate
python manage.py test
```markdown
#### Contribution Guidelines
# Contribution Guidelines
## How to Contribute
We welcome contributions from the community. Here are the steps to contribute:
1. **Fork the Repository**:
- Click the "Fork" button at the top right of the repository page.
2. **Clone Your Fork**:
```sh
git clone https://github.com/ATOUIYakoub/Django-hubspot-integration.git
cd your-fork
```
3. **Create a Branch**:
```sh
git checkout -b feature/your-feature-name
```
4. **Make Your Changes**:
- Implement your feature or fix.
5. **Commit Your Changes**:
```sh
git add .
git commit -m "Add your commit message"
```
6. **Push to Your Fork**:
```sh
git push origin feature/your-feature-name
```
7. **Create a Pull Request**:
- Go to the original repository and click on "New Pull Request".
- Select your branch and submit the pull request.
## Coding Standards
- Follow PEP 8 guidelines for Python code.
- Write clear and concise commit messages.
- Include tests for new features and bug fixes.
## Reporting Issues
- Use the "Issues" tab to report bugs or request features.
- Provide detailed information to help us understand and reproduce the issue.
# FAQs
## How do I set up the project locally?
Follow the [Setup Instructions](#setup-instructions) to set up the project on your local machine.
## How do I contribute to the project?
Follow the [Contribution Guidelines](#contribution-guidelines) to contribute to the project.
## How do I run the tests?
Run the following command to execute the tests:
```sh
python manage.py test