Giter VIP home page Giter VIP logo

k_evatool_laravel_container_app's Introduction

k:evatool laravel container app

This part of the system functions as a wrapper for the k:evatool Laravel package. It is intended to provide a fully functional backend including user management and OAUTH Authentication. It is part of the k:evatool

Funding

This project is part of the project museum4punkt0 - Digital Strategies for the Museum of the Future, sub-project k:eva. Further information: https://www.museum4punkt0.de.

The project museum4punkt0 is funded by the Federal Government Commissioner for Culture and the Media in accordance with a resolution issued by the German Bundestag (Parliament of the Federal Republic of Germany).

BKM-Logo NeustartKultur

Production

Recommended Server Setup

Backend (Laravel)

  • Ubuntu 20.04
  • Apache 2.4.x (nginx can be used as well)
  • PHP 8.0 (Several addition php packages are needed. Please see https://laravel.com/docs/8.x/deployment. We additionally recommend installing the GMP extension.)
  • MySQL 8.0
  • Composer 2.x

Prerequisites

A MySQL database must be installed and configured. Configuration also includes the creation of a database with the necessary access writes so that PHP can access it. The credentials must be inserted in the .env file.

IMPORTANT: Please clone https://github.com/museum4punkt0/k_evatool_laravel_package into the "packages/twoavy" directory. Otherwise installation would fail.

Install

Run this in project directory on initial install

php composer.phar install
php artisan storage:link
php artisan migrate
php artisan passport:install

Updates

Run this in project directory after each update

php composer.phar install
php artisan storage:link
php artisan migrate

Symlinks needed

Create the following symlinks for proper file paths. Run these commands on public folder

ln -s ../storage/app/evaluation-tool/assets evaluation-tool
ln -s ../storage/app/evaluation-tool/audio evaluation-tool-audio
ln -s ../storage/app/evaluation-tool/settings_assets evaluation-tool-settings-assets

Local development

Install & update

cp .env.example .env
mkdir -p ./packages/twoavy/evaluation-tool
git clone [email protected]:museum4punkt0/k_evatool_laravel_package.git ./packages/twoavy/evaluation-tool
git -C ./packages/twoavy/evaluation-tool checkout master
docker-compose build
docker-compose up -d
docker-compose exec k_evatool composer install
docker-compose exec k_evatool php artisan migrate:fresh --seed
docker-compose exec k_evatool php artisan passport:install
docker-compose exec k_evatool php artisan users:create-admin

Alternatively you can use the Makefile and run "make magic"

Fresh migration (deletes all data)

docker-compose exec k_evatool php artisan migrate:fresh

Fresh migration with seed (deletes all data and seeds sample data)

docker-compose exec k_evatool php artisan migrate:fresh --seed

Run seeders

Seed

docker-compose exec k_evatool php artisan db:seed

Seed demo data

docker-compose exec k_evatool php artisan db:seed --class=Twoavy\\EvaluationTool\\Seeders\\EvaluationToolDemoDataSeeder

Seed demo survey results

docker-compose exec k_evatool php artisan evaluation:seed_survey_results SURVEYID COUNT

Passport installation

docker-compose exec k_evatool php artisan passport:install

Tests

Run all tests

docker-compose exec k_evatool php artisan test

Run all tests in class

docker-compose exec k_evatool php artisan test --filter "EvaluationToolSurveyTest"

Run only one specific method

docker-compose exec k_evatool php artisan test --filter "EvaluationToolSurveyTest::test_get_surveys"

License

GNU GENERAL PUBLIC LICENSE
Copyright © 2022, 2av GmbH
Please also see the LICENSE file provided within this repository

k_evatool_laravel_container_app's People

Contributors

twoavy-mh avatar twoavy-ms avatar twoavy-nb avatar twoavy-tg avatar

Watchers

 avatar

k_evatool_laravel_container_app's Issues

Mixed content if I want to upload files

Hi,

we installed this app in production together with admin frontend, and we have an apache2.4 server in front and everytime we want to upload a file we got this error:

ixed Content: The page at 'https://eval-backend.xxx.sh/#/assets' was loaded over HTTPS, but requested an insecure XMLHttpRequest endpoint 'http://eval-backend.xxx.sh/tus/8ad38c88-9b6e-4e55-9836-6328c9993b60'. This request has been blocked; the content must be served over HTTPS.

I grep after http: but there is nothing, in the .env files we using just https and reverse proxy it to localhost/tus

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.