changeweb / Unifiedtransform

A school management Software
https://changeweb.github.io/Unifiedtransform/
GNU General Public License v3.0
2.79k stars 1.22k forks source link

not working on my machine both linux and windows i am getting this error below when i run ./docker-install.sh #316

Closed ghost closed 2 years ago

ghost commented 2 years ago

if ! [ -x "$(command -v docker-compose)" ]; then echo 'docker-compose is not installed on your machine' >&2 sleep 1 echo 'Installing docker-compose' sleep 1 sudo curl -L "https://github.com/docker/compose/releases/download/1.27.4/docker-compose-$(uname -s)-$(uname -m)" -o /usr/local/bin/docker-compose sudo chmod +x /usr/local/bin/docker-compose sleep 1 fi

echo "Scaffolding your app using Docker... This will take a while..." sleep 1 sudo docker-compose up -d sudo docker-compose run --rm composer install sudo docker-compose run --rm artisan migrate:fresh

sleep 1

changeweb commented 2 years ago

Docker setup has an issue. Manual installation works for now.

ghost commented 2 years ago

how can i install it Manually?

On Thu, Aug 5, 2021 at 10:29 PM Hasib Mahmud @.***> wrote:

Docker setup has an issue. Manual installation works for now.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/changeweb/Unifiedtransform/issues/316#issuecomment-893775321, or unsubscribe https://github.com/notifications/unsubscribe-auth/AK5IFVVF75ZZ734N45HEAS3T3LYEDANCNFSM5BTO2DGA . Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&utm_campaign=notification-email .

ghost commented 2 years ago

How can i install it manually on Ubuntu 20.04 LTS?

On Sat, Aug 7, 2021 at 12:06 PM Adrian Martinez < @.***> wrote:

how can i install it Manually?

On Thu, Aug 5, 2021 at 10:29 PM Hasib Mahmud @.***> wrote:

Docker setup has an issue. Manual installation works for now.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/changeweb/Unifiedtransform/issues/316#issuecomment-893775321, or unsubscribe https://github.com/notifications/unsubscribe-auth/AK5IFVVF75ZZ734N45HEAS3T3LYEDANCNFSM5BTO2DGA . Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&utm_campaign=notification-email .

changeweb commented 2 years ago

Please follow the instructions in Readme.md file for manual installation.

ghost commented 2 years ago

still not working when i run composer install. here are the errors below.

Installation failed, reverting ./composer.json and ./composer.lock to their original content. root@school:~/Unifiedtransform# composer install Do not run Composer as root/super user! See https://getcomposer.org/root for details Continue as root/super user [yes]? yes Installing dependencies from lock file (including require-dev) Verifying lock file contents can be installed on current platform. Your lock file does not contain a compatible set of packages. Please run composer update.

Problem 1

To enable extensions, verify that they are enabled in your .ini files:

changeweb commented 2 years ago

The error messages clearly indicate the problem. Some packages require PHP 7 where you have PHP 8.

ghost commented 2 years ago

I managed to downgrade my php.73 and composer install worked, i am now having these issues when i run php artisan migrate. here are the errors below.

root@school:~/Unifiedtransform# php artisan migrate


changeweb commented 2 years ago

Check your database configuration in .env file.

ghost commented 2 years ago

Thank You, still not working, here is my configuration in .env file below, is there anything i am missing?

APP_NAME=UnifiedTransform APP_ENV=production APP_KEY= APP_DEBUG=true APP_LOG_LEVEL=debug APP_URL=http://localhost

DB_CONNECTION=mysql DB_HOST=db DB_PORT=3306 DB_DATABASE=schoolapp DB_USERNAME=schoolapp DB_PASSWORD=schoolapp

DOCKER_WEBSERVER_HOST=4049 DOCKER_PHPMYADMIN_HOST=5051

BROADCAST_DRIVER=log CACHE_DRIVER=file SESSION_DRIVER=file SESSION_LIFETIME=120 QUEUE_DRIVER=sync

REDIS_HOST=127.0.0.1 REDIS_PASSWORD=null REDIS_PORT=6379

MAIL_DRIVER=smtp MAIL_HOST=smtp.mailtrap.io MAIL_PORT=2525 MAIL_USERNAME=null MAIL_PASSWORD=null MAIL_ENCRYPTION=null

PUSHER_APP_ID= PUSHER_APP_KEY= PUSHER_APP_SECRET= PUSHER_APP_CLUSTER=mt1

STRIPE_KEY= STRIPE_SECRET=

changeweb commented 2 years ago

APP_KEY is missing. Generate app key using 'php artisan'.

ghost commented 2 years ago

Thank you, i tried that but its not show any key. here is the result when i run php artisan key:generate from terminal below.

