-
Notifications
You must be signed in to change notification settings - Fork 184
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Mirroring repositories locally to deployer #129
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
0451f0a
to
7baaf1a
Compare
8df9f31
to
520f732
Compare
Quick test, a deploy which takes 75 seconds currently took 28 seconds. Will need to test it at work with large/slow repositories |
Closed
a07e003
to
95f3aec
Compare
e7a023b
to
c398785
Compare
f30ad30
to
f277387
Compare
f277387
to
5310ada
Compare
a5bee0b
to
b6d2faa
Compare
2d24e5b
to
a3d0f5f
Compare
This branch is basically finished, I am using it at work right not to test it, but if anyone else fancies trying it out such as @dancryer please do :) |
…r/vendor/bin:/home/vagrant/.composer/vendor/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games
f014706
to
7d52ffe
Compare
REBELinBLUE
added a commit
that referenced
this pull request
Mar 2, 2016
Mirroring repositories locally to deployer
This is great, today i can see huge improvement in deployment times in "Install Composer Dependencies" step. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Last night I changedDeployer so that it mirrors the git repository in the project directory as mirror.git, then when you deploy it updates that and then does a shallow clone using that as the source.
That way you don't have to continually download the same files everytime you deploy, only files which have updated.
This obviously means the initial deploy is slower, and it uses more space on the server but later deploys are faster and transfer less data
However, I still have to check it out locally to the Deployer server in order to get the commit info.
So I was thinking, instead have mirrors of the repos on the Deployer server; and instead have Deployer tar up the last commit, transfer it to the server and untar it rather than running git on the server
Having a mirror means the rollback is actually possible, and having it on the Deployer server means I can show a list of branches and tags rather than just text fields
So what do you think?
It obviously means the Deployer server will take up more space though
(Obviously getting a specific revision, list of tags/branches and the commit info without cloning the repository is doable with the APIs for gitlab, github and bitbucket but I want to support all types of git repositories if possible)
storage/app
tar
command existsscp
command torsync
so we can get progressUpdate project deletion to remove mirrorsUpdate project editing to remove mirror if repo is changed, could try renaming and changing the remote?Refactor DeployProject, getScript should NOT be uploading filesNot going to do as part of this PR