D
D
Denis2019-06-01 20:31:05
1C-Bitrix
Denis, 2019-06-01 20:31:05

How to properly store site data on Git hub?

There is a large working site, on Bitrix, how to make sure that all data is stored on github?
Let's download the entire site to your PC, upload it to the repository. Now it turns out we have one site on the host and one locally on the PC that is synchronized with the github. More like a copy of it. Do edits on the test, check if everything is ok, commit and transfer to the host? Or what is better .. or probably easier)) and how to be with the database? Well, what else can be the nuances?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
A
Alexey Bespalov, 2019-06-06
@FreeArcher

Options 2:
1. Correct - put in the git only folders in which local development is being carried out, and if the old-fashioned template is in bitrix/tamplates/ then put it.
Do it on a production server.
Well, respectively, clone these folders on the test server and on the machine where development is underway.
2. Wrong - but allows you to upload updates to local and test computers. This is also created by git on the production server and the entire www directory is placed there. A lot, but then it just clones all the sources for itself and updates are uploaded.
The only thing you need to properly configure gitignore (I will be interested in throwing off my own).
Well, the base is just backed up only the base and deployed without files.
The question is how to do it the first time?
The first time you simply deploy a full backup of the site on your machine.
Then everything from the www folder is removed.
And it is uploaded again, but from git.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question