root@school:~/Unifiedtransform# php artisan key:generate Application key set successfully. root@school:~/Unifiedtransform#

changeweb commented 2 years ago

I just noticed, in your previous PHP version error log, it also showed that PHP extensions: GD, curl are missing. That might be the issue.

Check issue #303 . It has almost similar error message.

ghost commented 2 years ago

Thank you, i got the App Key now in my .env file, here is what is in my .env file. but i am still having issues and errors when i run php artisan migrate

APP_NAME=UnifiedTransform APP_ENV=local APP_KEY=base64:v+mfMKJNrFXWLkXrVc+M71VxwOKnGSQ1/jLyNDtqS4A= APP_DEBUG=true APP_LOG_LEVEL=debug APP_URL=http://localhost

DB_CONNECTION=mysql DB_HOST=db DB_PORT=3306 DB_DATABASE=schoolapp DB_USERNAME=schoolapp DB_PASSWORD=schoolapp

DOCKER_WEBSERVER_HOST=4049 DOCKER_PHPMYADMIN_HOST=5051

BROADCAST_DRIVER=log CACHE_DRIVER=file SESSION_DRIVER=file SESSION_LIFETIME=120 QUEUE_DRIVER=sync

REDIS_HOST=127.0.0.1 REDIS_PASSWORD=null REDIS_PORT=6379

MAIL_DRIVER=smtp MAIL_HOST=smtp.mailtrap.io MAIL_PORT=2525 MAIL_USERNAME=null MAIL_PASSWORD=null MAIL_ENCRYPTION=null

PUSHER_APP_ID= PUSHER_APP_KEY= PUSHER_APP_SECRET= PUSHER_APP_CLUSTER=mt1

STRIPE_KEY= STRIPE_SECRET=

ghost commented 2 years ago

Here is the error below when i run php artisan migrate

root@school:~/Unifiedtransform# php artisan migrate

Illuminate\Database\QueryException

SQLSTATE[HY000] [2002] php_network_getaddresses: getaddrinfo failed: Temporary failure in name resolution (SQL: select * from information_schema.tables where table_schema = schoolapp and table_name = migrations and table_type = 'BASE TABLE')

at vendor/laravel/framework/src/Illuminate/Database/Connection.php:671 667| // If an exception occurs when attempting to run a query, we'll format the error 668| // message to include the bindings with SQL, which will make this exception a 669| // lot more helpful to the developer instead of just the database's errors. 670| catch (Exception $e) {

671| throw new QueryException( 672| $query, $this->prepareBindings($bindings), $e 673| ); 674| } 675|

  +35 vendor frames

36 artisan:37 Illuminate\Foundation\Console\Kernel::handle(Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput)) root@school:~/Unifiedtransform#

handhikadj commented 2 years ago

if ! [ -x "$(command -v docker-compose)" ]; then echo 'docker-compose is not installed on your machine' >&2 sleep 1 echo 'Installing docker-compose' sleep 1 sudo curl -L "https://github.com/docker/compose/releases/download/1.27.4/docker-compose-$(uname -s)-$(uname -m)" -o /usr/local/bin/docker-compose sudo chmod +x /usr/local/bin/docker-compose sleep 1 fi

echo "Scaffolding your app using Docker... This will take a while..." sleep 1 sudo docker-compose up -d sudo docker-compose run --rm composer install sudo docker-compose run --rm artisan migrate:fresh

sleep 1

What's happening on this script? I can't see any error on this please provide more info on this

handhikadj commented 2 years ago

@changeweb please provide more info so I can investigate right away Don't ever conclude anything unless you experience it first-hand

handhikadj commented 2 years ago

docker-install.sh is a shell script so it's obvious it won't work on Windows (probably until you install WSL on your Windows PC)

changeweb commented 2 years ago

@adrianmartinezverax Please follow instructions in issue #315 .

ghost commented 2 years ago

Thank you, docker is working on my linux machine, but having some errors when I run "php artisan migrate" . here are the errors below.

Illuminate\Database\QueryException

SQLSTATE[HY000] [1045] Access denied for user 'superadmin'@'localhost' (using password: YES) (SQL: select * from information_schema.tables where table_schema = unified_transform_db and table_name = migrations and table_type = 'BASE TABLE')

at vendor/laravel/framework/src/Illuminate/Database/Connection.php:671 667| // If an exception occurs when attempting to run a query, we'll format the error 668| // message to include the bindings with SQL, which will make this exception a 669| // lot more helpful to the developer instead of just the database's errors. 670| catch (Exception $e) {

671| throw new QueryException( 672| $query, $this->prepareBindings($bindings), $e 673| ); 674| } 675|

  +35 vendor frames

