[go-cd] Re: Need some help with initial setup and file locations

2017-08-31 Thread Varsha Varadarajan
Hey, 

Just realized I didn't answer your question about the repository getting 
cloned on the agent fully. The repository does get cloned on the agent the 
first time and for subsequent builds running on this agent, only the 
changes are fetched. Unless you configure this otherwise 
.
 
At this moment, since a material is tied to the pipeline that it makes use 
of it, the location will always be the 
/pipelines/. Does that answer your 
question?

- Varsha

On Friday, 1 September 2017 09:17:40 UTC+5:30, Varsha Varadarajan wrote:
>
> Hi Adam,
>
> The repo does get cloned on the agent. This is the path 
> /var/lib/go-agent/pipelines/ and 
> /var/lib/go-agent/pipelines// if you 
> have configured one. For the exec task, give the command as bash and -c and 
> staging_deploy_wrapper.sh as the arguments. Like this -
>
> 
> 
> -c
> the_script
> 
> 
>
> - Varsha
>
> On Friday, 1 September 2017 01:23:30 UTC+5:30, Adam Fields wrote:
>>
>> I have the go server and agent installed (linux), and I've hit a few 
>> issues in setting up my first pipeline.
>>
>> What I'd like to do is have go monitor a particular branch of a github 
>> repo for new pushes, and when it finds one it should run a command line 
>> script (either capistrano or a shell wrapper) to deploy that branch. I've 
>> been able to add the git repo as material to the job, and verified that the 
>> connection works, so that's fine. I haven't been able to get the agent to 
>> run capistrano successfully, which is installed on the machine and can be 
>> run fine from the command line as the go user.
>>
>> I have two specific questions relating to this:
>>
>> 1) Where do I need to put the scripts so that the agent can find them? I 
>> tried putting them directly in the sandbox directory (/var/lib/go-agent/), 
>> but I still get 
>>
>> Error happened while attempting to execute 'staging_deploy_wrapper.sh'. 
>> Please make sure [staging_deploy_wrapper.sh] can be executed on this 
>> agent.
>>
>> when executing the build. I have confirmed that I can also run the 
>> wrapper script from the command line as the go user.
>>
>> 2) Does the repo being monitored need to be cloned to the agent? I 
>> noticed that it was downloaded to the build directory - is there any way to 
>> prevent that?
>>
>> Thanks!
>>
>>
>>

-- 
You received this message because you are subscribed to the Google Groups 
"go-cd" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to go-cd+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[go-cd] Re: Need some help with initial setup and file locations

2017-08-31 Thread Varsha Varadarajan
Hi Adam,

The repo does get cloned on the agent. This is the path 
/var/lib/go-agent/pipelines/ and 
/var/lib/go-agent/pipelines// if you 
have configured one. For the exec task, give the command as bash and -c and 
staging_deploy_wrapper.sh as the arguments. Like this -



-c
the_script



- Varsha

On Friday, 1 September 2017 01:23:30 UTC+5:30, Adam Fields wrote:
>
> I have the go server and agent installed (linux), and I've hit a few 
> issues in setting up my first pipeline.
>
> What I'd like to do is have go monitor a particular branch of a github 
> repo for new pushes, and when it finds one it should run a command line 
> script (either capistrano or a shell wrapper) to deploy that branch. I've 
> been able to add the git repo as material to the job, and verified that the 
> connection works, so that's fine. I haven't been able to get the agent to 
> run capistrano successfully, which is installed on the machine and can be 
> run fine from the command line as the go user.
>
> I have two specific questions relating to this:
>
> 1) Where do I need to put the scripts so that the agent can find them? I 
> tried putting them directly in the sandbox directory (/var/lib/go-agent/), 
> but I still get 
>
> Error happened while attempting to execute 'staging_deploy_wrapper.sh'. 
> Please make sure [staging_deploy_wrapper.sh] can be executed on this agent.
>
> when executing the build. I have confirmed that I can also run the wrapper 
> script from the command line as the go user.
>
> 2) Does the repo being monitored need to be cloned to the agent? I noticed 
> that it was downloaded to the build directory - is there any way to prevent 
> that?
>
> Thanks!
>
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"go-cd" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to go-cd+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[go-cd] Need some help with initial setup and file locations

2017-08-31 Thread Adam Fields
I have the go server and agent installed (linux), and I've hit a few issues 
in setting up my first pipeline.

What I'd like to do is have go monitor a particular branch of a github repo 
for new pushes, and when it finds one it should run a command line script 
(either capistrano or a shell wrapper) to deploy that branch. I've been 
able to add the git repo as material to the job, and verified that the 
connection works, so that's fine. I haven't been able to get the agent to 
run capistrano successfully, which is installed on the machine and can be 
run fine from the command line as the go user.

I have two specific questions relating to this:

1) Where do I need to put the scripts so that the agent can find them? I 
tried putting them directly in the sandbox directory (/var/lib/go-agent/), 
but I still get 

Error happened while attempting to execute 'staging_deploy_wrapper.sh'. 
Please make sure [staging_deploy_wrapper.sh] can be executed on this agent.

