Closed cit1zen closed 5 years ago
The upstream 2.4 branch still documents app:install so I am not sure on the correct fix for the 2.4 install at this point
@djdefi I found the solution to install Cachet 2.4 on Docker container. Would it be possible to create a separate branch, that I could pull request into? 2.4 has not been officially released, so it would probably do more harm than good to push it into master.
Thanks.
@querti how did you fix this for 2.4 to work?
I have changed the command 'php artisan app:install' in entrypoint.sh into 'php artisan cachet:install'
@querti Hello, Are you able to fix this just by changing 'php artisan cachet:install'. I had to make php artisan cachet:install --no-interaction
. But still I get the error of CSRF token validation failed
when logging to app with set credentials from setup.
@tejaswivinod I'm pretty sure I ran it in interactive mode and simply passed it the desired values by piping it with echo.
@querti Thanks for the confirmation. I am able to start the cachet, migrations happens successfully. But when I try to login after setup, it throws CSRF token validation failed
error. Any leads to the solution? Thanks. I tried seeding demo data, which results into this error
/var/www/html/vendor/laravel/framework/src/Illuminate/Database/Connection.php#664
Illuminate\Database\QueryException
SQLSTATE[42803]: Grouping error: 7 ERROR: column "chq_metric_points.created_at" must appear in the GROUP BY clause or be used in an aggregate function LINE 1: SELECT to_char(chq_metric_points.created_at, 'YYYY-MM-DD HH2... ^
/var/www/html/vendor/doctrine/dbal/lib/Doctrine/DBAL/Driver/PDOStatement.php#119
Doctrine\DBAL\Driver\PDOException
SQLSTATE[42803]: Grouping error: 7 ERROR: column "chq_metric_points.created_at" must appear in the GROUP BY clause or be used in an aggregate function LINE 1: SELECT to_char(chq_metric_points.created_at, 'YYYY-MM-DD HH2... ^
/var/www/html/vendor/doctrine/dbal/lib/Doctrine/DBAL/Driver/PDOStatement.php#117``` . But that should be another problem.
@tejaswivinod Dunno, maybe I didn't get this error because I didn't migrate the database but used the new one.
@querti above db error is after seeding with demo data by using php artisan cachet:seed
. Also, I guess I am able to resolve the validation error by removing all these variables from .env file. mentioned here: https://github.com/CachetHQ/Docker/issues/287. Is that what is expected behavior? I am on branch 2.4.
This config works fine for me: https://github.com/camilb/cachet-docker/commit/8b9bdadf4a63ff5f4be81755e54a67bd69d68bed. Just make sure you set APP_KEY
or check docker logs to get the generated key and then set it and restart docker.
@camilb want to submit a PR here with your fixes?
@djdefi done
@tejaswivinod Any progress on fixing this DB issue ?
I got the exact same error on branch 2.4 of docker-compose
I'm also seeing the same issue as @tejaswivinod when cachet is fetching the metric data on the status page. This is not the demo data, but using the https://github.com/castawaylabs/cachet-monitor in testing locally to push metrics up:
SQLSTATE[42803]: Grouping error: 7 ERROR: column "chq_metric_points.created_at" must appear in the GROUP BY clause or be used in an aggregate function LINE 1: SELECT
Worked for me when switching to the 2.4 branch AND then recreating the application (had to delete the images)
I'm unable to run Cachet 2.4 using docker-compose.
When I use fresh DB image, Cachet will fail with the exception:
When I use Cachet v2.3.15 to create a DB and then use Cachet 2.4, then I am unable to login into the admin account. Cachet will return 400 with error "CSRF token validation failed.".
Is there something that I am missing? Is there a way how to make Cachet 2.4 work inside the container?