Skip to content

Commit

Permalink
Merge pull request #24 from studieren-ohne-grenzen/develop
Browse files Browse the repository at this point in the history
First Release!
I think we made it, let's merge!

Thanks to @sebastian-leidig for the thorough testing and suggestions, thanks to @faboschert for the good work!
  • Loading branch information
leomelzer committed Sep 3, 2015
2 parents 94c12c7 + 6a7bf78 commit 29517fc
Show file tree
Hide file tree
Showing 59 changed files with 7,420 additions and 384 deletions.
23 changes: 23 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -4,3 +4,26 @@ vendor/
# Commit your application's lock file http://getcomposer.org/doc/01-basic-usage.md#composer-lock-the-lock-file
# You may choose to ignore a library lock file http://getcomposer.org/doc/02-libraries.md#lock-file
# composer.lock
logs/
.idea/

.buildpath
.project
.settings/

bower_components/
node_modules/

brunch-config.js
*.map

public/favicon.ico
public/img
public/css
public/js
public/fontello*

app/config.php
app/dashboard.db

doc/generated
66 changes: 64 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,72 @@
# dashboard
# The Dashboard
Simple dashboard for different management tasks, works on our LDAP tree

# Getting started

## Requirements
- [PHP](https://php.net)
- [Composer](https://getcomposer.org)
- [NPM](https://npmjs.org/)
- [Bower](http://bower.io/)

## Installation
1. Run `composer install`
1. Clone the repository: `git clone https://github.com/studieren-ohne-grenzen/dashboard.git`
2. Run `composer install`
3. Run `npm install`
4. Run `bower install`
5. Run `brunch w --server` and start hacking!

## Configuration
- The logging component *Monolog* expects a writable directory `logs` in the root.
- LDAP etc. is configured in `app/config.php`, please see `app/config.php.sample` for details
- You should use *STARTTLS* with the LDAP configuration, as suggested. You may need to alter your local `ldap.conf` file so the certificate will be accepted. See [php.net](https://secure.php.net/manual/de/function.ldap-start-tls.php#94893) and this [DigitalOcean guide](https://www.digitalocean.com/community/tutorials/how-to-encrypt-openldap-connections-using-starttls) for details.

## Building
You probably want to use [Brunch](http://brunch.io) for build management. Install it by running `npm install -g brunch`.
Brunch basically has two different modes, building (`b` switch) and watching (`w` switch). If you just want to have a
look, run `brunch w --server` and open `0.0.0.0:3000` in your favorite web browser. Changes to the assets will be
compiled and injected on the fly.
You can also run `brunch b --production` to minify and mangle all CSS and JS files.

## Deployment

Simply run `./deploy.sh` from the root directory. You need to setup a local SSH alias called `sogserver` which will be used to rsync all files to the server. See the `deploy_ignore.txt` file for a list of folders/files which will not be copied.

## Overview

Here is a general overview of the directory structure:

```
<root>
|
| app/ The main application folder where nearly all developemnt is happening
| assets/ Static assets, such as images
| css/ Our custom CSS files
| js/ Our custom JS files
| setup/ Scripts to setup the environment, such as creating the sqlite database
| sog/ PSR-0 namespaced application files, autoloaded using Composer
| config.php.sample Rename the sample file to config.php for usage
| create_sieve_forwardings.sh Bash script to create the necessary files for initial sieve forwarding, needs sudo
| dashboard.db (not in git) The sqlite database.
| services.php Service definitions for Silex application
| bower_components/ (not in git) Bower files
| doc/ Documentation
| logs/ (not in git) Used by Monolog
| node_modules/ (not in git) NPM files
| public/ This is the document root for the webserver, Brunch will compile and copy all assets (images, CSS, JS...) is folder
| .htaccess-dist mod_rewrite for nicer URLs and more, should be setup directly in the vhost file
| index.php The main runtime for the application
| <everything else> All other folders are copied here by Brunch upon building, changes made to files here will be lost
| vendor/ (not in git) Composer files
| views/ Twig templates
| bower.json Frontend dependencies, such as List.js and PureCSS
| brunch-config.coffee Brunch config file
| composer.json PHP dependencies, such as Silex
| composer.lock A snapshot of the currently used version numbers of the composer dependencies
| deploy.sh Script for easy deployment
| deploy_ignore.txt Lists files (with globbing) which should not be deployed with rsync
| LICENSE Go ahead, read it. It's not long.
| package.json Development dependencies, such as plugins for Brunch
| phpdoc.dist.xml Settings some defaults for phpdoc, such as target and project title
| README.md Hi, it's me!
```
Binary file added app/assets/favicon.ico
Binary file not shown.
12 changes: 12 additions & 0 deletions app/assets/fontello-4b29a36a/LICENSE.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
Font license info


## Font Awesome

Copyright (C) 2012 by Dave Gandy

Author: Dave Gandy
License: SIL ()
Homepage: http://fortawesome.github.com/Font-Awesome/


75 changes: 75 additions & 0 deletions app/assets/fontello-4b29a36a/README.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,75 @@
This webfont is generated by http://fontello.com open source project.


================================================================================
Please, note, that you should obey original font licences, used to make this
webfont pack. Details available in LICENSE.txt file.

- Usually, it's enough to publish content of LICENSE.txt file somewhere on your
site in "About" section.

- If your project is open-source, usually, it will be ok to make LICENSE.txt
file publically available in your repository.

- Fonts, used in Fontello, don't require a clickable link on your site.
But any kind of additional authors crediting is welcome.
================================================================================


Comments on archive content
---------------------------

- /font/* - fonts in different formats

- /css/* - different kinds of css, for all situations. Should be ok with
twitter bootstrap. Also, you can skip <i> style and assign icon classes
directly to text elements, if you don't mind about IE7.

- demo.html - demo file, to show your webfont content

- LICENSE.txt - license info about source fonts, used to build your one.

- config.json - keeps your settings. You can import it back into fontello
anytime, to continue your work


Why so many CSS files ?
-----------------------

Because we like to fit all your needs :)

- basic file, <your_font_name>.css - is usually enough, it contains @font-face
and character code definitions

- *-ie7.css - if you need IE7 support, but still don't wish to put char codes
directly into html

- *-codes.css and *-ie7-codes.css - if you like to use your own @font-face
rules, but still wish to benefit from css generation. That can be very
convenient for automated asset build systems. When you need to update font -
no need to manually edit files, just override old version with archive
content. See fontello source code for examples.

- *-embedded.css - basic css file, but with embedded WOFF font, to avoid
CORS issues in Firefox and IE9+, when fonts are hosted on the separate domain.
We strongly recommend to resolve this issue by `Access-Control-Allow-Origin`
server headers. But if you ok with dirty hack - this file is for you. Note,
that data url moved to separate @font-face to avoid problems with <IE9, when
string is too long.

- animate.css - use it to get ideas about spinner rotation animation.


Attention for server setup
--------------------------

You MUST setup server to reply with proper `mime-types` for font files -
otherwise some browsers will fail to show fonts.

Usually, `apache` already has necessary settings, but `nginx` and other
webservers should be tuned. Here is list of mime types for our file extensions:

- `application/vnd.ms-fontobject` - eot
- `application/x-font-woff` - woff
- `application/x-font-ttf` - ttf
- `image/svg+xml` - svg
Loading

1 comment on commit 29517fc

@sleidig
Copy link
Collaborator

@sleidig sleidig commented on 29517fc Sep 3, 2015

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

and thanks to @leomelzer as well! ;)

Please sign in to comment.