Build a solid WordPress dev environment with Docker

Поделиться
HTML-код
  • Опубликовано: 25 окт 2024

Комментарии • 245

  • @aschmelyun
    @aschmelyun  Год назад +17

    Hey new viewers! If you would like to see more content on WordPress and Docker, let me know what ideas you have in mind or what you'd like to learn more about.

    • @karlson2804
      @karlson2804 Год назад

      * How to use wp-env and configure on it composer autoload is the main problem.
      * How to make Vite compile with WordPress files and connect CI/CD dist for them.
      *Convert and connect fonts from otf and ttf to woff in WordPress project after compiling files on Vite.
      *Convert and connect img from jpg, png to webp in WordPress project after compiling files on Vite.
      *How to make a clear and clean structure for files in WordPress project for developing plugins and themes.
      *How to set up correctly and with best practices code style and lints for WP themes and plugin develop.

    • @DharmendraSingh4ever
      @DharmendraSingh4ever 11 месяцев назад

      @@karlson2804 great suggestion✌

    • @DharmendraSingh4ever
      @DharmendraSingh4ever 11 месяцев назад

      Thanks @aschmelyun its really helpful and really a good one and no doubt correct way to use docker with WordPress, waiting more videos on different topics please keep posting.
      Adding to this you can use wp-cli automation copying sh files to the root and execute installation and webpack internally setting apache/nginx logs can also be added to this.... thanks

    • @Khawar_Mehfooz
      @Khawar_Mehfooz 10 месяцев назад +2

      Wordpress theme development with Bedrock and Sage

    • @goonie79
      @goonie79 9 месяцев назад

      Was hoping to see phpmyadmin installed as well on this tutorial. It is Great tutorial, thank you!

  • @captainpumpkinhead1512
    @captainpumpkinhead1512 11 месяцев назад +11

    I really appreciate how you let stuff break, and then went back and showed how to fix those things!! I thought that was really helpful! Thank you!!!

    • @aschmelyun
      @aschmelyun  11 месяцев назад +1

      Thanks for noticing! It's how I learn best, so I figured it's the better way to show it!

    • @ghpr1231
      @ghpr1231 6 месяцев назад

      oh yeah this is amazingly detail. I love it! Thank you

  • @MrZerosixZeroone
    @MrZerosixZeroone 2 года назад +46

    This might be the best dev. tutuorial on the internet - the simplicity of the start that leads the viewer to an explanation of very complex solution while solving problems as they arrive is so gratifying to watch, combined with clear spoken Engish and being on point.

  • @savashzaynal6502
    @savashzaynal6502 2 года назад +4

    Seriously this is the most clean, clear and on point example. Very underrated.

  • @kurtock
    @kurtock 11 месяцев назад +2

    This is the best tutorial that I found about wordpress docker. Thank you for this tutorial, I will continue watching you other videos.

  • @shahbazahmadsiddiqui
    @shahbazahmadsiddiqui Год назад +1

    This is how a tutorial video should be made. Kudos and many many thanks to Andrew.

    • @aschmelyun
      @aschmelyun  Год назад

      I'm glad you liked it, thanks so much!

  • @aschmelyun
    @aschmelyun  3 года назад +51

    If you'd like to see the full code along with some additional helper items, check out the GitHub repo here: github.com/aschmelyun/docker-compose-wordpress

    • @jomaramomas7682
      @jomaramomas7682 3 года назад

      @andrew schmelyun Have you tried adding xdebug with this and making it work. It's too complicated to set up.

    • @PeterMumford
      @PeterMumford 2 года назад +2

      I like this plan a lot, but I'm wondering how deployable it is, since the certificates are bound to the NGINX container. Can you do a follow up on a deployment sequence?

    • @aschmelyun
      @aschmelyun  2 года назад +3

      @@PeterMumford Sure thing! I'll add it to my list.

    • @jenifer5463
      @jenifer5463 2 года назад

      When i try to clone this repo it don’t work well. As well as you can make another vedio in this particular issue.

    • @jenifer5463
      @jenifer5463 2 года назад

      Your git repo lots of extra code bit you skip this please you can make full tutorial i hope it will help people who learn More

  • @tictac1020
    @tictac1020 2 года назад +1

    After leaving previous job and not using my previous docker setup for months, I needed a refresher to get everything going on my personal laptop. Especially compared to all the various docs, SO threads, videos, and Reddit posts I went through when I created my prev job's new docker setup, this is the best Docker intro I've seen, nevermind best WP + Docker intro. You saved my bacon, dude. Will be checking out your other vids. Thanks for making this!

  • @crawfordpaul8188
    @crawfordpaul8188 2 года назад +1

    Took me some back and forth but I eventually got it working after watching your video. Thanks for the great tutorial!!!

  • @hexcoreZz
    @hexcoreZz Год назад +3

    Andrew, this was a great tutorial. Keep up the good work, appreciate you putting in the time for this.

  • @Laflamablanca969
    @Laflamablanca969 3 года назад +4

    You've got a new subscriber in me. Loving the Laravel + Docker tutorials. Cheers

  • @ahmed_attia
    @ahmed_attia Месяц назад

    I rarely comment on a video, but u just earned a new subscriber, very good content

  • @codehorror8076
    @codehorror8076 2 года назад

    This was a nice refresher after spending the last couple of years away from WP and Docker. Half way through the video I was thinking "wp-cli would be so much easier, let me see how I can do that". And then I noticed you discussed it at the end. Doh! It's "Sea el eye" (CLI) and it stands for "Command Line Interface".

  • @jamiedoig9568
    @jamiedoig9568 3 года назад

    As a complete new comer to docker and launching WP containers, I found this video extremely useful as well as the comment threads where all my questions were answered already by previous helpful users. +1 Subscriber

  • @Fabrifix
    @Fabrifix 3 года назад +4

    Thank you very much Andrew! You can't imagine how much you've helped me understand how docker and docker -compose work. The configurations inside the containers is something I did not find anywhere else ... thank you so much for your generosity!

  • @mmikhan
    @mmikhan 3 года назад +5

    Excellent Docker tutorial :) Would love to see a similar guide on how to set up up a Test-Driven Development (PHPUnit) for WordPress using Docker!

    • @aschmelyun
      @aschmelyun  3 года назад +6

      I'll add it to the list!

    • @epfuller
      @epfuller 3 года назад +4

      Yes, this would be great!

  • @DrewBombard
    @DrewBombard 2 года назад +2

    This is... so spot on and awesome. I love your delivery and explaining *everything* as you go along. Well done.

  •  3 года назад

    The thing I came here for, and got at the end of the video was how to keep plugin installations in version control.
    The answer seem to be to add a wp-cli container and put the commands to run in a dockerfile. Then, each time you start the service, it will run the wp-cli commands and install the plugins.
    Dunno exactly how or if that's persisted in the db, but I'm guessing it's just persisted in the wp-plugins directory and not in the database.
    Will give it a try on my own installation tomorrow. Thanks for a great, educational video.
    Keep em up, you earned yourself a subscriber!

    • @aschmelyun
      @aschmelyun  3 года назад +1

      I'm glad you found that part useful! As for persistence, the wp-cli container networks with the same db container that the main wp installation is using, so it should persist as long as you're using a volume on the MySQL container (or don't spin it down).

  • @blinkapec
    @blinkapec 3 года назад +1

    Thanks for the non-trivial approach (not just "image: wordpress"), in my opinion it is more flexible and interesting, since teaches some additional details regarding dockerization in general.

  • @ColmanByrne
    @ColmanByrne 3 года назад +7

    While WP will run fine , there are some missing modules , gd , imagick , bcmath, exif that can cause some issues with some plugins and themes .
    I would recommend a change to the php.dockerfile to include these , can be left out if you dont need them.
    RUN docker-php-ext-install mysqli pdo pdo_mysql bcmath exif && docker-php-ext-enable pdo_mysql bcmath exif
    RUN set -ex \
    && apk add --no-cache --virtual .phpize-deps $PHPIZE_DEPS imagemagick-dev libtool \
    && export CFLAGS="$PHP_CFLAGS" CPPFLAGS="$PHP_CPPFLAGS" LDFLAGS="$PHP_LDFLAGS" \
    && pecl install imagick-3.4.3 \
    && docker-php-ext-enable imagick \
    && apk add --no-cache --virtual .imagick-runtime-deps imagemagick \
    && apk del .phpize-deps
    RUN apk add --no-cache libpng libpng-dev && docker-php-ext-install gd && apk del libpng-dev
    of course if you add them , rebuild with docker-compose up -d --build site

    • @jenifer5463
      @jenifer5463 2 года назад

      After follow YOUR code i cannot compose file getting error.. Can you help

  • @s0ulAssassin542
    @s0ulAssassin542 2 года назад

    thanks for this awesome tutorial. really helped me to set up a local development environment without resorting to MAMP or something similar

  • @kishanbindal
    @kishanbindal 2 года назад +3

    This video is so well designed! Thank you so much for the time and effort you have put into this informative video!

  • @BruceKoehler
    @BruceKoehler 2 года назад +10

    Hello Andrew, I have just started getting into Docker and I was following along on this video when I ran into a snag. I got up to about the 9:50 mark, when I started the container that went fine, but when I tried refreshing the browser to start WordPress I am getting a 403 Forbidden error. I carefully looked over the code, and I am not seeing anything amiss. Hoping for some advice. Thank you

    • @FranciscoSilva-rf3gw
      @FranciscoSilva-rf3gw 2 года назад

      Hello Bruce, i have the same error, did you manage to solve it?

    • @priyankchouksey7434
      @priyankchouksey7434 2 года назад +3

      @@FranciscoSilva-rf3gw @Bruce Koehler, it is answered partially though. Add below line in the servers section of default.conf file, above locations
      index index.php;

  • @PeterMumford
    @PeterMumford 2 года назад

    This is awesome. Its the best docker-php tutorial yet.

  • @Luca-no3do
    @Luca-no3do 2 месяца назад

    Amazing video Andrew ! Thanks for sharing

  • @SabinMehedin
    @SabinMehedin 3 года назад +3

    Hi Andrew! Great video. I have one question. From your side, it's a good idea to run multiple WordPress project on the same docker env? For example, in the WordPress folder to have wp1 and wp2. Or should be separated?
    And another question. test1.local make a request to test2.local. Why I receive cURL error 6: Could not resolve host: test2.local?
    Thanks in advance.

  • @mantaslukosevicius3175
    @mantaslukosevicius3175 2 года назад

    Best wordpress-docker set-up video.

  • @berroubamohamedelamine8667
    @berroubamohamedelamine8667 Год назад

    Every step was clear and clean, very well explained. thanks a lot.

  • @olekristianmller-hansen4220
    @olekristianmller-hansen4220 Год назад +9

    Hmmm, seems promising, but after creating the nginx/default.conf file and specifying it in the docker-compose.yml file, nginx goes from the default Welcome to nginx page to just showing a generic 403 Access Forbidden page.

    • @erikhendrikson9594
      @erikhendrikson9594 Год назад +1

      same

    • @raselsiddiqe8280
      @raselsiddiqe8280 8 месяцев назад

      got any solution?

    • @KomentarSaya
      @KomentarSaya 8 месяцев назад

      same, its weird

    • @leolaf6501
      @leolaf6501 7 месяцев назад +2

      Check if you miss any semicolons in your config file.
      Also you can run "docker logs -f " followed by the containername of your nginx and see what the error is 😊

    • @ns2304
      @ns2304 9 дней назад

      Press F12 on the browser and go to the network section, look for a title called ‘GET’ which is the get request to load the page. See if you can expand that title and find more info of the file it’s trying to access. It might very well be a permissions issue on Linux. I encountered this when I tried doing a docker project in the home/user folder.try create the project in your root directory

  • @bd4utonite2
    @bd4utonite2 Год назад +2

    followed you youtube tutorial but can get to nginX but cannot get to wordpress.. something about missing mysqli???

  • @AbhinavKulshreshtha
    @AbhinavKulshreshtha 3 года назад +3

    Amazing Tutorial. I have been using compose-file from others because I always ran into one problem or other. But because of your approach of letting things fail and fixing it, I not only ran wordpress, but also successfully ran laravel setup. Now I will try my hand on Laravel-Vue microservice setup because that is what my actual app is using. I am guessing I just need to create another service called node and try to match ports between them just like you did on fpm?

  • @apted
    @apted Год назад

    Really clear and easy to follow tutorial, many thanks. subscribed!

  • @baddogmintz
    @baddogmintz 9 месяцев назад

    It's a splendid tutorial. Thank you. Just one quibble: at around 11:00, where you say, oh, this is crashing because the PHP mysql extension is missing -- there is no way anybody could infer that from the opaque error message that Wordpress displays. It would be nice to know where the error logs are and see for ourselves.

  • @err_0-5rZ
    @err_0-5rZ 2 года назад +3

    For anyone having the error establishing database connection. Make sure you set up your database connection in the wp-config.php file, you will initially see there a wp-config-sample.php file. This tutorial skipped it. Nevertheless, good tutorial! Thanks!

    • @aschmelyun
      @aschmelyun  2 года назад +1

      This is true, and I apologize for that! DB host should be pointing to `mysql`, not the typical localhost.

    • @nomanislam3157
      @nomanislam3157 2 года назад

      9:56 please help How to get wp-config.php file without copy and paste inside wordpress.. Bcz after that plugin and media Don't word.. After all this is best learning methodology...

    • @koerperkontrolle
      @koerperkontrolle 2 года назад

      up because I got stuck there too, makes sense thanks

    • @nomanislam3157
      @nomanislam3157 2 года назад

      By default it was not generated.. Thats problem occur.. How to solve u don’t say that

  • @aaBeben
    @aaBeben 2 года назад

    You are the best tutor. Thanks from Indonesia.

  • @codescholar7345
    @codescholar7345 3 года назад +6

    Great video! This is exactly what I was looking for. Can you show how to push this to a VPS for production?

    • @aschmelyun
      @aschmelyun  3 года назад +11

      I'll add it to my video ideas list!

  • @dhiyaaulauliyaa3988
    @dhiyaaulauliyaa3988 3 года назад

    amazing guide! every step is well explained and doesn't left any confusion, thank you!

  • @ankuradhey
    @ankuradhey 2 года назад

    Bookmarked this. Everything covered nicely. 👍

  • @buchdev
    @buchdev 3 года назад +1

    Nice! Your explanation is so helpful, cool and clear! Thanks... I needed this

    • @aschmelyun
      @aschmelyun  3 года назад +1

      Thank you so much! I'm glad it was helpful.

  • @buundy
    @buundy Год назад +1

    I downloaded your code and after reviewing the video I customized it for my needs. I can start the nginx, mysql and php but I can see in the Docker Desktop that wp cannot be started, or it stops immediately with this error: "less: unrecognized option: r". Do you have an idea what can cause this? Thanks in advance!

  • @deryckoe84
    @deryckoe84 3 года назад

    Excellent video. Could not be better explained. Thanks for sharing this.

  • @ColmanByrne
    @ColmanByrne 3 года назад +7

    Andrew - for info the line try_files $uri $uri / /index.php?$args; yields a 403 forbidden until you remove the second $uri/ - This is caused because nginx will try to index the directory, and be blocked by itself. Throwing the error.
    try_files $uri $uri/ means, from the root directory, try the file pointed by the uri, if that does not exists, try a directory instead (hence the /). When nginx access a directory, it tries to index it and return the list of files inside it to the browser/client, however by default directory indexing is disabled, and so it returns the error "Nginx 403 error: directory index of [folder] is forbidden". see nginx.org/en/docs/http/ngx_http_autoindex_module.html

    • @heliocorreia1359
      @heliocorreia1359 3 года назад +2

      add line
      index index.php;
      with that, nginx will search for index files inside /var/www/html

    • @aschmelyun
      @aschmelyun  3 года назад +2

      @@heliocorreia1359 This is correct. That line was missing from the original video, but is present in the code on GitHub. My apologies!

    • @ColmanByrne
      @ColmanByrne 3 года назад +1

      No problem , and excellent video in any case , really helped me to understand docker setup , I especially liked you showing what can go wrong and how to fix them ! keep it up

    • @itrrmp
      @itrrmp 17 дней назад

      @@heliocorreia1359 that didn't work. I'm still getting 403

  • @hsiehleo4736
    @hsiehleo4736 2 года назад +3

    Hi Andrew, thank you for the great video!
    Unfortunately there is a problem, after I added an /nginx folder to store default.conf and make docker-compose up -d again, what I see is not WP's installation page but '403 Forbidden' page by nginx, could you tell me what happen? I use WSL on Windows 11. Thanks!

    • @erjohn5404
      @erjohn5404 2 года назад

      same problem lmao, this tutorial is 10 months ago so probably the latest update is fucking us up

    • @erjohn5404
      @erjohn5404 2 года назад

      have you fixed it?

    • @spouwn
      @spouwn 2 года назад +11

      in the nginx/default.conf file you need to add this index line in the server configuration:
      root /var/www/html;
      index index.php;

    • @fincampbell
      @fincampbell 2 года назад +1

      @@spouwn Thanks. This helped me today 😅

    • @lascasermas
      @lascasermas 2 года назад +1

      @@spouwn thank you so much :)

  • @mariogenzano
    @mariogenzano 3 дня назад

    I just watched your video and I have to say I found it really interesting. Recently, I've been trying to do exactly the same thing but with the setup of a Real Cronjob. Could you give me some advice on this? How do you configure a Real Cronjob in Docker that works with WordPress? Thank you so much in advance!

  • @katkaadmi
    @katkaadmi Год назад +1

    Hi i follow your step but it's not working. show "403 Forbidden". my os is Ubuntu 20.04

  • @2penry2
    @2penry2 3 года назад +3

    Such an excellent channel, really appreciate the time you've dedicated to helping us learn new things!

  • @josuebarros-desenvolvedorw2490
    @josuebarros-desenvolvedorw2490 3 года назад +5

    Wonderful content!
    Please help us setting the Roots Stack Environment on Docker too! (Bedrock, Sage...)

  • @zunnur1
    @zunnur1 3 года назад

    this the most well explained video regarding docker. Thank you

  • @hanggianggono3765
    @hanggianggono3765 3 года назад

    what a quality step by step explanation!

  • @joshbarros1995
    @joshbarros1995 3 года назад

    Docker + Bedrock + Sage = Paradise

  • @alexanderr1371
    @alexanderr1371 2 года назад +4

    thanks for the great tutorial. I am following along, checked 100 times, and maybe there has been some changes with docker.
    01. When I try to perform the setup I get the error "Error establishing a database connection". I used everything as you have it.
    Is there a solution that you may recommend, please?
    02. It seems that it redirected automatically from "localhost" to "wordpress-docker.test", it doesn't do this automatically for me. Was there something that you did in between?

  • @bluescorpian
    @bluescorpian Год назад

    very helpfull, explained very well how everything works. thanks

  • @AndreiSavelev-u9s
    @AndreiSavelev-u9s 6 месяцев назад

    Awesome!! Thank you for this video!

  • @flipperiflop
    @flipperiflop 3 года назад +1

    If one uses multiple servers, where one has db, other has cache and two others have the webapp itself, would it be smart to have docker only for development, and use some other way to handle the production servers? Or is there a good established way to do this with docker too, where development and deployment have each their own setup? And how would one run only one part of the app on one server?
    Kubernetes might solve the issue, but seems like an overkill for this problem.

  • @pratikbhetwal3670
    @pratikbhetwal3670 Год назад

    When running the docker through a WSL distro(ubuntu in my case), does the second path you specify in the volumes section in 25.15 exist virtually or should the folder exist on the local machine through manual installation(sudo apt insall nginx) of nginx outside the docker environment? I don't understand how the symlinks work. I'm guessing that the /var/www/html folder doesn't actually exist physically on your device either.

  • @mariaalmeida8485
    @mariaalmeida8485 3 года назад +1

    This tutorial absolutely rocks. I followed the tutorial and used the same example URL, but now that I want to change it I can't (even though I changed it in the default.conf). Any tips how to fix it?

  • @ellmatic
    @ellmatic 3 года назад +2

    Perhaps I'm missing something, but why is WordPress manually brought in like that (downloaded and just added)? Can't it be brought in and version controlled/updated in the same way that the other services were, in a composer-like way? I thought that was the whole point of all of this.

    • @aschmelyun
      @aschmelyun  3 года назад

      While WordPress doesn't officially have a composer entry, it is installable through it with 3rd-party forks. However, the point of this video was to demonstrate how to get a local environment up for a new or existing WP site using Docker and separate containers for each process.
      There could be some more streamlining done with this, and I'll take that into consideration when thinking of follow-up videos on this topic!

    • @ellmatic
      @ellmatic 3 года назад

      @@aschmelyun Cool, thanks for taking the time to reply. Looking forward to follow-up content. Cheers!

  • @lucatsf
    @lucatsf Год назад

    That video helped me a lot, thanks, man!

  • @ahmedsayed4140
    @ahmedsayed4140 2 года назад

    An excellent and informative lesson, Thank you so much.

  • @sleeptheory3934
    @sleeptheory3934 3 года назад

    This is how tutorial should be made. i wish i could like more.

  • @mriservice1671
    @mriservice1671 Год назад

    I keep getting an error
    [error] 128#128: *31 FastCGI sent in stderr: "Primary script unknown" while reading response header from upstream,

  • @masterpayne5982
    @masterpayne5982 2 года назад +1

    I am having problems with permissions. It would appear as if the container uses a user called "82 [82]". It is breaking a lot of things in WordPress like media and plugins, along with updates. If anyone has the time to help please give it. I don't know how to share permissions with a user that is in a docker container.

  • @dionoliphant7026
    @dionoliphant7026 Год назад

    I get an issue with adding a post(API JSON error) as well as when updating plugins and worpress as well as themes - FTP details are requested.

  • @jmora7101
    @jmora7101 7 месяцев назад

    great job but why use this instead of xampp, wamp, local or laragon?

  • @user-tt6nc6mo7k
    @user-tt6nc6mo7k 3 года назад +1

    Clear and concise! Would like to know how you added the custom domain name? Is there a way to have that done automatically similar to laravel valet where the directory name is taken as the domain name?

    • @ColmanByrne
      @ColmanByrne 3 года назад +1

      Edit your hosts file and add line 127.0.0.1 wordpress-docker.test ( on windows this is in C:/windows/system32/drivers/etc - but edit as administrator !)

    • @jamiedoig9568
      @jamiedoig9568 3 года назад

      @@ColmanByrne Thanks! For anyone else doing this just add it below the # comments when editting the hosts.file in visual studio code

  • @josepolanco9147
    @josepolanco9147 2 года назад

    Hi Andrew!
    I mounted a server without nginx on dockers. I started toying around and dind't follow a guide to make this server https compatible before changing this on the wordpress settings.
    I ended up wrecking my whole docker instance. I ended up erasing also the DB associated with Wordpress. I tried closing down the docker instance and composing up again, but to no good.
    Is there a 'hard-reset' to start all over again?
    Appreciate your help :)

  • @ТарасПроцишин-з5ц
    @ТарасПроцишин-з5ц 9 месяцев назад

    Hi! Thanks a lot for your content! Could you leave links to src file in descriptions, pls.

  • @urushadze
    @urushadze 3 года назад +1

    What about deployment on the server :3 I am searching for it now

  • @2mahender
    @2mahender Год назад

    do you have single Dockerfile with alpine base image installed with wordpress,php,nginx?

  • @visualmodo
    @visualmodo 3 года назад

    Excellent WordPress guide!

    • @aschmelyun
      @aschmelyun  3 года назад

      Thank you! I’m glad you liked it.

  • @Daan007
    @Daan007 2 года назад

    Hi Andrew, great video. this is for localhost what changes do i have to add to deploy this on app service or ACI in Azure? many thank for the reply! have a great day..

  • @omerta3393
    @omerta3393 Год назад

    Awesome! How we can create multiple WordPress sites on local this way?

  • @robdorn420
    @robdorn420 3 года назад +1

    Excellent video again.
    Would be nice if you would make a video on implementing xdebug. Currently struggling to get that working with docker, php and vscode.

    • @aschmelyun
      @aschmelyun  3 года назад

      Great idea! I love xdebug, I'll be sure to add that to my video list.

    • @ColmanByrne
      @ColmanByrne 3 года назад

      could Add following to php.dockerfile
      RUN apk add --no-cache --virtual .build-deps $PHPIZE_DEPS \
      && pecl install xdebug \
      && docker-php-ext-enable xdebug \
      && apk del -f .build-deps
      needs additional config to setup new mode and ide key etc for new xdebug 3 works as far as loading xdebug in php , but have not figured out the additional configs yet to get it to work on VSCODE , next task !

    • @robdorn420
      @robdorn420 3 года назад +1

      @@ColmanByrneI have XDEBUG already up and running, but thank you anyway for your response.

  • @andreasgaschka
    @andreasgaschka 3 года назад

    Great starter tutorial.
    I have trouble uploading larger files, either media or plugins. Any help here?

  • @chandalasaturnino8213
    @chandalasaturnino8213 2 года назад +1

    Great, thanks a lot. The only think I'm not getting right is the certs. Chrome says it's not good. Cheers.

  • @jethrolanda1752
    @jethrolanda1752 Год назад

    hi guys, does anyone know how can I fix the add plugins page. I am unable to download and install plugins. This is also the same in cli command. TIA

  • @ahrorbekmirzaev8332
    @ahrorbekmirzaev8332 3 года назад

    Great video! Thx for helpful information

  • @topsydhaka
    @topsydhaka 2 года назад

    Hi Thank you for the video, very helpful. What is entrypoint: ['wp', '--allow-root'] for?

  • @christerjohanzzon
    @christerjohanzzon 3 года назад +1

    Great tutorial!
    Unfortunately my Wordpress installation is slow, takes -+7 seconds to load a single page. I'm running Windows 10 and Docker on a SSD, so it should not be so slow. Is there any way I can improve speed?

    • @diegogonzalezcruz6952
      @diegogonzalezcruz6952 2 года назад

      Hi, did you solve it?

    • @jorgearaya4712
      @jorgearaya4712 2 года назад

      I have the same issue, did some research and WSL2 seems to be the issue, if you have windows on its pro version you can disable it in docker dashboard > settings > General > Use WSL2 based engine

    • @jarnoojasaar
      @jarnoojasaar Год назад

      @@jorgearaya4712 hyper-v isn't just faster on Windows, it also uses only 2GB of ram instead of WSL2 which uses 4+ GB when running the wordpress container.

  • @queue6844
    @queue6844 Год назад

    With a few tweaks it worked thanks 🙂

  • @codehorror8076
    @codehorror8076 2 года назад

    In the wpcli.dockerfile add a RUN command "RUN apt update && apt install mysql-client". If you don't you can not use wpcli, it will complain about mysql not being found.

  • @robotjeans
    @robotjeans 3 года назад

    Excellent walkthrough

  • @DiversityAndOne6
    @DiversityAndOne6 Год назад

    my web browser Edge gives me the 403 error forbidden. how do i resolve this ?

  • @hanschannel599
    @hanschannel599 2 года назад

    thanks, Andrew! I learn a lot!

  • @PathOfDamn
    @PathOfDamn 3 года назад

    Sorry if this was answered before, but since I'm using windows and I DON'T want to use HyperV for Docker (I'm using VirtualBox for other things), and that I can't really use WSL2 at the moment (can't afford a restart, too many things running LOL), do you think it is recommended that I spin up a debian-testing vm, install docker engine in there, and then through VSCode's Remote Dev extension I develop things with docker in that vm?
    I mean, yea, I can just dual-boot, but I think I'm too swamped with work atm to reorganize my stuff. Sorry if this was a dumb question.

    • @aschmelyun
      @aschmelyun  3 года назад

      Not a dumb question at all! That definitely sounds like a complicated setup, and I think the solution you laid out sounds pretty good for your scenario. Especially if you're just doing local dev, your VM shouldn't need that much resource allotment for the Docker instance.

    • @PathOfDamn
      @PathOfDamn 3 года назад

      @@aschmelyun Thanks for the reply, I'm slowly transferring my dev environments over to docker, since VM with snapshots are taking a tad bit too much space for my liking.
      My current environment is more like anything I've not handed off yet or that I need to maintain, I'm sticking with what I had. But any new projects coming my way or things I need to do for the team I'm in, I put them in docker. No doubt my projects are slowly cleaning up, and it's.. a chore, to put it kindly, to reorganize things when everything is being worked on.

  • @rickpereira8821
    @rickpereira8821 3 года назад

    At 8:17 I got the error "Error response from daemon: invalid mount config for type "bind": bind source path does not exist: /run/desktop/mnt/host/e/wordpress-docker-test/wordpress"
    Working in Docker for Windows (WSL) so that might be why I'm having such a hard time with this stuff...

  • @caponero7110
    @caponero7110 Год назад

    Is possible to use Dbeaver for this enviroment? thank you in advance

  • @ajlozadaro
    @ajlozadaro Год назад

    Wow, amazing tutorial!

  • @robeeeeen
    @robeeeeen 2 года назад

    What should be done if multiple wordpress sites needs to configure like virtualhost?

  • @MajesticRiderTales
    @MajesticRiderTales 3 года назад +2

    9:52 >> how did you get that wordpress installation page

    • @aschmelyun
      @aschmelyun  3 года назад +2

      After running the docker-compose up command, I just navigated to localhost. In this case, I set an entry in my /etc/hosts file to 127.0.0.1 wordpress-docker.test to get a fake URL in my browser.

    • @MajesticRiderTales
      @MajesticRiderTales 3 года назад

      @@aschmelyun yeah I heard that in the video but can you please share the steps to do that. Thank you

    • @ellmatic
      @ellmatic 3 года назад

      @@MajesticRiderTales He just told you. Add an entry in your /etc/hosts file so that wordpress-docker.test points to localhost (127.0.0.1).

  • @YasserHawass
    @YasserHawass 3 года назад

    if you're on windows & having troubles following the tutorial after 8:00
    You might need to update File Sharing configuration in your Docker for Windows app to include your work directory :"D

  • @gasperzargi5715
    @gasperzargi5715 2 года назад

    Great tutorial, thanks.
    If one would like to use this with apache server, how would default.conf file Look like for apache?
    Thank you

  • @petalaak
    @petalaak Год назад

    Nice tutorial! One thing popped into my mind: before firing up the development environment, Wordpress needs to be downloaded into local machine and extracted into /wordpress directory. This is makes sense if you're developing existing project: just drop it into /wordpress directory and continue developing it. However, it would be handy if you didn't have wordpress already in /wordpress directory, it would be downloaded automatically when the containers are started. This would allow to use this as a handy way of starting a new Wordpress project. I know it's not big of a deal to go get Wordpress and extract it, but automatic is always automatic! :D How complicated would adding this sort of functionality be?

    • @BorisBurtin
      @BorisBurtin Год назад

      I hit the same issue. I expected that something needs to go into the *./wordpress* directory, but I don't believe that it's mentioned in the video.

    • @faaith100
      @faaith100 Год назад

      You could be doing that but consider that the fact that manually adding code is a one-time only process. So it makes sense not to add logic into the startup to fulfill this need. You'd basically need a script in the entrypoint that:
      - Checks if there's a /wordpress directory. If there isn't:
      - Downloads the latest version
      - Installs an unzip tool in the container (further adding dependencies that we don't want in a docker container)
      - Unzips
      Then if you've mapped the volume correctly, from outside of the container to the local folder, you should see the wordpress files there.
      I mean that could work if you're really doing multiple wordpress sites. But for a one off, I don't think it is worth the hassle. Even if you're running a big marketing agency, you'll probably have the boilerplate repository with everything to go. This also gives you the capability to manually decide when you want to use a new wordpress version. Specially if there's major/breaking changes involved compared to the old one you were using.

  • @heliocorreia1359
    @heliocorreia1359 3 года назад +1

    I have a permission error. Someone went through this.
    "It was not possible to write data to the wp-config.php file.
    You can create wp-config.php file manually and paste the following text into it."
    how to solve this? I even created the wp-config manually, but do not install any plugins. Thanks

    • @ColmanByrne
      @ColmanByrne 3 года назад +1

      chmod -R 777 the wordpress folder

    • @aschmelyun
      @aschmelyun  3 года назад +3

      What Colman said is a good workaround. If you check out the pinned GitHub there's a fix for this in the php.dockerfile that handles chown of the volume's files.

    • @rao.manoj.0
      @rao.manoj.0 2 года назад

      @@aschmelyun
      add wp as the user with uid 1000 didn't work for me. What am I missing?

    • @osoverlord
      @osoverlord Год назад

      @@aschmelyun Do you mean RUN chown wp:wp /var/www/html ? If so, then unfortunately after I've installed wp with wp cli and ran --build site - I still can't change the wp-content folder and all files in it :( plz help

  • @JuanitoOrtega
    @JuanitoOrtega 3 года назад

    Nice video, please how do you set domain kind .test?... can you share how do you do that please?.. Thank you.

  • @laugedyret
    @laugedyret 3 года назад

    Super video, thanks!

  • @kilhrorn
    @kilhrorn 3 года назад

    I followed every steps, but can't get the same results at 13:30, i get a database connection error :'(

  • @SelasNight
    @SelasNight 3 года назад

    Hi Andrew, thanks for the tutorial. i was trying it out but can't seem to get the wp container to start. The log says
    less: unrecognized option: r
    I can still install wordpress and access the dashboard on localhost but the container is grayed out. Please advise. Thanks again for the great tutorials!

    • @overw0rld
      @overw0rld 2 года назад

      Add following line to your php.dockerfile:
      ENV PAGER=more

  • @bosphoramus
    @bosphoramus 3 года назад

    Amazing tutorial, thanks

  • @DevenSitapara
    @DevenSitapara 2 года назад

    Thank you very very much Andrew