Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Activity
  • 09:39
    derheyne starred cytopia/devilbox
  • 07:41
    palidin starred cytopia/docker-bind
  • 00:22
    cytopia closed #58
  • 00:21
    cytopia synchronize #58
  • 00:19
    cytopia synchronize #58
  • 00:19
    cytopia synchronize #58
  • 00:17
    cytopia synchronize #58
  • 00:13
    cytopia assigned #58
  • 00:13
    cytopia opened #58
  • Dec 01 23:43
    cytopia closed #57
  • Dec 01 23:32
    cytopia assigned #57
  • Dec 01 23:32
    cytopia opened #57
  • Dec 01 23:18
    cytopia closed #55
  • Dec 01 23:02
    dependabot[bot] synchronize #55
  • Dec 01 23:02
    dependabot[bot] edited #55
  • Dec 01 23:02
    dependabot[bot] edited #55
  • Dec 01 23:02
    cytopia commented #55
  • Dec 01 23:02
    cytopia assigned #53
  • Dec 01 23:02
    cytopia closed #53
  • Dec 01 22:45
    mimimiku778 starred cytopia/devilbox
Dan Bryant
@cube-dan
To fix the problem you have to fix the perms on your host system; devilbox has nothing to do with it. Do this:
... from a terminal:
chmod 600 ~/id_rsa
... and you're done!
@longplayman:matrix.org , what platform are you on? There's a LOT of setup with vscode+xdebug and much of it has nothing to do with your xdebug.ini settings. I have it working — on a Mac — so the following might not help you; here we go anyway.
Dan Bryant
@cube-dan
vscode: make sure that you're woking from within a "workspace":
image.png
more vscode: make sure that your {workspace-folder}/.vscode/launch.json file has at least this in it:
{
  "version": "0.2.0",
  "configurations": [
    {
      "name": "Listen for Xdebug",
      "type": "php",
      "request": "launch",
      "port": 9000,
      "pathMappings": {
        "/shared/httpd/[some-site-folder]/[the-docroot]": "${workspaceFolder}/[the-docroot]/"
      }
    }
  ]
}
The really important bits are:
Dan Bryant
@cube-dan
      "port": 9000,
      "pathMappings": {
        "/shared/httpd/[some-site-folder]/[the-docroot]": "${workspaceFolder}/[the-docroot]/"
      }
devilbox has voodoo for passing port 9000 to/from the docker container. work with 9000 or change the voodoo; your call.
for the pathMappings ... the syntax is "devilbox/side":"your/computer/side". you'll need to fill in the [some-side-folder]/[the-docroot] bits with the real deets from your project.
Dan Bryant
@cube-dan
... and now for the picky bit. "${workspaceFolder}/[the-docroot]/" needs a trailing slash or your breakpoints won't grab. If you have the trailing slash. If you have the trailing slash and your breakpoints still aren't hitting try checking "everything":
image.png
host system: make sure that you've setup a network interface alias. read about that here: https://devilbox.readthedocs.io/en/latest/howto/xdebug/host-address-alias-an-mac.html#howto-host-address-alias-on-mac
Dan Bryant
@cube-dan
... And now for the part that you actually asked for; the xdebug.ini file. You'll need to setup the file to match the version of php that you're using and the config vars in my file are for Xdebug 3 ... as translated from Xdebug 2 using this: https://xdebug.org/docs/upgrade_guide — so you may need to go the other direction if you're using a different version of php. Here's the contents (the important bits) of my [devilbox-root]/cfg/php-ini-7.4/devilbox-php.xdebug.ini file:
[PHP]
xdebug.remote_enable = 1
xdebug.remote_autostart = 1
xdebug.remote_handler = dbgp
xdebug.remote_port = 9000
xdebug.idekey = VSCODE
xdebug.log = /var/log/php/xdebug.log
xdebug.mode=debug
xdebug.start_with_request=0
xdebug.discover_client_host=0
xdebug.client_host=10.254.254.254
Whoops, almost forgot. You need a cookie set in your browser for the current page that you're debugging. Here's the content of a bookmarklet that I use to spin up a xdebug.idkey cookie:
Dan Bryant
@cube-dan
javascript:(function() {document.cookie='XDEBUG_SESSION='+'VSCODE'+';path=/;';})()
To add that, right click (or ctrl+click) the Chrome bookmark bar then choose "Add Page":
image.png
Dan Bryant
@cube-dan
GIve the cook a name, slop in the js code above, save the book, and you're all setup with a shiny new bookmarklet that gives you "I can connect to a vscode + xdebug session" superpowers:
image.png
To make sure everything is A<=>B you can shell into the devilbox and give the xdebug.log file, specified in the xdebug.ini file (above) a tail -f:
 tail -f /var/log/php/xdebug.log
