1

I have Aegir installed with a two platforms. I'm interested in adding some additional themes/modules to the platform. Normally I might do this through Drush, but when I log into the server, I am logged in as Root not as Aegir (I don't believe you can log in a Aegir).

What is the best approach to adding themes and or modules? Should I simply upload via FTP and then make sure that I change ownership of the files?

2

I figured out a work around, actually it is quite simple. First ssh in as root. Then switch users su - aegir. Now drush will work. then simply use the drush command with the @sitename, so for instance drush @sitename.com dl themename. now this downloads to sites/all/modules, if you want you can move it to sites/sitname/modules. Either way it's a pretty fast workflow.

  • also if you want to download anything to the platform you can use this command drush @platform_PlatformName dl modulename – user379468 Nov 29 '12 at 20:53
0

There are some good beginner tutorials here. http://friendlydrupal.com/aegir

since you are able to log in as root then you can also create the aegir user at the bash prompt like this:

ln -s /var/aegir/config/apache.conf /etc/apache2/conf.d/aegir.conf
useradd -r -U -d /var/aegir -m -G www-data aegir
echo 'aegir ALL=NOPASSWD: /usr/sbin/apache2ctl'>> /etc/sudoers

this is assuming you are on an Ubuntu distro and that you have installed aegir properly. Other helpful links; http://vimeo.com/17131725, http://vimeo.com/groups/webdesigntuts/videos/9127281 and of course, http://community.aegirproject.org

I also found this which might be ideal for the situation:

Primarily, I had to generate the key file as Aegir user and move the key file over from the first server, where it was generated, to the second server, where it would be used, as a conventional (i.e., non-system account) user (that is assumed to have FTP capability at the second server). This can be accomplished as follows: Steps to be run from the first server:

  • Start by being logged in as the conventional user
  • Become Aegir user: "sudo su -s /bin/bash - aegir"
  • Create key file: "ssh-keygen -t dsa" [when prompted for text, just hit return]. This produces, among other things, a public key file named "id_dsa.pub". This file will be copied to the other server.
  • Copy id_dsa.pub to a location that is accessible to the conventional user account: "cp .ssh/id_dsa.pub /[accessible_location]/." + "chmod 777 /[accessible_location]/id_dsa.pub" (remember to remove this temporary file later)
  • Return to being the conventional user by exiting out of "su"
  • FTP the file from [accessible_location] to the second server [again, this assumes that a FTP capability exists between the first and second server, and that the conventional user is able to use that capability on both machines]

At the second server:

  • Become the Aegir user (as above)
  • Copy the file to the .ssh directory, under Aegir user's home directory, as the file "authorized_keys" (e.g., /var/aegir/.ssh/authorized_keys). Note: if this file already exists, you want to concatenate id_dsa.pub on to the existing authorized_keys file. Last, I had to set the file permissions just right on the second server:
  • change the permissions on this file to 600 (i.e., chmod 600 authorized_keys) When I tried this before, I left the permissions on authorized_keys as 777 during debug. I now understand that passwordless login WON'T WORK with this permissions set to 777. Obviously, we would not leave them at 777 in a permanent solution anyway, but I was surprised that this issue was a show-stopper during debug/installation.”

I found this at http://groups.drupal.org/node/89684

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.