Exemplo n.º 1
0
def mkdir_course_workdir(usercoursebinding):
    try:
        dir_usercourse = Dirname.usercourseworkdir(usercoursebinding)
        uid = usercoursebinding.user.profile.userid
        gid = usercoursebinding.course.groupid
        _mkdir(dir_usercourse, uid = uid, gid = gid, mode = 0o770)
    except KeyError as e:
        logger.error("Cannot create course dir, KOOPLEX['mountpoint']['usercourse'] is missing")
Exemplo n.º 2
0
def mkdir_course_workdir(usercoursebinding):
    try:
        dir_usercourse = Dirname.usercourseworkdir(usercoursebinding)
        uid = usercoursebinding.user.profile.userid
        gid = usercoursebinding.course.groupid
        _mkdir(dir_usercourse, uid=uid, gid=gid, mode=0o770)
    except KeyError as e:
        logger.error(
            "Cannot create course dir, KOOPLEX['mountpoint']['usercourse'] is missing"
        )
Exemplo n.º 3
0
def archive_course_workdir(usercoursebinding):
    if usercoursebinding.is_teacher:
        return
    dir_usercourse = Dirname.usercourseworkdir(usercoursebinding)
    archive = Filename.courseworkdir_archive(usercoursebinding)
    _archivedir(dir_usercourse, archive)
Exemplo n.º 4
0
def archive_course_workdir(usercoursebinding):
    if usercoursebinding.is_teacher:
        return
    dir_usercourse = Dirname.usercourseworkdir(usercoursebinding)
    archive = Filename.courseworkdir_archive(usercoursebinding)
    _archivedir(dir_usercourse, archive)