A
A
AstonMartin2016-11-03 15:44:37
git
AstonMartin, 2016-11-03 15:44:37

How to organize repositories in git?

Good day!
We have two sites: an online store and a crm system for it. Both self-written on yii2, all in one project. Naturally, they are integrated with each other to some extent. DB is one. We use github to store the sources.
Currently, everything is done very primitively:
- dev and production sites are on the same server. shop.com, crm.shop.com, test.shop.com, testcrm.shop.com
- there is one repository and one master
branch in the git - we test on test domains, if everything is fine, then we do a git clone on production domains.
What is inconvenient:
- crm and the store are deployed together.
- development of large parts of the system slows down the deployment of small fixes
I want to do everything right. Tell me, plz, how best to organize? Make different repositories? Do different brunches? Or somehow get by with tags?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
I
Igor Vorotnev, 2016-11-03
@AstonMartin

I would do like this:
1. The feature is done - there is a pull request in development, deployment to the test server (and why do you need a clone if you can git pull origin development)
2. If everything is ok - pull to the master, merge and deploy to production.
The master branch itself in both turnips is prohibited for writing by anyone, only through a pull from development. Merging and deploying should be done by the team leader / responsible for code performance in production.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question