Commit 5671ec0c authored by Leigh B Stoller's avatar Leigh B Stoller
Browse files

Need to add TBAMDINGROUP to group list, to get into the repo dir.

parent ec86d19e
......@@ -51,6 +51,7 @@ my $TB = "@prefix@";
my $TBOPS = "@TBOPSEMAIL@";
my $OURDOMAIN = "@OURDOMAIN@";
my $CONTROL = "@USERNODE@";
my $TBADMINGROUP= "@TBADMINGROUP@";
my $MAINSITE = @TBMAINSITE@;
my $REPODIR = "$TB/opsdir/repositories";
my $PROXY = "$TB/libexec/gitrepo.proxy";
......@@ -146,6 +147,13 @@ my $this_user = User->ThisUser();
if (! defined($this_user)) {
fatal("You ($UID) do not exist!");
}
# We have to add the admin group so we can get into the repositories
my $unix_gid = getgrnam($TBADMINGROUP);
if (!defined($unix_gid)) {
fatal("No such group $TBADMINGROUP");
}
$GID = $unix_gid;
$EGID = "$unix_gid $unix_gid";
# Run as the user for most of this script.
$EUID = $UID;
......@@ -492,7 +500,7 @@ sub GetRepoSource($;$)
if (!defined($refspec));
chdir("$repodir") or
fatal("Could not chdir to $repodir");
fatal("Could not chdir to $repodir: $!");
if (system("$GIT cat-file -e $refspec:profile.py") == 0) {
$source = "profile.py";
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment