Giter Site home page Giter Site logo

drupal's Introduction

Maintained by: the Docker Community (not the Drupal Community or the Drupal Security Team)

This is the Git repo of the Docker "Official Image" for drupal (not to be confused with any official drupal image provided by drupal upstream). See the Docker Hub page for the full readme on how to use this Docker image and for information regarding contributing and issues.

The full image description on Docker Hub is generated/maintained over in the docker-library/docs repository, specifically in the drupal directory.

See a change merged here that doesn't show up on Docker Hub yet?

For more information about the full official images change lifecycle, see the "An image's source changed in Git, now what?" FAQ entry.

For outstanding drupal image PRs, check PRs with the "library/drupal" label on the official-images repository. For the current "source of truth" for drupal, see the library/drupal file in the official-images repository.


  • build status badge
  • build status badge
Build Status Badges (per-arch)
amd64 build status badge arm32v5 build status badge arm32v6 build status badge arm32v7 build status badge
arm64v8 build status badge i386 build status badge mips64le build status badge ppc64le build status badge
s390x build status badge put-shared build status badge

drupal's People

Contributors

bushong1 avatar davidbarratt avatar docker-library-bot avatar greggles avatar hehongbo avatar ibobik avatar j0wi avatar jonathanthiry avatar knickers avatar mayeco avatar robertdebock avatar skyred avatar sylus avatar tanarurkerem avatar thom8 avatar tianon avatar yosifkit avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

drupal's Issues

Set UID and GID on Run

It would be nice to match existing UID's and GID's on shared volumes. This should be a trivial addition.

Is a Volume Needed?

Drupal would require some local storage for images and the like, right? So in order for the container to be persistent wouldn't I need to include a volume as well as the database?

If it is needed, I'm confused as to why the official Wordpress Dockerfile specifies a volume while the official Drupal Dockerfile does not?

missing php.ini file containing the date.timezone parameter

I've come accross this error when accessing the drupal 8.0.1 container front page as anonymous visitor:

Uncaught PHP Exception Exception: "DateTime::__construct(): It is not safe to rely on the system's timezone settings. You are required to use the date.timezone setting or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected the timezone 'UTC' for now, but please set date.timezone to select your timezone." at /var/www/html/core/lib/Drupal/Core/EventSubscriber/FinishResponseSubscriber [...]

Looking to the php image page, adding a php.ini in the dockerfile seems to be recommended. I don't know if this should be in this dockerfile or just documented on the page, since the appropriate timezone might be different for every user...

cookies for features?

ciao,

i'm one of two maintainers of that Drupal-image. that image aims to provide an easily extendable vanilla Drupal-experience as well as a base for also easily customized Drupal-images. notably, it features:

  • environment-based configuration of
    • database-settings
    • PHP's UPLOAD- & MEMORY_LIMIT
  • an entrypoint.sh that provides hooks for an inital setup (default if no db is detected) and pre-launch
  • convenient drush-usage in scripts and bash
  • Drupal's recommended PHP-settings and -extensions
  • default-settings, so a vanilla-instance passes security-review

if you think that any of these features fits to this image, we offer to upstream it. feel free to review the repository in question. depending on your response we'd prepare commits then.

by that opportunity, are there plans to publish guidelines what functionality an image from this library sould or must not provide?

Add Drush

Are you open to include Drush into this image? If yes, I will prepare PR, if not I will do it in my derivated image.

GD library FreeType support

Drupal 8 throws this warning:

The GD Library for PHP is enabled, but was compiled without FreeType support. Image effects using fonts will not be available with the GD image toolkit.

Configuring the drupal docker container to use an AWS RDS DB

The current drupal container doc describes the use of the deprecated docker link facility to 'link' a drupal container to a local db container.

First, this is bad - you need stop using link.

Second, using the drupal container with an external DB seems like a pretty common case - much more common than running the db as a local container. Why is there no doc for this case?

I need to connect a drupal container to an RDS DB instance. I'm hoping that by creating a settings.php with the correct config and building a new drupal container with this settings.php in /var/www/html/ this will config drupal to use my RDS DB.

How do I verify if this is working? Is there some other solution to this issue?

PHP Startup: Unable to load dynamic library 'gd.so'

I'm using the current rc-fpm container image. It appears that for some reason php-fpm can't find gd.so in the container even though it is in the container.

When I run the container with the default Cmd (php-fpm) it logs this warning:

[14-Feb-2018 21:55:01] NOTICE: PHP message: PHP Warning: PHP Startup: Unable to load dynamic library 'gd.so' (tried: /usr/local/lib/php/extensions/no-debug-non-zts-20170718/gd.so (libpng16.so.16: cannot open shared object file: No such file or directory), /usr/local/lib/php/extensions/no-debug-non-zts-20170718/gd.so.so (/usr/local/lib/php/extensions/no-debug-non-zts-20170718/gd.so.so: cannot open shared object file: No such file or directory)) in Unknown on line 0
Usage: php [-n] [-e] [-h] [-i] [-m] [-v] [-t] [-p ] [-g ] [-c ] [-d foo[=bar]] [-y ] [-D] [-F [-O]]

In fact, gd.so is exactly where it should be in the container:

core@ip-10-0-6-213 ~ $ docker ps
CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES
deb8ab170e4c nginx:alpine "nginx -c /etc/nginx/" 2 days ago Up 2 days lb-cntnr
b629fbab59e7 drupal:rc-fpm "docker-php-entrypoin" 2 days ago Up 2 days drupal-cntr
core@ip-10-0-6-213 ~ $ docker exec b629fbab59e7 ls /usr/local/lib/php/extensions/no-debug-non-zts-20170718/
gd.so
mbstring.so
opcache.a
opcache.so
pdo.so
pdo_mysql.so
pdo_pgsql.so
zip.so

No way to persist data

There should be a VOLUME entry in the Dockerfile at /var/www/html so that you can install modules and persist data. Otherwise I'd have to re-build a custom container image to achieve what should be a default. Please take a look at what Wordpress and Joomla are doing with their Dockerfiles.

php7.0-fpm not work

Hey I think there are somthing wrong on this file. The Nginx service is missing and I didnt see the php7.0-fpm on this images when I built on my self.

Please take a look on this file :)

Issue with permissions

When I try to install a module a get an error that I don't have permissions for writing in the module folder.

Can you guys add change permission to the dockerfile?

Need for a security warning related to modules, themes and profiles directories

I see that in #28 that the Dockerfile was modified to make extension related directories (modules, themes, and profiles) web server writable. I can see why this was done -- it makes it possible to install themes and modules via the admin UI -- but it's arguably a security hole, since it greatly increases the surface for attacks that work by adding malicious executable code to an install.

While I'd guess that small drupal installs that use the admin UI install feature is an important use case here, we may want to add a note to README.md indicating that volumes mounted at those points should only be writable if you intend to do this. Otherwise, users of the image would be better off with root.root ownership on these directories.

The same could be said about settings.php as well.

PHP version

Currently image use php:5.5-apache.

Drupal 7 have no problem with php:5.6, so why not use it?

Ldap Connection

I've noticed that this dockerfile has no a php ldap extension, is any future version bunded with php ldap extension?

make automated builds available for quicker deployment of maintenance/security releases

Drupal 8.0.4, Drupal 7.43, and Drupal 6.38, maintenance releases which contain fixes for security vulnerabilities, have been released on February 24, 2016 at 6:36pm.

This official image repo does not seem to create automated-builds, or if it is, it hasn't picked these releases yet.

Are there any plans to streamline the image building, so that we can deploy updates quicker and fix security vulnerabilities ASAP after their disclosure?

Do we want to support Email/Contact?

Both D7 and D8 ship with Contact Module, which generates a web form and send the inquiry to Emails. With this image, this function doesn't work, because there is no email server included in the image.

So, I am wondering if we want to support this Core function in this image?

Problem with volumes

I'm trying to run a Drupal container but I keep getting this error. https://gyazo.com/a7c50a1d8cf9502a3f667063352a425e

I used the following command to create a container with the necessary volume mounts:
docker run --name drupal -p 80:80 -v /data/drupal/sites:/var/www/html/sites/default/files -v /data/drupal/themes:/var/www/html/themes -v /data/drupal/profiles:/var/www/html/profiles -v /data/drupal/modules:/var/www/html/modules --link redis:redis --link mariadb:mysql -d drupal

I'm doing something wrong or is this a known issue?

Support Drupal Distributions

I think with a little bit of work, along with the changes I proposed in #63 , we could make it possible for Drupal distribution maintainers to inherit from these images to provide Docker images for their distributions.

Distributions are pre-packaged combinations of Drupal core and other selected modules, themes, etc. Examples include OpenAtrium (https://www.drupal.org/project/openatrium), Commerce Kickstart (https://www.drupal.org/project/commerce_kickstart), and farmOS (https://www.drupal.org/project/farm).

Currently, the Dockerfiles create two environmental variables:

ENV DRUPAL_VERSION 7.50
ENV DRUPAL_MD5 f23905b0248d76f0fc8316692cd64753

These are used to download and verify the packaged drupal codebase:

curl -fSL "http://ftp.drupal.org/files/projects/drupal-${DRUPAL_VERSION}.tar.gz"

echo "${DRUPAL_MD5} /usr/src/drupal-${DRUPAL_VERSION}.tar.gz" | md5sum -c -

Drupal distributions can be downloaded and verified using the same pattern, except instead of "drupal" they use their project name (ie: "farm").

As a first step, we can add an additional environmental variable:

ENV DRUPAL_PROJECT drupal

And use that to build the download URL:

curl -fSL "http://ftp.drupal.org/files/projects/${DRUPAL_PROJECT}-${DRUPAL_VERSION}.tar.gz"

There are a few other things to figure out... the code changes introduced in #63 automatically compare the "current" and "desired" Drupal versions using Drush. But that only looks at the Drupal core version. A distribution will have it's own version on top of the Drupal core version. So we will need to tweak the way that version comparison code works too.

Drupal 8 sqlite3 feature add

Hi there,

I pulled the Drupal 8, installed via sqlite. When I come to install drush and do some things in it, got very stuck because the sqlite3 library wasn't installed. Commands like drush dl and drush status would work, but nothing which touched the database.

Eventually ran drush with debug mode and realised it needed the sqlite3 library.

Might be something to add along with pdo_mysql and pdo_postgresql in the install to smooth the path for users.

Regards,

Cameron

Make this work similar as WordPress using docker-compose

(!docker newbie!)

Yesterday I ran docker-compose using https://hub.docker.com/_/wordpress/ which has a way better UX then trying https://hub.docker.com/_/drupal/

WP was a no brainer but Drupal lacks a docker compose file so I got stuck. I could have used __ SQLite__

AFAIK we need environment variables first to link the two containers together?

Is it worth the effort to create this docker-compose.yml file and if so what steps are there to take?

link mySql

Hello, this is how I started my drupal instance

  1. create the mysql container docker run --name some-mysql -e MYSQL_ROOT_PASSWORD=drupal -d mysql
  2. create and link drupal: docker run --name some-drupal --link some-mysql:mysql -p 8080:80 -d drupal

image

I visit my ip:8080 and start the installation and none of my mysql creds are linked.
image

Shouldn't I not need to go through the db setting if I have a mySql linked?

Create Drupal image with preinstalled theme

In my docker-compose I have a mysql image and this drupal image. I started it and installed a new theme. However, when I remove the drupal image and create a new one the themes are gone. They're still in the database though, because I don't delete it.

Is there a possibility to create an image with a preloaded theme? What I managed to do was to create the image with preconfigured settings. I set up my Drupal site, then copied the settings.php to my host and in the Dockerfile this file is added back again to the container. This skips the installation progress, however, the site doesn't work correctly because of the themes.

And when I copy all the contents of default/files as well I get at least a bit of a theme, but there are still many css/js missing. So, is there a way to create the image, with a preloaded theme, throw it away, create a new one and still have the theme?

how to use drupal fpm container with nginx container

How to use together nginx and drupal:8-fpm container?

In my practice nginx and php-fpm containers should have common volume with servable script (drupal).

As I understand, drupal:8-fpm image has drupal sources inside container (added on build stage).

Is it possible to serve drupal:8-fpm through nginx container?

Question about tests

Hi I have a quick question about how the automated Travis tests work. My pull request failed to pass and I'm trying to understand why so I can fix it: #63

It seems that the override-cmd test is failing in my branch. The entrypoint script in my branch outputs some status messages using echo. Is that what's causing the override-cmd test to fail? Does that test expect to ONLY see the "hello world" output that it generates, and nothing else?

https://github.com/docker-library/official-images/blob/master/test/tests/override-cmd/run.sh

Any insight or advice you can provide would be welcome! Thanks!

Root permissions

I don't know if some tried but if you want to use a module like monolog or rabbitmq you need to use composer (and is not in!) also because you are root, if you don't have that in mind when you use drush or something it will be create files with root and in your local too

PHP EXIF extension

Drupal 8 throws this warning:

The PHP EXIF extension is not installed. Automatic image orientation effects will not be available with the GD image toolkit.

Add tag for PHP FPM

Apache with PHP FPM is much better than mod_php. How about to provide alternative?

Can't mount /var/www/html/ to host

I wanted to mount /var/www/html/ to a host folder but when I do so. Drupal seems to not install at all,

Is there some work around this problem?

Add alpine fpm variant

Just adding some awesome alpine support. ^_^

I didn't touch the apache conf given:

docker-library/php#259

I also updated the update.sh script but wasn't sure if any changes needed to the generate-stackbrew-library.sh file.

P.R: #72

Cannot load the latest drupal 8

i use the command below try install drupal 8 latest version.

sudo docker run --name d8docker9 --link drupaldb3:mysql -p 8892:80 -d drupal:8.0.0

but it always load drupal rc2 no matter i try drupal:8 drupal:latest drupal:8.0.0

thanks your help ~

image

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.