if everything is connecting you'll get this bit of magic pixie powder:
Dan Bryant
@cube-dan
[22630] Log opened at 2021-09-15 22:37:18.304575
[22630] [Step Debug] INFO: Connecting to configured address/port: 10.254.254.254:9000.
[22630] [Step Debug] INFO: Connected to debugging client: 10.254.254.254:9000 (through xdebug.client_host/xdebug.client_port). :-)
... dig the smiley face on the end; because awesome, thats why.
Dan Bryant
@cube-dan
Anyway. Maybe someone can help me out with a problem of my own. After sitting on an xdebug breakpoint too long, proxy_fcgi (probably) decides that I'm done with the connection and barfs out these errors:
==> log/apache-2.4/qualitydigest.com-error.log <==
[Wed Sep 15 16:46:59.355296 2021] [proxy_fcgi:error] [pid 1097:tid 140406884910848] [client 172.16.238.1:64840] AH01067: Failed to read FastCGI header, referer: http://somesite.com.loc/
[Wed Sep 15 16:46:59.356665 2021] [proxy_fcgi:error] [pid 1097:tid 140406884910848] (104)Connection reset by peer: [client 172.16.238.1:64840] AH01075: Error dispatching request to : , referer: http://somesite.com.loc/

==> log/apache-2.4/somesite.com-access.log <==
172.16.238.1 - - [15/Sep/2021:16:44:44 -0600] "GET / HTTP/1.1" 503 299 "http://somesite.com.loc/" "Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:92.0) Gecko/20100101 Firefox/92.0"
Does anyone know how to keep proxy_fcgi — or whatever part of the stack gets bored with me looking at the contents of variables — from timing out and punching back with a 503?
Ghost
@ghost~618bfa826da03739848a40df

Hi all, I'm stuck on something and I could use some help.

I'm having Postman send over a GET request with an Authorization header, but it's not getting to PHP. Apache is probably discarding it, for security reasons. I have tried several ways to tell Apache NOT to do this, but nothing is working. Here's what I've tried:

  1. Adding custom vhost templates to /my-project/.devilbox with the appropriate directives, and confirmed they're being picked up
  2. Adding a custom .conf file to /devilbox/cfg/apache-2.4
  3. Making changes directly to my .htaccess files in my webapp (CakePHP v3)

I've restarted the Devilbox countless times but I'm getting nowhere with this. Any help would be appreciated.

Novitsh
@Novitsh
Does someone have any docs on using Devilbox with mutagen? I read it increases speed a lot. Docker is slow on Mac.
Alberto
@B1NAR10
Hi, I have a problem with mysql since it does not run and gives me an error, what could it be?
Jimmy
@Jarco
Can anyone point me to the documentation or explain to me how I can use the work flavor container. It is set in my docker compose, but I am still missing the drush tool.
3 replies
Nvm. my question, I am now sure I am running the work container. It just doesn't contain drush. If anyone could explain to me how to get drush in there I would be grateful. If I read this correctly it should already be? https://github.com/devilbox/docker-php-fpm
Raa'Shaun Hunter
@CardcaptorRLH85
I've been following the installation instructions and I've reached the point where I'm supposed to be able to access the Devilbox intranet. However, when I try to access it on the port I've assigned in the .env file (the machine I run my containers on has a web server that uses ports 80 & 443 so I assigned Devilbox to 30080 and 30443), I get a connection timeout message in Chrome. I'm accessing this from another machine on the same LAN, would that be a problem?
Raa'Shaun Hunter
@CardcaptorRLH85
I've tried using curl to grab the intranet webpage for devilbox from the machine that my docker containers live on and I received the correct page. However, I can't access it from any other machines. Is it only supposed to be accessible from localhost?
3 replies
oodlenoodle
@oodlenoodle:matrix.org
[m]
Hi, I'm trying to install devilbox on my machine and I'm able to access the intranet from my local machine. I keep getting a timeout and I can't figure out what I'm doing wrong
deneb-v
@deneb-v

Hi, I have 2 devilbox instances running on my docker.

lets says devilbox 1 is running service at backend.loc and devilbox 2 is running service at frontend.loc

is there a way to make the service in devilbox 2 (frontend.loc) able to access backend.loc?

danieltruong
@danieltruong:matrix.org
[m]
Hi, how can I add crontab? crontab -e * php -q "/var/www/html/cron.php" >/dev/null 2>&1
I tried connect to container Httpd and php to add : update; install cron; and crontab -e; add >> crontab -e * php -q "/var/www/html/cron.php" >/dev/null 2>&1 ... But not work. could someone hlep. Thanks
Matei Nicolae - Daniel
@matei1337
How can I enable OpenSSL on Devilbox? I am trying to test something that involves curl, but I get this error: error:1425F102:SSL routines:ssl_choose_client_version:unsupported protocol
Raa'Shaun Hunter
@CardcaptorRLH85
I'm running devilbox in Docker on a Synology DS220+ and I have the No Host DNS record found. Add the following to /etc/hosts: 127.0.0.1 debitpay.loc error. Do I add this the the NAS' hosts file or the one inside the container?
Raa'Shaun Hunter
@CardcaptorRLH85
I've added this line (as well as ::1 debitpay.loc) to the NAS' hosts file and nothing changed even after restarting the NAS (and therefore all of the containers). What should I try now?
cytopia
@cytopia
Peter Nerád
@neradp
@CardcaptorRLH85 Add 127.0.0.1:HOST_PORT_BIND nameserver to your dns network resolution setup at NAS at first place. If you use some dns service on NAS, add forwarding to 127.0.0.1:HOST_PORT for your development domain.
6 replies
Matei Nicolae - Daniel
@matei1337
service "pgsql" refers to undefined volume devilbox-pgsql-13.0: invalid compose project I get this error after updating the Devilbox to version 2.0.0
1 reply
Matei Nicolae - Daniel
@matei1337
how can i
1 reply