36 artisan:37

Illuminate\Foundation\Console\Kernel::handle(Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))

On Fri, Aug 13, 2021 at 3:10 PM Hasib Mahmud @.***> wrote:

@adrianmartinezverax https://github.com/adrianmartinezverax Please follow instructions in issue #315 https://github.com/changeweb/Unifiedtransform/issues/315 .

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/changeweb/Unifiedtransform/issues/316#issuecomment-898447018, or unsubscribe https://github.com/notifications/unsubscribe-auth/AK5IFVVUTUGZSPEEPWAP62TT4UKUFANCNFSM5BTO2DGA . Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&utm_campaign=notification-email .

ghost commented 2 years ago

[image: Screen Shot 2021-08-13 at 7.06.56 PM.png]

On Fri, Aug 13, 2021 at 6:47 PM Adrian Martinez < @.***> wrote:

Thank you, docker is working on my linux machine, but having some errors when I run "php artisan migrate" . here are the errors below.

Illuminate\Database\QueryException

SQLSTATE[HY000] [1045] Access denied for user 'superadmin'@'localhost' (using password: YES) (SQL: select * from information_schema.tables where table_schema = unified_transform_db and table_name = migrations and table_type = 'BASE TABLE')

at vendor/laravel/framework/src/Illuminate/Database/Connection.php:671 667| // If an exception occurs when attempting to run a query, we'll format the error 668| // message to include the bindings with SQL, which will make this exception a 669| // lot more helpful to the developer instead of just the database's errors. 670| catch (Exception $e) {

671| throw new QueryException( 672| $query, $this->prepareBindings($bindings), $e 673| ); 674| } 675|

  +35 vendor frames

36 artisan:37

Illuminate\Foundation\Console\Kernel::handle(Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))

On Fri, Aug 13, 2021 at 3:10 PM Hasib Mahmud @.***> wrote:

@adrianmartinezverax https://github.com/adrianmartinezverax Please follow instructions in issue #315 https://github.com/changeweb/Unifiedtransform/issues/315 .

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/changeweb/Unifiedtransform/issues/316#issuecomment-898447018, or unsubscribe https://github.com/notifications/unsubscribe-auth/AK5IFVVUTUGZSPEEPWAP62TT4UKUFANCNFSM5BTO2DGA . Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&utm_campaign=notification-email .

ghost commented 2 years ago
Screen Shot 2021-08-13 at 7 06 56 PM
handhikadj commented 2 years ago

Thank you, docker is working on my linux machine, but having some errors when I run "php artisan migrate" . here are the errors below. Illuminate\Database\QueryException SQLSTATE[HY000] [1045] Access denied for user 'superadmin'@'localhost' (using password: YES) (SQL: select * from information_schema.tables where table_schema = unified_transform_db and table_name = migrations and table_type = 'BASE TABLE') at vendor/laravel/framework/src/Illuminate/Database/Connection.php:671 667| // If an exception occurs when attempting to run a query, we'll format the error 668| // message to include the bindings with SQL, which will make this exception a 669| // lot more helpful to the developer instead of just the database's errors. 670| catch (Exception $e) { 671| throw new QueryException( 672| $query, $this->prepareBindings($bindings), $e 673| ); 674| } 675| +35 vendor frames 36 artisan:37 Illuminate\Foundation\Console\Kernel::handle(Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput)) On Fri, Aug 13, 2021 at 3:10 PM Hasib Mahmud @.***> wrote: @adrianmartinezverax https://github.com/adrianmartinezverax Please follow instructions in issue #315 <#315> . — You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub <#316 (comment)>, or unsubscribe https://github.com/notifications/unsubscribe-auth/AK5IFVVUTUGZSPEEPWAP62TT4UKUFANCNFSM5BTO2DGA . Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&utm_campaign=notification-email .

php artisan migrate won't work because the web app runs on Docker environment unless you're inside the container. Run ./dev artisan migrate instead. Once again, it's shell script. Only runs on Mac/Linux. Please read the docs carefully. On the other hand, it's always advisable for you to know Docker before decided to use the Docker setup

handhikadj commented 2 years ago

Please close this issue if there's no more to complain

ghost commented 2 years ago

Thank you so much, everything is working. I really appreciate it. Sorry for the late i was in Transit.

On Sat, Aug 21, 2021 at 10:50 AM handhikadj @.***> wrote:

Please close this issue if there's no more to complain

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/changeweb/Unifiedtransform/issues/316#issuecomment-903084603, or unsubscribe https://github.com/notifications/unsubscribe-auth/AK5IFVSUZSSBFMO6XSFGZHTT55SDXANCNFSM5BTO2DGA . Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&utm_campaign=notification-email .