a year ago
i have a problem with the conection of the database with my project, someone who i can share mi screen and show what's happening please.
0 Replies
a year ago
Please explain your issue in here, if possible.
@Adam so i have a login on the railway project and everything at the begining deploy on a correct way, but when i send the request of the user and password (previously added on my database) this appears, but on my local project everythng is ok



a year ago
your frontend is trying to submit for form with http, you need to be using https when hosting on railway
a year ago
change http to https, please don't overthink this
a year ago
When you send a request to your backend, currently the url you’re sending to is http. You need to change wherever it says http to https
a year ago
simple as that
a year ago
are you using https now
a year ago
that looks like a completely different problem
a year ago
please send a link to a page and steps to reproduce this issue
a year ago
in this chat
a year ago
please do not dm people without asking, this doesn't need to move to dms so please keep it in this chat
a year ago
please provide some demo credentials
a year ago
okay I will look at the network tab when I'm back on the computer
a year ago
in the mean time, have you looked into your deployment logs?
a year ago
have you read them?
2024-06-06T17:33:35.041970Z 0 [System] [MY-015015] [Server] MySQL Server - start.
2024-06-06T17:33:35.164734Z 0 [System] [MY-010116] [Server] /usr/sbin/mysqld (mysqld 8.4.0) starting as process 7
2024-06-06T17:33:35.171528Z 1 [System] [MY-013576] [InnoDB] InnoDB initialization has started.
2024-06-06T17:33:35.617852Z 1 [System] [MY-013577] [InnoDB] InnoDB initialization has ended.
2024-06-06T17:33:35.916257Z 0 [Warning] [MY-010068] [Server] CA certificate ca.pem is self signed.
2024-06-06T17:33:35.916317Z 0 [System] [MY-013602] [Server] Channel mysql_main configured to support TLS. Encrypted connections are now supported for this channel.
2024-06-06T17:33:35.923363Z 0 [Warning] [MY-011810] [Server] Insecure configuration for --pid-file: Location '/var/run/mysqld' in the path is accessible to all OS users. Consider choosing a different directory.
2024-06-06T17:33:35.958738Z 0 [System] [MY-010931] [Server] /usr/sbin/mysqld: ready for connections. Version: '8.4.0' socket: '/var/run/mysqld/mysqld.sock' port: 3306 MySQL Community Server - GPL.
2024-06-06T17:33:36.261069Z 8 [Warning] [MY-011302] [Server] Plugin mysqlx reported: 'Failed at SSL configuration: "SSL context is not usable without certificate and private key"'
2024-06-06T17:33:36.261473Z 0 [System] [MY-011323] [Server] X Plugin ready for connections. Bind-address: '::' port: 33060, socket: /var/run/mysqld/mysqlx.sock
a year ago
these are your database logs
a year ago
look at your apps logs
INFO Server running on [http://0.0.0.0:5887].
Press Ctrl+C to stop the server
2024-06-07 19:26:14 …………………………………………… ~ 0s
2024-06-07 19:30:28 …………………………………………… ~ 1s
2024-06-07 19:30:31 …………………………………………… ~ 0s
2024-06-07 19:30:36 …………………………………………… ~ 0s
2024-06-07 19:31:47 …………………………………………… ~ 0s
2024-06-07 19:31:52 …………………………………………… ~ 0s
2024-06-07 19:31:52 …………………………………………… ~ 0s
2024-06-07 19:36:55 …………………………………………… ~ 0s
a year ago
hmmm that's not helpful
a year ago
are you sure you have setup the connection to the database properly
a year ago
I assume if you set it up correctly it would have worked then lol
a year ago
there is clearly as misconfiguration somewhere
NIXPACKSBUILDCMD=composer install --no-dev && npm install --only=production && npm run build && php artisan optimize && php artisan config:cache && php artisan route:cache && php artisan view:cache && php artisan migrate --force
a year ago
that's not how the build command works, you don't need to set the environment variable there, just specify the command itself
a year ago
um when did i say to remove them both completely?
18 0.608 Composer plugins have bee
18 0.608 Do not run Composer as root/super user! See https://getcomposer.org/root for details
18 0.761 Installing dependencies from lock file
18 0.765 Verifying lock file contents can be installed on current platform.
18 0.808 Package operations: 0 installs, 0 updates, 37 removals
18 0.808 - Removing theseer/tokenizer (1.2.3)
18 0.813 - Removing symfony/yaml (v6.4.7)
18 0.816 - Removing spatie/laravel-ignition (2.7.0)
18 0.819 - Removing spatie/ignition (1.14.1)
18 0.823 - Removing spatie/flare-client-php (1.5.1)
18 0.825 - Removing spatie/backtrace (1.6.1)
18 0.828 - Removing sebastian/version (4.0.1)
18 0.830 - Removing sebastian/type (4.0.0)
18 0.833 - Removing sebastian/recursion-context (5.0.0)
18 0.836 - Removing sebastian/object-reflector (3.0.0)
18 0.841 - Removing sebastian/object-enumerator (5.0.0)
18 0.841 - Removing sebastian/lines-of-code (2.0.2)
18 0.841 - Removing sebastian/global-state (6.0.2)
18 0.841 - Removing sebastian/exporter (5.1.2)
18 0.841 - Removing sebastian/environment (6.1.0)
18 0.841 - Removing sebastian/diff (5.1.1)
18 0.841 - Removing sebastian/complexity (3.2.0)
18 0.841 - Removing sebastian/comparator (5.0.1)
18 0.841 - Removing sebastian/code-unit-reverse-lookup (3.0.0)
18 0.841 - Removing sebastian/code-unit (2.0.0)
18 0.841 - Removing sebastian/cli-parser (2.0.1)
18 0.841 - Removing phpunit/phpunit (10.5.20)
18 0.841 - Removing phpunit/php-timer (6.0.0)
18 0.841 - Removing phpunit/php-text-template (3.0.1)
18 0.841 - Removing phpunit/php-invoker (4.0.0)
18 0.841 - Removing phpunit/php-file-iterator (4.1.0)
18 0.841 - Removing phpunit/php-code-coverage (10.1.14)
18 0.841 - Removing phar-io/version (3.2.1)
18 0.841 - Removing phar-io/manifest (2.0.4)
18 0.841 - Removing nunomaduro/collision (v7.10.0)
25 | >>> RUN composer install --no-dev && npm install --only=production && npm run build && php artisan optimize && php artisan config:cache && php artisan route:cache && php artisan view:cache && php artisan migrate --force
26 |
27 |
ERROR: failed to solve: process "/bin/bash -ol pipefail -c composer install --no-dev && npm install --only=production && npm run build && php artisan optimize && php artisan config:cache && php artisan route:cache && php artisan view:cache && php artisan migrate --force" did not complete successfully: exit code: 127
Error: Docker build failed
a year ago
put your build are start commands back, just without the nixpacks variable
a year ago
what is your current build and start command now?
Dockerfile:25
23 | # build phase
24 | COPY . /app/.
25 | >>> RUN composer install --no-dev && npm install --only=production && npm run build && php artisan optimize && php artisan config:cache && php artisan route:cache && php artisan view:cache && php artisan migrate --force
26 |
27 |
ERROR: failed to solve: process "/bin/bash -ol pipefail -c composer install --no-dev && npm install --only=production && npm run build && php artisan optimize && php artisan config:cache && php artisan route:cache && php artisan view:cache && php artisan migrate --force" did not complete successfully: exit code: 127
a year ago
please stop spamming build logs
15 ERROR: process "/bin/bash -ol pipefail -c composer install --no-dev && npm install --only=production && npm run build && php artisan optimize && php artisan config:cache && php artisan route:cache && php artisan view:cache && php artisan migrate --force" did not complete successfully: exit code: 127
a year ago
as per the service settings
a year ago
im sorry but that does not answer the question
a year ago
im not sure if i will be able to help here then
the start command was is php artisan serve --host=0.0.0.0 --port=$PORT, but i deleted the nixbuilds from the custom build how you told me
a year ago
i never told you to remove your build command
a year ago
again, put it back, without the nixpacks environment variable
a year ago
bruh
a year ago
what is your current build and start command now?
composer install --no-dev && npm install --only=production && npm run build && php artisan optimize && php artisan config:cache && php artisan route:cache && php artisan view:cache && php artisan migrate --force && php artisan serve


