Sunday, January 19, 2014

Walk on a trail

an hour walk on the trail 140, 341, 342, really nice weather.

Gerrit+LDAP

setup gerrit with LDAP authentication.

Here are the key note for gerrit.conf file
[auth]
        type = LDAP
[ldap]
        server=
        accountBase= ou=people,dc=*,dc=*
        accountPattern=(&(objectClass=person)(uid=${username}))
        accountFullName= mail
        accountEmailAddress = mail
[httpd]
        listenUrl=http://*:8180/

 also tried apache2 proxy to LDAP. key note
created a new virtual host with port 8082, have to add this to the port.conf
the gerrit port is still 8180.
in gerrit.conf
canonicalWebUrl = http://192.168.1.30:8082/
[httpd]
        listenUrl = proxy-http://127.0.0.1:8180/
the LDAP way is easier to config, the proxy one is working halfway, can only login first user and creat admin. I don't have time to figure out why
 another lessons learned here for gerrit username.
User names cannot contain spaces.  Currently they are restricted to be
strings that match the following regular expression:
  ^[a-zA-Z][a-zA-Z0-9._-]*[a-zA-Z0-9]$

otherwise, gerrit login will give "name does not conform" error.

Saturday, January 18, 2014

Apache+openldap without SSL

This is a experimental in my home network without using ssl.

sudo a2enmod ldap authnz_ldap authn_alias
the red part is appended.  
sudo emacs sites-available/default
        AuthLDAPURL ldap://localhost:389/dc=****,dc=****?uid?sub?(objectClass=*)

        ServerAdmin webmaster@localhost

        DocumentRoot /var/www/
       
                Options FollowSymLinks
                AllowOverride None
       
       
                Options Indexes FollowSymLinks MultiViews
                AllowOverride None
                Order allow,deny
                allow from all

                AuthName  "Authentication"
                AuthBasicProvider ldap-internal
                AuthType Basic
                AuthzLDAPAuthoritative on
                Require valid-user
       
that's it, access apache with LDAP.

Scribefire not working now

I have been using scribefire to publish blogs for 5 years, and recently ( since my last post), it stopped working with this site. I am too busy to figure out why and I saw other people's comments on the apps comments section complaining for the same thing.I have a home blog using apache roller, so scribefire will allow me to publish to both site. if some one figured out the cause, I would like to use scribefire again.