Path: csiph.com!fu-berlin.de!uni-berlin.de!individual.net!not-for-mail From: Arno Welzel Newsgroups: comp.lang.php Subject: Re: docker: wordpress: Call to undefined function yaml_parse_file() Date: Sat, 1 Aug 2020 16:40:09 +0200 Lines: 52 Message-ID: References: Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-15 Content-Transfer-Encoding: 7bit X-Trace: individual.net n38N4wXhUDYU7ZAfboRCig7ncTuTkuJ4wwGQBJm8SYpf8MkH9z Cancel-Lock: sha1:c8LQFPVRot8pSwH78eN9n0cWPUw= In-Reply-To: Xref: csiph.com comp.lang.php:18310 SuperTex: > Il 30/07/20 15:40, Arno Welzel ha scritto: >> SuperTex: >> >>> Il 29/07/20 12:49, Arno Welzel ha scritto: >>>> SuperTex: >>>> >>>>> $ curl http://localhost:8000 >>>>> >>>>> Among other things, appears: >>>>> >>>>> Fatal error: Uncaught Error: Call to undefined function >>>>> yaml_parse_file() in /var/www/html/wp-content/plugins/mytest/main.php >>>>> >>>>> I suppose you need to install the php-imap extension (or something similar). >>>> >>>> No - YAML has nothing to do with IMAP. YAML is handled php-yaml. >>>> >>>> If you created this plugin yourself you should think about using plain >>>> PHP files for configuration instead of YAML. Developing WordPress >>>> plugins which depend on the YAML extension is not a good idea. >>> >>> I apologize. >>> I meant php-yaml extension (or something similar). >>> >>> But can't you just install php extensions in docker/wordpress? >> >> See this: >> >> >> >> But anyway: relying on php-yaml is not a good idea if you ever want to >> use your WordPress plugin anywhere outside your own local docker setup. >> > > -- SNIPPET --- > wordpress: > dockerfile: extensions > #image: wordpress:latest > --- END SNIPPET --- > > $ docker-compose build > The Compose file './docker-compose.yml' is invalid because: > Unsupported config option for services.wordpress: 'dockerfile' You should read the ANSWERS there and not the QUESTION. -- Arno Welzel https://arnowelzel.de