Redundant port :8000 results in browser error
Closed this issue · 10 comments
With the current uri definition uri = "http://drupal9.lndo.site:8000"
I get this after following thedrush uli
generated link:
Unable to connect
Firefox can’t establish a connection to the server at drupal9.lndo.site:8000.
This works better:
uri = "http://drupal9.lndo.site"
PR will be ready shortly.
Upon provisioning the app, Lando returns the following URLs, and they all work okay (I'm using Firefox, too):
APPSERVER URLS https://localhost:32805
http://localhost:32806
http://drupal9.lndo.site:8080
https://drupal9.lndo.site
http://drupal9.lndo.site isn't one of them and when I try to access it I'm getting a 404 (as expected). I wonder why it's not failing for you? Did you do anything special?
Try to change the uri
variable back to https://drupal9.lndo.site and follow this procedure https://docs.lando.dev/config/security.html#trusting-the-ca
For me it works okay now with both the SSL version of the test site and the provided certificates.
Thanks for link to the SSL/TLS page at lando.dev, that's the one I tried with no luck a while ago ... Which OS are you using? I am using Ubuntu 18.04.
This is my process:
$ git clone git@github.com:anavarre/d9.git
Cloning into 'd9'...
remote: Enumerating objects: 43, done.
remote: Counting objects: 100% (43/43), done.
remote: Compressing objects: 100% (32/32), done.
remote: Total 43 (delta 20), reused 33 (delta 11), pack-reused 0
Receiving objects: 100% (43/43), 20.52 KiB | 6.84 MiB/s, done.
Resolving deltas: 100% (20/20), done.
$ git clone --branch 9.0.x https://git.drupalcode.org/project/drupal.git
Cloning into 'drupal'...
remote: Enumerating objects: 2382, done.
remote: Counting objects: 100% (2382/2382), done.
remote: Compressing objects: 100% (1299/1299), done.
remote: Total 721313 (delta 1193), reused 2210 (delta 1049), pack-reused 718931
Receiving objects: 100% (721313/721313), 160.35 MiB | 39.14 MiB/s, done.
Resolving deltas: 100% (523731/523731), done.
$ cd drupal/
$ ../d9/d9.py --install
===> Git repository detected
===> Drupal 9 branch detected
===> Drupal 9 codebase detected
===> Creating Lando configuration file (PHP 7.3 / MySQL 5.7)
===> Starting app
Let's get this party started! Starting app..
Recreating landoproxyhyperion5000gandalfedition_proxy_1 ... done
Creating network "drupal9_default" with the default driver
Creating volume "drupal9_data_appserver" with default driver
Creating volume "drupal9_home_appserver" with default driver
Creating volume "drupal9_data_database" with default driver
Creating volume "drupal9_home_database" with default driver
Creating drupal9_appserver_1 ... done
mkdir: cannot create directory '/user/.ssh': File exists
Stopping drupal9_appserver_1 ... done
Starting drupal9_appserver_1 ... done
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 599 100 599 0 0 5241 0 --:--:-- --:--:-- --:--:-- 5254
100 4673k 100 4673k 0 0 2676k 0 0:00:01 0:00:01 --:--:-- 3540k
Drush Version : 8.2.3
Stopping drupal9_appserver_1 ... done
Starting drupal9_appserver_1 ... done
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 811k 100 811k 0 0 301k 0 0:00:02 0:00:02 --:--:-- 301k
Stopping drupal9_appserver_1 ... done
Creating drupal9_database_1 ... done
Starting drupal9_appserver_1 ... done
Waiting until database service is ready...
Waiting until appserver service is ready...
Waiting until database service is ready...
Waiting until database service is ready...
Waiting until database service is ready...
Waiting until database service is ready...
Waiting until database service is ready...
BOOMSHAKALAKA!!!
Your app has started up correctly.
Here are some vitals:
NAME drupal9
LOCATION /home/user_name/drupal
SERVICES appserver, database
APPSERVER URLS https://localhost:32785
http://localhost:32786
http://drupal9.lndo.site
https://drupal9.lndo.site
===> composer.json detected
===> Pulling Composer dependencies
===> Installing the latest Drush
===> Installing Drupal
// You are about to create a sites/default/settings.php file and DROP all tables in your 'drupal8' database. Do you
// want to continue?: yes.
[notice] Starting Drupal installation. This takes a while.
[success] Installation complete.
http://drupal9.lndo.site:8000/user/reset/1/1583253887/hkDuEDbheNTNQ46qbUFrcf8G6SHANKHnFuWqbIq5FNw/login
When I click the drush uli
generated link http://drupal9.lndo.site:8000/user/reset/1/1583253887/hk...FNw/login I get the Unable to connect - Firefox can’t establish a connection to the server at drupal9.lndo.site:8000.
error in Firefox.
What is the purpose behind defining port 8000 at the end of the uri
here?
uri = "http://drupal9.lndo.site:8000"
Which OS are you using?
cat /etc/issue && uname -r
KDE neon 5.18
4.15.0-88-generic
You do have http://drupal9.lndo.site
in your Lando install. Interesting, like I said, I don't. I'm using this Lando version:
lando version
v3.0.0-rc.23
What is the purpose behind defining port 8000 at the end of the uri here?
That's Lando doing this via Traefik. It's the only alternative I currently have when not using HTTPS (well, that or any of the 2 other localhost URLs with another port)
I tried upgrading Lando from rc.22 to rc.23, and went through all the hoops on their SSL page, but still get an error (port 8000) or SSL warning via HTTPS.
Perhaps we should close this issue and the PR, if you want to keep port 8000 in the uri
?
I tried upgrading Lando from rc.22 to rc.23, and went through all the hoops on their SSL page, but still get an error (port 8000) or SSL warning via HTTPS.
Did you try the Firefox specific about:config
at the bottom of the page? https://docs.lando.dev/config/security.html#trusting-the-ca
Yep, and I tried deleting and re-creating it:
Looks like you do not have a Lando CA for lndo.site yet! Let's set one up!
Yet, in Firefox I still get
Error code: SEC_ERROR_UNKNOWN_ISSUER
and
Peer’s Certificate issuer is not recognized.
Closing per 8e926a4. Turns out Traefik is much smarter than I thought. It's capable of dynamically binding to available ports and offer alternatives when necessary. I've clarified this in the README.
I am glad we got to the bottom of this and got it fixed, so that using port 8000 or HTTPS isn't required.