Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Commits on Aug 25, 2012
  1. @vinoski

    make sure "rebar eunit" passes

    vinoski authored
    When using yaws as an app dependency for another application built with
    rebar, I noticed that testing that application with "rebar eunit" would
    fail while testing yaws. It was easy to work around with "rebar eunit
    skip_deps=true" but yaws really should pass its tests when tested via
    rebar.
    
    Change rebar.config to add ibrowse as a dependency. It's used only for
    testing, but rebar doesn't support test-only dependencies, plus it's
    filtered out during release generation anyway.
    
    Modify some of the test files to be able to find ibrowse include files
    regardless of whether they're built via make or via rebar. Also rename all
    non-eunit test functions ending in "_test" so they don't confuse eunit. Also
    had to move the embedded_yaws_id_dir test from eunit to t2 because it fails
    under "rebar eunit" when yaws is a dependency for another app. It fails
    because it calls into the yaws_api:embedded_start_conf function which tries
    to call application:load(yaws), but paths aren't properly set up to allow
    that to work under these testing circumstances.
    
    Note that not all tests currently run under rebar; building with make and
    then running "make test" results in many more tests being executed. Fixing
    this will come later.
Commits on Jul 25, 2012
  1. @capflam

    Make the mime types mappings configurable

    capflam authored capflam committed
    Now, it possible to customize the global mime types mappings and to overload
    it for each virtual server. It can be done using following directives in the
    global part or the server part of the configuration:
    
    * default_type: Defines the default mime type to be used where Yaws cannot
      determine it by its mime types mappings (default: text/plain).
      In the server part, this directive overloads the global one.
    
    * default_charset: Defines the default charset to be added when a response
      content-type is text/* (default: none). In the server part, this directive
      overloads the global one.
    
    * mime_types_file: Overrides the default mime.types file included with Yaws
      (default: ${PREFIX}/lib/yaws/priv/mime.types). In the server part, this
      directive overloads the global one but mappings defined in this file will
      not overload those defined by add_types directives in the global part.
    
    * add_types: Specifies one or more mappings between mime types and file
      extensions. More than one extension can be assigned to a mime type. If a
      mapping is defined in the global part and redefined in a server part using
      this directive, then the later is used. Else the global one is kept.
    
    * add_charsets: Specifies one or more mappings between charsets and file
      extensions. More than one extension can be assigned to a charset. If a
      mapping is defined in the global part and redefined in a server part using
      this directive, then the later is used. Else the global one is kept.
    
    Here is an example:
    
      default_type = text/html
    
      <server localhost>
          port = 8000
          listen = 0.0.0.0
          docroot = /var/www
          # nothing is overloaded in the vhost
      </server>
    
      <server localhost>
          port = 8001
          listen = 0.0.0.0
          docroot = /var/www
    
          # overload global configuration:
          default_type    = text/plain
          mime_types_file = /etc/mime.types
          add_types       = <text/xhtml, yaws> <application/x-test, tst test>
          default_charset = UTF-8
          add_charsets    = <ISO-8859-1, php html yaws> <US-ASCII, tst>
      </server>
    
    During Yaws compilation, a default module 'mime_types' is created using the
    default mime.types file. Then, when yaws starts up, this module is
    re-generated, re-compiled and loaded dynamically. The new module replaces the
    default one but the .beam file is unchanged. So if one of these steps failed,
    we fall back on the default module.
Commits on Jun 27, 2012
  1. @vinoski

    loosen docroot checking for certain server configs

    vinoski authored
    For server configurations that define a reverse proxy, redirection for the
    path "/", forward proxies, or appmods on "/", a docroot isn't
    needed. Change yaws_config to avoid errors for missing docroot settings for
    such servers. Add test/t6 to check these configurations.
Commits on Jun 11, 2012
  1. @vinoski

    handle large non-chunked content in yaws_revproxy

    vinoski authored
    Use partial_post_size as a block size to handle large non-chunked content
    from backend servers in yaws_revproxy. Read the content block by block,
    returning each block to the client as it arrives. This avoids having to
    read the entire backend response into memory before replying to the
    client. Add a test for this new functionality and fix .gitignore to ignore
    the new content file used for the test.
Commits on May 11, 2012
  1. @capflam

    Add support for precompressed static files

    capflam authored
    By setting use_gzip_static to true in deflate options, in a vhost
    configuration, It is possible to serve precompressed versions of
    static files. Yaws will look for precompressed files in the same
    location as original files that end in ".gz".
    
    Only files that do not fit in the cache are concerned and the mtime
    of a precompressed file must be higher than the one of original file.
Commits on Apr 25, 2012
  1. @capflam

    Add options to configure deflate compression behaviour

    capflam authored
    By adding "<deflate> ... </deflate>" structure in vhosts configuration,
    it is possible to configure how deflate compression will be applied
    and when it will come into effect. Now we can:
    
     * define the smallest response size that will be compressed
     * define the compression level to be used
     * specify the zlib compression window size
     * specify how much memory should be allocated for the internal
       compression state
     * choose the strategy used to tune the compression algorithm
    
    All these parameters are used when a zlib stream is initialized for
    compression.
    
    It is also possible to define all compressible mime types.
    Here is an example:
    
    <server localhost>
      ...
      deflate = true
      <deflate>
        min_compress_size = 4096
        compression_level = best_compression
        mime_types        = defaults, image/*
        mime_types        = application/xml, application/xhtml+xml, application/rss+xml
        mem_level         = 9
        strategy          = default
        window_size       = 15
      </deflate>
      ...
    </server>
Commits on Apr 24, 2012
  1. @vinoski

    add rebar dependencies needed for SOAP applications

    vinoski authored
    Use rebar.config.script to dynamically add SOAP dependencies if the shell
    environment variable YAWS_SOAP is set. This way, Yaws users not interested
    in SOAP do not need these dependencies.
  2. @vinoski

    change dialyzer Makefile targets to handle known warnings

    vinoski authored
    At the suggestion of Tuncer Ayaz, modify the dialyzer targets to use the
    new known_dialyzer_warnings file to ignore all known dialyzer warnings.
Commits on Mar 6, 2012
  1. @capflam

    Update gitignore file

    capflam authored
Commits on Dec 21, 2011
  1. @tuncer @vinoski

    Add reltool based release support

    tuncer authored vinoski committed
    Running "rebar generate" now creates a self-contained yaws system
    under the build directory's "rel" subdirectory. The yaws script it
    provides at ./rel/yaws/bin/yaws isn't the same as the normal yaws
    script (the one normally found at ./bin/yaws); rather, it's a special
    script that starts yaws and the Erlang applications on which it
    depends as a local self-contained Erlang node. You can run
    
    ./rel/yaws/bin/yaws console
    
    to start an interactive yaws node, or
    
    ./rel/yaws/bin/yaws start
    
    to run it as a daemon, which you can later stop with
    
    ./rel/yaws/bin/yaws stop
    
    This script does not accept the command-line options that ./bin/yaws
    does, at least for now. If this is a problem, please raise an issue at
    the Yaws github repo or on the Yaws mailing list.
  2. @vinoski

    make "rebar compile" install under the build dir

    vinoski authored
    A "rebar compile" used to install yaws, yaws.conf, and other files
    under the user's home directory, just like "make local_install". This
    approach isn't idiomatic to rebar usage, so change it to install files
    locally under the build directory. Starting ./bin/yaws from the build
    directory starts this local installation.
Commits on Jul 17, 2011
  1. @vinoski

    add yapp.app to .gitignore

    vinoski authored
Commits on May 28, 2011
  1. @capflam @vinoski

    add tests for authentication mechanisms

    capflam authored vinoski committed
  2. @capflam @vinoski

    add a test for external interpretation of php scripts

    capflam authored vinoski committed
Commits on May 23, 2011
  1. @capflam @vinoski

    add yaws.appup.src template file (capflam)

    capflam authored vinoski committed
    Add yaws.appup.src template file used to build the final yaws.appup
    file. Also add ebin/yaws.appup to .gitignore.
Commits on Apr 10, 2011
  1. @vinoski
Commits on Mar 3, 2011
  1. @vinoski

    avoid keeping our own copy of ibrowse

    vinoski authored
    Remove our copy of ibrowse in our test directory from git
    control. Instead, download ibrowse master from github if we don't have
    a fresh copy. Track master HEAD to make sure we have the latest.
    
    Change test/Makefile to fetch ibrowse if needed as part of building
    the "all" target.
    
    Add test/ibrowse to .gitignore.
Commits on Jul 24, 2010
  1. @vinoski
Commits on Apr 12, 2010
  1. @vinoski
Commits on Apr 10, 2010
  1. @vinoski
Commits on Jun 9, 2009
  1. Added a .gitignore to file to ignore generated files, this makes 'git…

    Fabian Alenius authored
    … status' a lot more readable.
Something went wrong with that request. Please try again.