Project Layout

Inside the project there are several key files and directories:

  • .ansible-env - This directory is created when building your project. It contains the latest version of Ansible.
  • .env - This directory is created when building your project. It contains the virtualenv needed for running your project. Usually there’s no need for you to manually activate the virtualenv, as manage.py will do that for you. If you ever decide to switch the version of Python then you need to delete this directory in order to bootstrap a clean new environment.
  • _lib - Contains the library needed to bootstrap your project environment. Generally you don’t need to change anything here unless you want to change the version of Python.
  • ansible - Contains the Ansible playbook. You should look into this directory if you wish to implement some custom deployment steps, such as installing non-Python packages.
  • deps - Contains the Python dependencies. See Dependencies.
  • flask_app - Contains the actual backend code in Flask.
  • migrations - ?
  • scripts - ?
  • static - Contains static files. See The Static Directory.
  • tests - Contains tests. See Testing Your Application.
  • webapp - Exists only in weber-frontend. Contains the client side application written in Ember.js. The layout in this directory is managed by ember-cli, npm, Bower and Broccoli.
  • manage.py - This is the main app to manage the building, testing and deployment of your project. See The Management Application.

The Static Directory

This static directory exists in all variants of Weber, but it plays a different role in weber-frontend. In weber-backend and weber-minimal, this directory is tracked by Git. You should modify it if you want to change or add static assets.

In weber-frontend this directory is created as part of the build process. It isn’t tracked by Git. The static assets can be found webapp/public/assets, which is a directory tracked by Git. If you ever wish to add or modify the static assets in weber-frontend remember to modify webapp/public/assets.