{"thread":{"id":"39009","subject":"How to send a warning message from git hosting server?","startedAt":"2015-04-05T15:04:43Z","lastAt":"2015-04-15T10:28:52Z","messageCount":5,"participants":["Yi, EungJun","Junio C Hamano","Tony Finch","Sitaram Chamarty"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"259025","messageId":"CAFT+Tg-Gwr9EemFv88+=Ao21dGYe73D-CDiT4mXU4kuP-niOSw@mail.gmail.com","threadId":"39009","inReplyTo":null,"subject":"How to send a warning message from git hosting server?","fromName":"Yi, EungJun","fromEmail":"semtlenori@gmail.com","sentAt":"2015-04-05T15:04:43Z","receivedAt":"2015-04-05T15:04:43Z","isPatch":false,"sender":{"key":"semtlenori@gmail.com","avatar":"https://gravatar.com/avatar/8363435d2badb3450df0dd7c4ec2113f6e1d62c44dd3cf7dfe83c5a389b8a9bf?d=mp&s=160"},"body":"Hello. I am serving a git hosting service for my company.\n\nSometimes I want to send a warning message to users who use my\nservice; e.g. the service will be shutdown tomorrow for a while\ntemporary.\n\nI know it is possible to a remote message by hooks or HTTP body if an\nerror occured. But it seems that there is no hooks for git-fetch and\ngit does not print HTTP body if there is no error.\n\nI want a way to response a remote message when a client send any kind\nof request. Is it possible?\n\n-EungJun\n"},{"id":"259033","messageId":"xmqqzj6mcorc.fsf@gitster.dls.corp.google.com","threadId":"39009","inReplyTo":"CAFT+Tg-Gwr9EemFv88+=Ao21dGYe73D-CDiT4mXU4kuP-niOSw@mail.gmail.com","subject":"Re: How to send a warning message from git hosting server?","fromName":"Junio C Hamano","fromEmail":"gitster@pobox.com","sentAt":"2015-04-05T20:18:47Z","receivedAt":"2015-04-05T20:18:47Z","isPatch":false,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"\"Yi, EungJun\" <semtlenori@gmail.com> writes:\n\n> Hello. I am serving a git hosting service for my company.\n>\n> Sometimes I want to send a warning message to users who use my\n> service; e.g. the service will be shutdown tomorrow for a while\n> temporary.\n>\n> I know it is possible to a remote message by hooks or HTTP body if an\n> error occured. But it seems that there is no hooks for git-fetch and\n> git does not print HTTP body if there is no error.\n>\n> I want a way to response a remote message when a client send any kind\n> of request. Is it possible?\n\nI do not offhand know if there are such hooks, but I would imagine\nthat I'd be mightily annoyed if I were forced to interact with such\na server.  I may not have a need to pull anything for a few days,\nworking on my changes, and then I'd find out when the service is\nalready down.  I may pull many times a day, and for a few days of\npre-announcement period, I'd be forced to see the same message over\nand over.  I may have a cron job to fetch down the changes made by\ncoworkers in other timezones while I am sleeping so that I can start\nmy day from an up-to-date state, but it is very likely I would say\n\"fetch --quiet\" in the cron job because I want it to be quiet unless\nthere is an error.\n\nI'd appreciate if the Gitmasters at the company sent an e-mail\naddressed to git-users@mycompany.xz instead.\n"},{"id":"259166","messageId":"alpine.LSU.2.00.1504081206420.10193@hermes-1.csi.cam.ac.uk","threadId":"39009","inReplyTo":"CAFT+Tg-Gwr9EemFv88+=Ao21dGYe73D-CDiT4mXU4kuP-niOSw@mail.gmail.com","subject":"Re: How to send a warning message from git hosting server?","fromName":"Tony Finch","fromEmail":"dot@dotat.at","sentAt":"2015-04-08T11:08:06Z","receivedAt":"2015-04-08T11:08:06Z","isPatch":false,"sender":{"key":"dot@dotat.at","avatar":"https://avatars.githubusercontent.com/u/68429?v=4"},"body":"Yi, EungJun <semtlenori@gmail.com> wrote:\n>\n> I want a way to response a remote message when a client send any kind\n> of request. Is it possible?\n\nYes, though you need a wrapper around git. Recent versions of gitolite\nhave a \"motd\" message of the day feature.\n\nhttp://gitolite.com/gitolite/list-non-core.html#triggers\n\nTony.\n-- \nf.anthony.n.finch  <dot@dotat.at>  http://dotat.at/\nFisher: Northwest backing southwest 4 or 5, occasionally 6 at first. Slight or\nmoderate. Fog patches. Moderate or good, occasionally very poor.\n"},{"id":"259261","messageId":"CAFT+Tg9La03dkteQT0YOPPKdR78w89385VfOGN2B9kLGPo7Kcg@mail.gmail.com","threadId":"39009","inReplyTo":"alpine.LSU.2.00.1504081206420.10193@hermes-1.csi.cam.ac.uk","subject":"Re: How to send a warning message from git hosting server?","fromName":"Yi, EungJun","fromEmail":"semtlenori@gmail.com","sentAt":"2015-04-12T11:25:47Z","receivedAt":"2015-04-12T11:25:47Z","isPatch":false,"sender":{"key":"semtlenori@gmail.com","avatar":"https://gravatar.com/avatar/8363435d2badb3450df0dd7c4ec2113f6e1d62c44dd3cf7dfe83c5a389b8a9bf?d=mp&s=160"},"body":"On Wed, Apr 8, 2015 at 8:08 PM, Tony Finch <dot@dotat.at> wrote:\n> Yi, EungJun <semtlenori@gmail.com> wrote:\n>>\n>> I want a way to response a remote message when a client send any kind\n>> of request. Is it possible?\n>\n> Yes, though you need a wrapper around git. Recent versions of gitolite\n> have a \"motd\" message of the day feature.\n\nIt sounds nice. Is the wrapper for git client or git server?\n"},{"id":"259402","messageId":"552E3D64.8090501@gmail.com","threadId":"39009","inReplyTo":"CAFT+Tg9La03dkteQT0YOPPKdR78w89385VfOGN2B9kLGPo7Kcg@mail.gmail.com","subject":"Re: How to send a warning message from git hosting server?","fromName":"Sitaram Chamarty","fromEmail":"sitaramc@gmail.com","sentAt":"2015-04-15T10:28:52Z","receivedAt":"2015-04-15T10:28:52Z","isPatch":false,"sender":{"key":"sitaramc@gmail.com","avatar":"https://avatars.githubusercontent.com/u/43316?v=4"},"body":"On 04/12/2015 04:55 PM, Yi, EungJun wrote:\n> On Wed, Apr 8, 2015 at 8:08 PM, Tony Finch <dot@dotat.at> wrote:\n>> Yi, EungJun <semtlenori@gmail.com> wrote:\n>>>\n>>> I want a way to response a remote message when a client send any kind\n>>> of request. Is it possible?\n>>\n>> Yes, though you need a wrapper around git. Recent versions of gitolite\n>> have a \"motd\" message of the day feature.\n> \n> It sounds nice. Is the wrapper for git client or git server?\n\nGitolite is -- in this context -- a wrapper on the git server.\n\nIt's main purpose is access control; the motd feature is just an extra that just happened to be easy once there was a wrapper anyway.\n"}]}