diff --git a/app/index.js b/app/index.js
index d333dca..cbc943d 100644
--- a/app/index.js
+++ b/app/index.js
@@ -81,8 +81,6 @@
 import users_index from './users/index.js';
 import user_accounts_controller from './users/controllers/user-accounts-controller.js';
 
-import phosphor_templates from './templates.js';
-
 window.angular && (function(angular) {
   'use strict';
 
@@ -94,7 +92,7 @@
             'ngRoute', 'angular-clipboard',
             'angularUtils.directives.dirPagination',
             // Basic resources
-            'app.templates', 'app.common.services', 'app.common.directives',
+            'app.common.services', 'app.common.directives',
             'app.common.filters',
             // Model resources
             'app.login', 'app.overview', 'app.serverControl',
diff --git a/app/templates.js b/app/templates.js
deleted file mode 100644
index 2b04ff6..0000000
--- a/app/templates.js
+++ /dev/null
@@ -1,15 +0,0 @@
-/**
- * A module which contains all compiled templates for the angular application
- *
- * @module app/templates
- * @exports app/templates
- */
-
-window.angular && (function(angular) {
-  'use strict';
-
-  /**
-   * Used for gulp template cache plugin.
-   */
-  angular.module('app.templates', []);
-})(window.angular);
diff --git a/gulp-options.js b/gulp-options.js
deleted file mode 100644
index 6bfa74d..0000000
--- a/gulp-options.js
+++ /dev/null
@@ -1,13 +0,0 @@
-/*eslint-env node */
-/*global module: true, __dirname: true */
-
-'use strict';
-
-module.exports = {
-  'targetFolderPath': './target',
-  'srcFolderPath': './app',
-  'tempFolderPath': __dirname + '/.temp',
-  'nodeModulesFolderPath': './node_modules',
-  'bowerFolderPath': __dirname + '/bower_components',
-  'dirname': __dirname,
-};
diff --git a/gulp_tasks/checkstyle.js b/gulp_tasks/checkstyle.js
deleted file mode 100644
index 0826352..0000000
--- a/gulp_tasks/checkstyle.js
+++ /dev/null
@@ -1,30 +0,0 @@
-/*eslint-env node */
-/*global require: true, module: true */
-
-'use strict';
-
-var options = require('../gulp-options.js'), gulp = require('gulp'),
-    clean = require('gulp-clean'), eslint = require('gulp-eslint');
-
-var runSequence = require('run-sequence'), fs = require('fs');
-
-gulp.task('checkstyle:clean', function() {
-  return gulp
-      .src(
-          [options.targetFolderPath + '/eslint-report-checkstyle.xml'],
-          {'read': false})
-      .pipe(clean({'force': true}));
-});
-
-gulp.task('checkstyle:eslint', function() {
-  return gulp.src([options.srcFolderPath + '/**/*.js', options.excludePath])
-      .pipe(eslint({'useEslintrc': true}))
-      .pipe(eslint.format('checkstyle', function(output) {
-        fs.writeFileSync(
-            options.targetFolderPath + '/eslint-report-checkstyle.xml', output);
-      }));
-});
-
-module.exports = function(callback) {
-  return runSequence('checkstyle:clean', 'checkstyle:eslint', callback);
-};
diff --git a/gulp_tasks/distribution.js b/gulp_tasks/distribution.js
deleted file mode 100644
index c732eab..0000000
--- a/gulp_tasks/distribution.js
+++ /dev/null
@@ -1,42 +0,0 @@
-/*eslint-env node */
-/*global require: true, module: true */
-
-'use strict';
-
-var options = require('../gulp-options.js'), gulp = require('gulp'),
-    clean = require('gulp-clean'), webapp = require('./webapp.js'),
-    imagemin = require('gulp-imagemin');
-
-var runSequence = require('run-sequence');
-
-gulp.task('webapp', function(callback) {
-  return webapp(callback);
-});
-
-gulp.task('distribution:clean', function() {
-  return gulp.src([options.dirname + '/dist'], {'read': false}).pipe(clean({
-    'force': true
-  }));
-});
-
-gulp.task('distribution:copy', function() {
-  return gulp.src(['**/*'], {'cwd': options.targetFolderPath + '/webapp'})
-      .pipe(gulp.dest(options.dirname + '/dist'));
-});
-
-gulp.task(
-    'imagemin',
-    () => gulp.src([options.dirname + '/app/assets/images/*'])
-              .pipe(imagemin({
-                optimizationLevel: 3,
-                progressive: true,
-                interlaced: false,
-                svgoPlugins: [{removeViewBox: false}]
-              }))
-              .pipe(gulp.dest('dist/assets/images')));
-
-module.exports = function(callback) {
-  return runSequence(
-      'distribution:clean', 'webapp', 'distribution:copy', 'imagemin',
-      callback);
-};
diff --git a/gulp_tasks/minifyvendors.js b/gulp_tasks/minifyvendors.js
deleted file mode 100644
index 8c429a3..0000000
--- a/gulp_tasks/minifyvendors.js
+++ /dev/null
@@ -1,32 +0,0 @@
-/*eslint-env node */
-/*global require: true, module: true */
-
-'use strict';
-
-var options = require('../gulp-options.js'), gulp = require('gulp'),
-
-    // Base dependencies
-    clean = require('gulp-clean'), rename = require('gulp-rename'),
-
-    // Classical gulp dependencies
-    uglify = require('gulp-uglify');
-
-var runSequence = require('run-sequence');
-
-gulp.task('minifyvendorjs:clean', function() {
-  return gulp.src(options.bowerFolderPath + '/**/*.min.js', {read: false})
-      .pipe(clean());
-});
-
-gulp.task('minifyvendorjs:minify', function() {
-  return gulp.src(options.bowerFolderPath + '/**/*.js')
-      .pipe(uglify({preserveComments: 'false'}))
-      .pipe(rename({suffix: '.min'}))
-      .pipe(gulp.dest(function(file) {
-        return file.base;
-      }));
-});
-
-module.exports = function(callback) {
-  return runSequence('minifyvendorjs:clean', 'minifyvendorjs:minify', callback);
-};
diff --git a/gulp_tasks/server.js b/gulp_tasks/server.js
deleted file mode 100644
index 49fc013..0000000
--- a/gulp_tasks/server.js
+++ /dev/null
@@ -1,28 +0,0 @@
-var options = require('../gulp-options.js'), gulp = require('gulp'),
-    connect = require('gulp-connect'),
-    distribution = require('./distribution.js');
-
-var runSequence = require('run-sequence');
-
-gulp.task('distribution', function(callback) {
-  return distribution(callback);
-});
-
-gulp.task('connect', function() {
-  connect.server({root: 'dist', livereload: true});
-});
-
-gulp.task('livereload', function() {
-  gulp.src(['./dist/**/*.html', './dist/**/*.js', './dist/**/*.css'])
-      .pipe(connect.reload());
-});
-
-gulp.task('watch', function() {
-  gulp.watch('./app/**/*', function(callback) {
-    return runSequence('distribution', 'livereload');
-  });
-});
-
-module.exports = function(callback) {
-  return runSequence('connect', 'watch', callback);
-};
diff --git a/gulp_tasks/webapp.js b/gulp_tasks/webapp.js
deleted file mode 100644
index f26f169..0000000
--- a/gulp_tasks/webapp.js
+++ /dev/null
@@ -1,106 +0,0 @@
-/*eslint-env node */
-/*global require: true, module: true */
-
-'use strict';
-
-var options = require('../gulp-options.js'), gulp = require('gulp'),
-
-    // Base dependencies
-    clean = require('gulp-clean'), rename = require('gulp-rename'),
-    util = require('gulp-util'),
-
-    // Angular gulp dependencies
-    ngTemplateCache = require('gulp-angular-templatecache'),
-    ngAnnotate = require('gulp-ng-annotate'),
-    ngConstant = require('gulp-ng-constant'),
-
-    // Classical gulp dependencies
-    stripDebug = require('gulp-strip-debug'), uglify = require('gulp-uglify'),
-    sass = require('gulp-sass'), cleanCss = require('gulp-clean-css'),
-    rev = require('gulp-rev'), revReplace = require('gulp-rev-replace'),
-    gulpIf = require('gulp-if'), useref = require('gulp-useref'),
-    jsoncombine = require('gulp-jsoncombine'),
-    htmlParser = require('gulp-htmlparser');
-
-
-var runSequence = require('run-sequence'), es = require('event-stream');
-
-gulp.task('webapp:clean', function() {
-  return gulp
-      .src(
-          [options.targetFolderPath + '/webapp', options.dirname + '/.temp'],
-          {'read': false})
-      .pipe(clean({'force': true}));
-});
-
-gulp.task('webapp:sasscompile', function() {
-  return gulp.src('app/styles/index.scss')
-      .pipe(sass.sync().on('error', util.log))
-      .pipe(gulp.dest(options.srcFolderPath + '/styles'));
-});
-
-// ----- To .temp from app
-gulp.task('webapp:copyjs', function() {
-  return gulp.src(options.srcFolderPath + '/**/*.js')
-      .pipe(ngAnnotate())  // Check angular dependencies injection
-      .pipe(stripDebug())  // Remove all logs
-      .pipe(uglify({'mangle': false}))
-      .pipe(gulp.dest(options.dirname + '/.temp'));
-});
-
-gulp.task('webapp:copyothers', function() {
-  return gulp
-      .src(
-          ['**/*', '!**/*.js', '!**/*.css', '!**/*.scss'],
-          {'cwd': options.srcFolderPath})  // All except JS files
-      .pipe(gulp.dest(options.tempFolderPath));
-});
-
-gulp.task('webapp:copycss', function() {
-  return gulp.src('app/styles/index.css')
-      .pipe(cleanCss())
-      .pipe(gulp.dest(options.tempFolderPath + '/styles'));
-});
-
-// ----- To target/webapp from .temp and bower_components
-gulp.task('webapp:template', function() {
-  return gulp
-      .src([
-        options.srcFolderPath + '/**/*.html',
-        '!' + options.srcFolderPath + '/index.html'
-      ])
-      .pipe(ngTemplateCache(
-          'templates.js', {'module': 'app.templates', 'standalone': true}))
-      .pipe(gulp.dest(options.tempFolderPath));
-});
-
-gulp.task('webapp:useref', function() {
-  var tasks = ['index.html'].map(function(indexPage) {
-    var assets = useref.assets({});
-
-    return gulp.src(options.tempFolderPath + '/' + indexPage)
-        .pipe(assets)
-        .pipe(assets.restore())
-        .pipe(useref())
-        .pipe(revReplace())  // Force useref to apply the 'rev' method
-        .pipe(gulp.dest(options.targetFolderPath + '/webapp'));
-  });
-
-  return es.concat.apply(null, tasks);
-});
-
-gulp.task('webapp:copyresources', function() {
-  return gulp
-      .src(
-          ['**/*.*', '!**/*.js', '!**/*.css', '!**/*.html', '!**/*.log'],
-          {'cwd': options.tempFolderPath})
-      .pipe(gulp.dest(options.targetFolderPath + '/webapp'));
-});
-
-module.exports = function(callback) {
-  return runSequence(
-      'webapp:clean', 'webapp:sasscompile',
-      ['webapp:copyjs', 'webapp:copycss', 'webapp:copyothers'],
-      ['webapp:template'], ['webapp:useref'], ['webapp:copyresources'],
-      callback);
-};
diff --git a/gulpfile.js b/gulpfile.js
deleted file mode 100644
index 16d940f..0000000
--- a/gulpfile.js
+++ /dev/null
@@ -1,14 +0,0 @@
-/*eslint-env node */
-/*global require: true*/
-
-/**
- * Gulp file declaration
- */
-
-'use strict';
-
-var gulp = require('gulp');
-var sass = require('gulp-sass');
-
-// Load gulp tasks automatically
-require('gulp-load-tasks')('gulp_tasks');
