Hot answers tagged

25

From info ls, under the What information is listed? section, regarding the output produced by -l: A file with any other combination of alternate access methods is marked with a '+' character. Generally, it means it has an ACL set.


13

The "@" sign -- which is not documented in the manual page for ls(1) indicates that the file has extended attributes. You can use the command 'xattr -l ' to show them Quote from : http://en.wikipedia.org/wiki/Extended_file_attributes Extended file attributes is a file system feature that enables users to associate computer files with metadata not ...


11

I think you're trying to make sudo work in a way that it is not ment to - you don't want to add the 'simple' user to the sudoers file (please correct me if i'm wrong). In that case sudo isn't the tool you want to use you want to issue su -c <command> this will prompt for the root password, execute the command, then exit.


10

Symlinks are cached by Apache, I assume you are using FollowSymLinks in your httpd.conf. You could try using SymLinksIfOwnerMatch whose call to lstat is not cached http://httpd.apache.org/docs/2.0/misc/perf-tuning.html#symlinks


10

As stated by @MadHatter this means the File/Directory has additional right trough Access Control Lists. Usually the Owner:Group system is enough, but in some cases you need a fainer grained permission control. There comes the acl system in touch. To see the acls on a specific file/dir simply type: getfacl myfileordir For changing the permissions use the ...


9

Capistrano and MCollective solve different problems. Sure, there is overlap, but Capistrano is very heavily focused on deploys, where MCollective is aimed towards generic orchestration - performing ad-hoc tasks and collecting information. You can make MCollective do your deploys, but IMHO it is better suited for discovery and ad-hoc information gathering, or ...


9

We use a configuration management tool (Chef in our case) which writes out Nagios configuration from the node information.


6

You do not need to set up a server/client infrastructure to use puppet, nor do you need to have a running puppetmaster daemon. You can point puppetd directly at a set of manifest files for your server and it'll happily get things configured for you.


6

Each run command basically executes within its own shell environment. So you would need to do something like: run "cd #{release_path} && script/console production" However, you cannot run commands in script/console this way as script/console is for interactive usage. What you want is script/runner like so: run "cd #{release_path} && ...


6

Actually, the command string listed in the sudoers is requiring to be the exact match. In your example, you put the command string /usr/bin/yum update in the sudoers configuration line, but the command you finally executes is yum -y update. (the difference is the extra parameter -y). Then, the mismatch in command string caused the sudoers failed to hit ...


5

As far as I know they can. Take note that puppet is ruby too. And so is chef. I guess it is a matter of personal taste, have a look at the way to define 'recipes' and decide which would better suite you. You can also look at these other questions. This answer says it all :). If you have a git repository already, maybe capistrano is a better choisce. ...


5

Capistrano is mature and is not in need of much work. It still has a huge user base with >24K downloads for the 21 Mar 2011 release. Jamis Buck created Capistrano somewhere around 2005. He did the majority of work on it until Feb 2009 when he announced he would be handing over maintainership of it. Lee Hambley took over and has been maintaining the ...


5

It appears that Capistrano uses non-interactive shell and hence it won't read bashrc. Solution: Added this to deploy.rb set :default_shell, '/bin/bash -l'


4

You could also look into making a setup using kickstart and pxe boots to do the preliminary setup.


4

There's a flag to be set in the sudoers file if you want the user to authenticate via his own password, or via root's. The flag is called rootpw. Sudo is a very powerfull package, be sure to check the man page about sudoers(5).


4

You should use: execute "cd #{release_path} && script/console production" With capistrano 3.x


4

Puppet would be ideal for this. Puppet provides you with a declarative language to describe the configuration of each server, including packages, services and configuration files. Puppet provides a strong framework to describe the dependancies that each component has on each other, which allows your to build modular configuration files that describe how to ...


3

-rwxr-xr-x for a regular file whose user class has full permissions and whose group and others classes have only the read and execute permissions. on osx ls command now displays a "@" character after the permissions string for each file that has extended attributes


3

No. Use su to become root using the root password. The better solution is probably to have capistrano use sudo on the deployment machine for tasks that need root access.


3

You can use mcollective to run remote commands. You have to install a client on each puppet client though. Note that mcollective also requires an activemq server.


3

You can use capistrano-chef, a RubyGem that allows you to use Chef Search for role names to do the deployment. https://github.com/cramerdev/capistrano-chef Possibly unrelated, Evan Machnic has a video of how he uses Chef and capistrano from a presentation at a Ruby Brigade meeting. http://how-i-work.com/workbenches/26-automating-deployments-with-git-...


3

I had this same problem/question. Here's a snippet from my working deploy.rb file. Note: I've altered /etc/sudoers to allow my deploy user to run the sudo mv... command foreman_temp = "/tmp/#{application}-foreman" run [ "mkdir -p #{foreman_temp}", "cd #{release_path}", "/usr/local/rvm/gems/ruby-1.9.2-p290/bin/bundle exec foreman export upstart #{...


3

Check out /etc/sysconfig/init. The top lines on my CentOS 5.x system: # color => new RH6.0 bootup # verbose => old-style bootup # anything else => new style bootup without ANSI colors or positioning BOOTUP=color Changing the BOOTUP line to something like nocolor eliminates the formatting for all init scripts. If you just want to disable ...


3

Wrote my own little set of php scripts that write nagios configurations to a file. Nagios is easy because its just a text file so all you need to do is create a template for each type of server. Then when the server starts add a file using the template. The only data that changes in the file is the host ip and name. For more static servers I created a ...


3

This is probably solveable outside of Capistrano and in SSH itself. Setting up a ~/.ssh/config file an creating an entry for your host: HostName myserver.example.com PreferredAuthentications=keyboard-interactive PubkeyAuthentication=no Capistrano will definitely prompt for a password if no key is present, I've done that.


3

This is an selinux problem. When you run sudo nginx it starts nginx as unconfined_t, when you run sudo service nginx start it starts nginx as httpd_t. By initially starting with just sudo it creates a bunch of files and initializes its state as unconfined_t. For example the pid file will be the wrong context. Thus when using service nginx stop to terminate ...


2

if someone steals our private ssh key and acces to our machines as the foo user, is able to take down the website Encrypt your SSH private keys with a secure passphrase and do not copy them to remote servers. If someone gets hold of your private key it will be no use to them without the passphrase.


2

One thing i 'll like to add is that it would be better to exclude foo guy from being able to login from ssh What i mean is to connect to the server as user "superman" and afterwards using su foo to become foo user and execute any command you want Using this way, the attacker needs both password / private key in order to be able to use capistrano. If he was ...


2

Remove the entry for ec2.flasheves.com your deploy server's ~/.ssh/known_hosts, it looks like the host key on ec2.flasheves.com changed and ssh is killing the connection since it could be a hijack. http://www.symantec.com/connect/articles/ssh-host-key-protection


2

At the risk of reviving an old thread, check out Ansible for running arbitrary commands over a set of hosts. Set up a hosts file with a group named "all" and then type ansible all -a "/bin/echo hello" to see the results.



Only top voted, non community-wiki answers of a minimum length are eligible