Welcome! Log In Create A New Profile

Advanced

happy holidays - and a question regarding php source code sharing...

Posted by iberkner 
happy holidays - and a question regarding php source code sharing...
December 24, 2009 12:04PM
Hi All,

Currently we have a single application server, we are in the process of
adding another one. There are 2 options:

1. Copy source code to new server and run code from there

2. Create a linked share to the source code on the new application server so
that code is only updated in one place

Thoughts / suggestions / recommendations?

Thanks
На четвъртък 24 декември 2009 19:01:57 Ilan Berkner написа:
> Hi All,
>
> Currently we have a single application server, we are in the process of
> adding another one. There are 2 options:
>
> 1. Copy source code to new server and run code from there
>
> 2. Create a linked share to the source code on the new application server
> so that code is only updated in one place
>
> Thoughts / suggestions / recommendations?

Use a central repository for app code and a proper deployment script, that
sends the code to all of your servers (and checks that it is really there -
looking at the checksums for instance). I use svn and the post-commit hook do
deploy directories from repos on servers, moreover I use it for config files
and scripts too (firewall, backups, nginx, php ............) since its very
lazy: commit and let a script sync changed stuff to servers and restart
services when needed.

It is better to avoid using networking solutions (NFS and friends) since RAM
is cheap these days and you can fit all of your code either on a hard drive
(if your server has one) or on a ram disk.

Momchil
maybe SVN as a code repository + synchronize it to places.

how this code is updated?

regards,
- Tomasz

2009/12/24 Ilan Berkner <iberkner@gmail.com>:
> Hi All,
>
> Currently we have a single application server, we are in the process of
> adding another one.  There are 2 options:
>
> 1. Copy source code to new server and run code from there
>
> 2. Create a linked share to the source code on the new application server so
> that code is only updated in one place
>
> Thoughts / suggestions / recommendations?
>
> Thanks
For this situation, we set up one server to sync files on a regular basis,
from one server to the other.
Then we modify code only on one server, and it's automatically replicated
each morning and evening.

-Jon

On Thu, Dec 24, 2009 at 12:01 PM, Ilan Berkner <iberkner@gmail.com> wrote:

> Hi All,
>
> Currently we have a single application server, we are in the process of
> adding another one. There are 2 options:
>
> 1. Copy source code to new server and run code from there
>
> 2. Create a linked share to the source code on the new application server
> so that code is only updated in one place
>
> Thoughts / suggestions / recommendations?
>
> Thanks
>
Re: happy holidays - and a question regarding php source code sharing...
December 24, 2009 03:32PM
This is probably the route I'm going to take... seems to be the most
recommended one.

Thanks!

On Thu, Dec 24, 2009 at 12:37 PM, Jonathan Langevin <intel352@gmail.com>wrote:

> For this situation, we set up one server to sync files on a regular basis,
> from one server to the other.
> Then we modify code only on one server, and it's automatically replicated
> each morning and evening.
>
> -Jon
>
>
> On Thu, Dec 24, 2009 at 12:01 PM, Ilan Berkner <iberkner@gmail.com> wrote:
>
>> Hi All,
>>
>> Currently we have a single application server, we are in the process of
>> adding another one. There are 2 options:
>>
>> 1. Copy source code to new server and run code from there
>>
>> 2. Create a linked share to the source code on the new application server
>> so that code is only updated in one place
>>
>> Thoughts / suggestions / recommendations?
>>
>> Thanks
>>
>
>
Re: happy holidays - and a question regarding php source code sharing...
December 24, 2009 03:36PM
i would recommend doing it transactionally. i think rsync can support
this. that way you don't have servers out of sync.

also use --delay-updates

On Thu, Dec 24, 2009 at 12:30 PM, Ilan Berkner <iberkner@gmail.com> wrote:
> This is probably the route I'm going to take... seems to be the most
> recommended one.
>
> Thanks!
>
> On Thu, Dec 24, 2009 at 12:37 PM, Jonathan Langevin <intel352@gmail.com>
> wrote:
>>
>> For this situation, we set up one server to sync files on a regular basis,
>> from one server to the other.
>> Then we modify code only on one server, and it's automatically replicated
>> each morning and evening.
>> -Jon
>>
>> On Thu, Dec 24, 2009 at 12:01 PM, Ilan Berkner <iberkner@gmail.com> wrote:
>>>
>>> Hi All,
>>>
>>> Currently we have a single application server, we are in the process of
>>> adding another one.  There are 2 options:
>>>
>>> 1. Copy source code to new server and run code from there
>>>
>>> 2. Create a linked share to the source code on the new application server
>>> so that code is only updated in one place
>>>
>>> Thoughts / suggestions / recommendations?
>>>
>>> Thanks
>
>
На четвъртък 24 декември 2009 20:36:29 Momchil Ivanov написа:
> На четвъртък 24 декември 2009 19:01:57 Ilan Berkner написа:
> > Hi All,
> >
> > Currently we have a single application server, we are in the process of
> > adding another one. There are 2 options:
> >
> > 1. Copy source code to new server and run code from there
> >
> > 2. Create a linked share to the source code on the new application server
> > so that code is only updated in one place
> >
> > Thoughts / suggestions / recommendations?
>
> Use a central repository for app code and a proper deployment script, that
> sends the code to all of your servers (and checks that it is really there -
> looking at the checksums for instance). I use svn and the post-commit hook
> do deploy directories from repos on servers, moreover I use it for config
> files and scripts too (firewall, backups, nginx, php ............) since
> its very lazy: commit and let a script sync changed stuff to servers and
> restart services when needed.
>
> It is better to avoid using networking solutions (NFS and friends) since
> RAM is cheap these days and you can fit all of your code either on a hard
> drive (if your server has one) or on a ram disk.
>
> Momchil

btw if you are looking for something to hook up to svn, I found these nice
Perl Packages yesterday, they might help you:

http://search.cpan.org/~jpeacock/SVN-Notify-
Mirror-0.038/lib/SVN/Notify/Mirror/Rsync.pm

http://search.cpan.org/~jpeacock/SVN-Notify-
Mirror-0.038/lib/SVN/Notify/Mirror/SSH.pm

http://search.cpan.org/~jpeacock/SVN-Notify-
Mirror-0.038/lib/SVN/Notify/Mirror.pm

http://search.cpan.org/~dwheeler/SVN-Notify-2.79/lib/SVN/Notify.pm
Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 213
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready