• Apache的配置


    配置http访问站点

    编辑httpd.conf文件
     
    #方式一:配置虚拟主机
    <VirtualHost localhost>
      #ServerAdmin luowei010101@gmail.com
      DocumentRoot "D:/javascript/js_projects"
      #ServerName vvvv.com
      ErrorLog "D:/javascript/js_projects/error.log"
      
      <Directory "D:/javascript/js_projects">
         Options Indexes FollowSymLinks
         AllowOverride None
         Order allow,deny
         Allow from all
      </Directory>
    </VirtualHost>
     
    #==========================================
    #方式二:配置目录别名
    Alias /js_test/  "D:/javascript/js_projects/test/"
    <Directory  "D:/javascript/js_projects/test">
       Options Indexes MultiViews 
       AllowOverride None 
       Order allow,deny 
       Allow from all 
    </Directory>
    #==========================================

    配置git

    # git config
    SetEnv GIT_PROJECT_ROOT D:/repository/git_project
    SetEnv GIT_HTTP_EXPORT_ALL
    ScriptAliasMatch \
    "(?x)^/(.*/(HEAD | \
    info/refs | \
    objects/(info/[Apache Git server on Windows^/]+ | \
    [0-9a-f]{2}/[0-9a-f]{38} | \
    pack/pack-[0-9a-f]{40}\.(pack|idx)) | \
    git-(upload|receive)-pack))$" \
    "C:/vcs/Git/libexec/git-core/git-http-backend.exe/$1"

    <Directory "C:/vcs/Git/libexec/git-core/">
    Options Indexes FollowSymLinks
    AllowOverride All
    Order allow,deny
    Allow from all
    </Directory>

    #enable read/write access
    <Location />
    AuthType Basic
    AuthName "Git"
    AuthUserFile D:/my_tool/Apache2.2/passwd.git
    Require valid-user
    </Location>


    # config gitweb
    Alias /gitweb "C:/vcs/Git/share/gitweb"

    <Directory "C:/vcs/Git/share/gitweb/">
    AddHandler cgi-script .cgi
    <Files ~ "\.cgi$">
    Options +ExecCGI
    </Files>
    AllowOverride None
    Order allow,deny
    Allow from all
    DirectoryIndex gitweb.cgi
    </Directory>

  • 相关阅读:
    SQL注入原理解说,非常不错!
    Asp.Netserver控件开发的Grid实现(三)列编辑器
    Windows下搭建deepnet环境
    reactor设计模式
    C++ 表达式语句 海伦的故事
    [ArcGIS必打补丁]ArcGIS 10.1 SP1 for (Desktop, Engine, Server) Quality Improvement Patch
    四个好看的CSS样式表格
    UVA 10047 The Monocycle (状态记录广搜)
    二叉搜索树相关性质的应用
    广播(broadcast)、电视与电视网络
  • 原文地址:https://www.cnblogs.com/luowei010101/p/2815169.html
Copyright © 2020-2023  润新知