openeuropa/eu_login

Name: eu_login

Owner: OpenEuropa

Description: null

Created: 2018-05-08 07:40:51.0

Updated: 2018-05-21 16:00:21.0

Pushed: 2018-05-21 16:00:19.0

Homepage: null

Size: 15

Language: PHP

GitHub Committers

UserMost Recent Commit# Commits

Other Committers

UserEmailMost Recent Commit# Commits

README

EU Login

Build Status

The EU Login module allows to authenticate against the EU Login service.

Table of contents:

Installation

The recommended way of installing the EU Login module is via a Composer-based workflow.

In your Drupal project's main composer.json add the following dependency:


"require": {
    "openeuropa/eu_login": "dev-master"
}

And run:

mposer update
Enable the module

In order to enable the module in your project run:

vendor/bin/drush en eu_login
Development

The EU Login project contains all the necessary code and tools for an effective development process, such as:

Project setup

Download all required PHP code by running:

mposer install

This will build a fully functional Drupal test site in the ./build directory that can be used to develop and showcase the module's functionality.

Before setting up and installing the site make sure to customize default configuration values by copying runner.yml.dist to ./runner.yml and overriding relevant properties.

To set up the project run:

vendor/bin/run drupal:site-setup

This will:

After a successful setup install the site by running:

vendor/bin/run drupal:site-install

This will:

Using Docker Compose

The setup procedure described above can be sensitively simplified by using Docker Compose.

Requirements:

Run:

cker-compose up -d

Then:

cker-compose exec -u web web composer install
cker-compose exec -u web web ./vendor/bin/run drupal:site-setup
cker-compose exec -u web web ./vendor/bin/run drupal:site-install

Your test site will be available at http://localhost:8080/build.

Run tests as follows:

cker-compose exec -u web web ./vendor/bin/phpunit
cker-compose exec -u web web ./vendor/bin/behat
Disable Drupal 8 caching

Manually disabling Drupal 8 caching is a laborious process that is well described here.

Alternatively you can use the following Drupal Console commands to disable/enable Drupal 8 caching:

vendor/bin/drupal site:mode dev  # Disable all caches.
vendor/bin/drupal site:mode prod # Enable all caches.

Note: to fully disable Twig caching the following additional manual steps are required:

  1. Open ./build/sites/default/services.yml
  2. Set cache: false in twig.config: property. E.g.:
    meters:
    .config:
    e: false
    
  3. Rebuild Drupal cache: ./vendor/bin/drush cr

This is due to the following Drupal Console issue.


This work is supported by the National Institutes of Health's National Center for Advancing Translational Sciences, Grant Number U24TR002306. This work is solely the responsibility of the creators and does not necessarily represent the official views of the National Institutes of Health.