this is probably a beginners question but I can’t figure it out:
I want to use application (application_django to be specific) to deploy our
django project. Our source is in a subversion repository that is only
accessible with a valid username/password. But I don’t know how to give the
username and password to the deployment process.
When I copy the url to a browser it asks for the authentication and when I
enter the deployment-auth it shows the correct stuff…
I also tried giving svn_username and svn_password as parameters on the
application-level but then it just complains that it doesn’t know what to do
with the parameters.
What should I do? What am I doing wrong?
Should I ditch application and just rebuild the parts of application_django
that I need for my own recipe?
this is probably a beginners question but I can't figure it out:
I want to use application (application_django to be specific) to deploy our
django project. Our source is in a subversion repository that is only
accessible with a valid username/password. But I don't know how to give the
username and password to the deployment process.
When I copy the url to a browser it asks for the authentication and when I
enter the deployment-auth it shows the correct stuff...
I also tried giving svn_username and svn_password as parameters on the
application-level but then it just complains that it doesn't know what to do
with the parameters.
What should I do? What am I doing wrong?
Should I ditch application and just rebuild the parts of application_django
that I need for my own recipe?
On Thursday 15 November 2012 08:55:13 Noah Kantrowitz wrote:
On Nov 15, 2012, at 8:43 AM, Arnold Krille wrote:
Hi all,
this is probably a beginners question but I can't figure it out:
I want to use application (application_django to be specific) to deploy
our
django project. Our source is in a subversion repository that is only
accessible with a valid username/password. But I don't know how to give
the
username and password to the deployment process.
This is what I have so far:
application "ohf2" do
path "/srv/ohf2"
owner "www-data"
group "www-data"
scm_provider Chef::Provider::Subversion do
When I copy the url to a browser it asks for the authentication and when I
enter the deployment-auth it shows the correct stuff...
I also tried giving svn_username and svn_password as parameters on the
application-level but then it just complains that it doesn't know what to
do with the parameters.
What should I do? What am I doing wrong?
Should I ditch application and just rebuild the parts of
application_django
that I need for my own recipe?
Are you installing svn before calling that?
Thanks, that I didn't do.
Now it fails with:
Chef::Exceptions::Exec: deploy_revision[ohf2]
(/var/chef/cache/cookbooks/application/providers/default.rb line 122) had an
error: Chef::Exceptions::Exec: returned 1, expected 0
I can provide a stacktrace if needed, but neither the stack-trace nor the
output from chef-client tell me which command returned 1 instead of 0.
On Thursday, November 15, 2012 at 9:28 AM, Arnold Krille wrote:
On Thursday 15 November 2012 08:55:13 Noah Kantrowitz wrote:
On Nov 15, 2012, at 8:43 AM, Arnold Krille wrote:
Hi all,
this is probably a beginners question but I can't figure it out:
I want to use application (application_django to be specific) to deploy
our
django project. Our source is in a subversion repository that is only
accessible with a valid username/password. But I don't know how to give
the
username and password to the deployment process.
This is what I have so far:
application "ohf2" do
path "/srv/ohf2"
owner "www-data"
group "www-data"
scm_provider Chef::Provider::Subversion do
When I copy the url to a browser it asks for the authentication and when I
enter the deployment-auth it shows the correct stuff...
I also tried giving svn_username and svn_password as parameters on the
application-level but then it just complains that it doesn't know what to
do with the parameters.
What should I do? What am I doing wrong?
Should I ditch application and just rebuild the parts of
application_django
that I need for my own recipe?
Are you installing svn before calling that?
Thanks, that I didn't do.
Now it fails with:
Chef::Exceptions::Exec: deploy_revision[ohf2]
(/var/chef/cache/cookbooks/application/providers/default.rb line 122) had an
error: Chef::Exceptions::Exec: returned 1, expected 0
I can provide a stacktrace if needed, but neither the stack-trace nor the
output from chef-client tell me which command returned 1 instead of 0.
Any ideas how to go on?
Arnold
Usually that error message is "$command returned X, expected 0"[0], which leads me to suspect you have a nil value for some required command.
--
Daniel DeLeo
Random example from first google hit: Chef::Exceptions::Exec: apt-get -q -y install exim4=4.72-6+squeeze2 returned 100, expected 0
On Thu, 15 Nov 2012 11:33:40 -0800 Noah Kantrowitz noah@coderanger.net wrote:
On Nov 15, 2012, at 11:30 AM, Arnold Krille wrote:
Is there a way to make chef-client log every command (as in
command-line commands) it executes?
"-l debug" on the command line should do that.
Thanks to Noah and Daniel!
Now I see the commands, most importantly the command that failed. And
its something I expected after thinking about it on my way home: This
machine isn't yet trusting our own root-CA and so its not trusting our
repository by default.
Another thing to add into our system-essentials cookbook!
after yesterdays tips, I added our ca to the trusted CAs for the system and
now its actually the user and password that is not working.
Here is my current cookbook with error-messages as comments:
package “subversion”
application “ohf2” do
path "/srv/ohf2"
owner "www-data"
group “www-data” #scm_provider Chef::Provider::Subversion
Doesn’t work, asks for svn-password for user www-data…
scm_provider Chef::Provider::Subversion do
svn_username "deployment"
svn_password "***"
end
django do
packages [“django”, “django_extensions”, “django-mptt”, “south”]
debug true
end
end
How do I get the checkout to know the credentials? How do I get application to
pass the credentials to the deploy-resource which seems to know what to do
with svn_username and svn_password?
after yesterdays tips, I added our ca to the trusted CAs for the system and
now its actually the user and password that is not working.
Here is my current cookbook with error-messages as comments:
package "subversion"
application "ohf2" do
path "/srv/ohf2"
owner "www-data"
group "www-data" #scm_provider Chef::Provider::Subversion
Doesn't work, asks for svn-password for user www-data...
scm_provider Chef::Provider::Subversion do
svn_username "deployment"
svn_password "***"
end
django do
packages ["django", "django_extensions", "django-mptt", "south"]
debug true
end
end
How do I get the checkout to know the credentials? How do I get
application to
pass the credentials to the deploy-resource which seems to know what to do
with svn_username and svn_password?