when executing the build. I have confirmed that I can also run the wrapper 
script from the command line as the go user.

2) Does the repo being monitored need to be cloned to the agent? I noticed 
that it was downloaded to the build directory - is there any way to prevent 
that?

Thanks!


-- 
You received this message because you are subscribed to the Google Groups 
"go-cd" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to go-cd+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [go-cd] Re: Garbage Collecition in GO

2017-08-31 Thread Chris Tamlyn
thanks.  Looks better on the support pages now.  Let's see what happens at 
 7am.

On Thursday, 31 August 2017 09:29:47 UTC+1, Ketan Padegaonkar wrote:
>
> On Thu, Aug 31, 2017 at 1:31 PM Chris Tamlyn  > wrote:
>
>> Since I raised this issue we've actually switched to a Linux server so 
>> the mechanism is slightly different.  When I view my support page I see:
>>
>>   "-Dgo.config.repo.gc.periodic\u003dY",
>>   "-Dgo.config.repo.gc.cron\u003d0 0 7 1/1 \\* \\?",
>>
>> Those are CLI args string escaped. You probably need to look at the 
> section under "System Properties" to see the unescaped values and see if 
> they are valid expressions understood by quartz (
> http://www.quartz-scheduler.org/api/2.2.1/org/quartz/CronExpression.html)
>
> I'm seeing this on the build server at build.gocd.org:
>
> $ curl -s -uUSER:PASS https://build.gocd.org/go/api/support | jq 
> '.["Runtime Information"]["System Properties"]["go.config.repo.gc.cron"]'
> *"0 0 7/12 1/1 * ?"*
>
> The file /etc/default/go-server contains:
>
> export GO_SERVER_SYSTEM_PROPERTIES="-Dgo.config.repo.gc.periodic=true 
> -Dgo.config.repo.gc.cron='0 0 7/12 1/1 * ?' -Dgo.config.repo.gc.expire=10"
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"go-cd" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to go-cd+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [go-cd] Re: Garbage Collecition in GO

2017-08-31 Thread Ketan Padegaonkar
On Thu, Aug 31, 2017 at 1:31 PM Chris Tamlyn  wrote:

> Since I raised this issue we've actually switched to a Linux server so the
> mechanism is slightly different.  When I view my support page I see:
>
>   "-Dgo.config.repo.gc.periodic\u003dY",
>   "-Dgo.config.repo.gc.cron\u003d0 0 7 1/1 \\* \\?",
>
> Those are CLI args string escaped. You probably need to look at the
section under "System Properties" to see the unescaped values and see if
they are valid expressions understood by quartz (
http://www.quartz-scheduler.org/api/2.2.1/org/quartz/CronExpression.html)

I'm seeing this on the build server at build.gocd.org:

$ curl -s -uUSER:PASS https://build.gocd.org/go/api/support | jq
'.["Runtime Information"]["System Properties"]["go.config.repo.gc.cron"]'
*"0 0 7/12 1/1 * ?"*

The file /etc/default/go-server contains:

export GO_SERVER_SYSTEM_PROPERTIES="-Dgo.config.repo.gc.periodic=true
-Dgo.config.repo.gc.cron='0 0 7/12 1/1 * ?' -Dgo.config.repo.gc.expire=10"

-- 
You received this message because you are subscribed to the Google Groups 
"go-cd" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to go-cd+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[go-cd] Re: Garbage Collecition in GO

2017-08-31 Thread Chris Tamlyn
Since I raised this issue we've actually switched to a Linux server so the 
mechanism is slightly different.  When I view my support page I see:

  "-Dgo.config.repo.gc.periodic\u003dY",
  "-Dgo.config.repo.gc.cron\u003d0 0 7 1/1 \\* \\?",


Which makes me think I've got an issue with escape characters, as yours looks 
like a real cron expression.


I followed the doc's with their comments on escaping special characters


(added to /etc/defaults/go-server):


GO_SERVER_SYSTEM_PROPERTIES="$GO_SERVER_SYSTEM_PROPERTIES 
-Dgo.config.repo.gc.periodic=Y -Dgo.config.repo.gc.cron='0 0 7 1/1 \* \?'" 


On Thursday, 19 May 2016 08:56:55 UTC+1, Chris Tamlyn wrote:
>
> We started to get an error in GO around Garabge collection which directs 
> us to this link:
>
> https://docs.go.cd/current/advanced_usage/config_repo.html
>
> Has anyone else implemented this in Go before?  I'm not sure that I'm 
> reading the documentation correctly on how to set it up for GO.  I've read 
> it as you need to add those properties to your 'wrapper-properties' file 
> (we run on Windows).  So I've added the following 3 settings:
>
> go.config.repo.gc.periodic=Y
> go.config.repo.gc.aggressive=Y
> go.config.repo.gc.cron=0 0 7 ? * SUN
>
> But I wasn't sure if this was the correct place of if they should be 
> Windows Environment variables.  Has anyone got any experience setting this 
> up and could help guide us?
>
> Many Thanks
>
> Chris
>

-- 
You received this message because you are subscribed to the Google Groups 
"go-cd" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to go-cd+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.