tsr 0.10.0 release notes

Welcome to tsr 0.10.0!

These release notes cover the new features, bug fixes, backward incompatible changes (specially the requirement on Gandalf and Docker versions), general improvements and changes in the API you’ll want to be aware of when upgrading from tsr 0.9.0 or older versions.

What’s new in tsr 0.10.0

  • Now tsuru app-run and tsuru-admin ssh use docker exec to run commands on containers, this means that tsuru doesn’t sshd inside containers anymore, making the containers more lightweight and saving some machine resources (issue #1002).

  • It’s now possible to have multiple routers configurations in your tsuru.conf file. The configuration to be used will be defined by which plan the application is using. See routers configuration reference and plan-create command for more details.

    For plans without a router configuration, the value defined in docker:router will still be used. So nothing will break with this change. See docker:router for more information.

    There’s also a new router available: Galeb. For more details, please refer to tsuru configuration reference and Galeb’s webpage.

  • Users are now able to create apps with the same name used by a platform (issue #712).

  • Extended the healthcheck entry in the tsuru.yaml file so users can specify a threshold of allowed failures. Please refer to the tsuru.yaml documentation page for more details (thanks Samuel ROZE).

  • It’s now possible to rollback your application to a previously deployed version. To support this feature the commands app-deploy-list and app-deploy- rollback were added. Also, all newly created application images in docker are versioned with :vN. You can change how many images will be available for rollback in tsuru.conf. See config reference and tsuru-client reference for more details.

  • Gandalf is now optional. There’s a new configuration entry for choosing the “repo-manager”. For backwards compatibility purposes, when this entry is undefined, tsuru will use Gandalf. In order to disable Gandalf, users can set repo-manager to “none”. When Gandalf is disabled, tsuru will not manage keys as well. For more details, see repository management page.

  • New Ruby platform with support to multiple Ruby versions. Instead of having one platform per Ruby version, now users can just change the Ruby version they use by specifying it in the Gemfile or in the .ruby-version file.

  • New PHP platform, with support to multiple PHP interpretors (FPM, mod_php) and frontends (Apache or nginx), including the support for configuring the virtual host (thanks Samuel ROZE).

Bug fixes

  • Fix error message for unauthorized access in the team-user-add endpoint (issue #1006).
  • Fix double restart bug on bind and unbind. When binding or unbinding apps, previous version of the tsuru-server daemon restarted the app twice, making the process _really_ slow when apps have a lot of units.
  • Do not try to restart an app that has no units when removing environment variables.
  • Bring back restart:after hooks, running them from the API after success in the healthcheck.

Other improvements in tsr 0.10.0

  • tsuru doesn’t store SSH public keys anymore, this handling is forwarded to the repository manager, and it’s possible to run tsuru with no key management at all, by setting repo-manager to “none”. Then the client will fail on key-add, key-remove and key-list with the message “key management is disabled” (issue #402).

  • Improve user actions tracking. All app-related actions now use the app=<appname> format. Currently, these informations are available only in the database now, but in the future tsuru will expose all actions to admins, and may expose all actions of a user to themself.

  • Support EBS optimized instances in the EC2 IaaS provider (issue #1058).

  • Record the user that made the deploy when running git push (depends on upgrading the platforms and Gandalf).

  • Improve user feedback (thanks Marc Abramowitz)

    • when the user creation fails
    • when failing to detect authentication scheme in the server
    • when making an unauthenticated requests, and receiving an unauthorized response
    • when resetting password
  • Improve user feedback on API start-up (thanks Marc Abramowitz)

    • send fatal failures both to standard output and syslog (issue #1019)
    • properly report failure to connect to MongoDB
    • properly report failures to open the /etc/tsuru/tsuru.conf file
    • print the list of Docker nodes registered in the cluster
    • include more precise information about the router (including the configured domain and Redis endpoint, for Hipache)
  • Properly set Content-Type headers in the API (thanks Marc Abramowitz)

  • General improvements in the documentation:

  • Add instructions for upgrading Docker in the management documentation.

Backward incompatible changes

  • This version of tsuru makes use of some features available only in the latest version of Gandalf, so if you plan to continue using Gandalf after this upgrade, you need to upgrade Gandalf to the version 0.6.0 (or bigger).
  • This version of tsuru makes use of features available only from the 1.4 version of Docker, so before upgrading to tsuru-server 0.10.0, users must ensure that all Docker nodes are running Docker 1.4 or greater. Please refer to the upgrade Docker page for instructions on upgrading Docker with lesser downtime.
  • tsuru changed the name of Docker images used for applications. During start-up, the server daemon will migrate images automatically. This may slow down the first start-up after the upgrade (issue #712).
  • Drop support for Docker images that do not run tsuru-unit-agent. Starting at tsuru-server 0.10.0, every platform image must have tsuru-unit-agent installed, and ready to run.

API changes

tsuru-server 0.10.0 also include some changes in the API. Please refer to the API documentation page for more details.

  • /apps/{appname}/ssh: new shell route to access app containers. In previous versions of API this route was in provision/docker package and just allowed admin access to app containers. Now, standart users and admin users can access app containers through ssh. Admins can access any app in tsuru and standart users can only access your apps.
  • /deploys: allow non-admin users to issue requests to this endpoint. The response will list only deployments of applications that the user has access to. Admin users can still see all deployments from all applications (issue #1092).
  • /healthcheck: tsuru now has an improved healthcheck endpoint, that will check the health of multiple components. In order to check everything, users should send a new request with the querystring parameter check set to all. Example: GET /healthcheck?check=all (issue #967).
  • /info: this new endpoint returns meta information about the current running version of tsuru, like the server version and which components are enabled (issue #1093).
  • /services/instances/{instance}/{appname}: bind and unbind endpoints now streams the progress of the binding/unbinding process (issue #963).
  • /tokens: removed endpoint for generating an application token via the API. Users can no longer send POST requests to this URL.