This repository has been archived by the owner on Apr 4, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 111
Add docker file to prepare PHP dev image #239
Closed
Closed
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
# Copyright (c) 2019 Red Hat, Inc. | ||
# This program and the accompanying materials are made | ||
# available under the terms of the Eclipse Public License 2.0 | ||
# which is available at https://www.eclipse.org/legal/epl-2.0/ | ||
# | ||
# SPDX-License-Identifier: EPL-2.0 | ||
# | ||
# Contributors: | ||
# Red Hat, Inc. - initial API and implementation | ||
|
||
FROM php:7.1-apache | ||
|
||
RUN apt-get -y update \ | ||
&& apt-get install -y libicu-dev\ | ||
tree \ | ||
vim \ | ||
wget \ | ||
git \ | ||
libzip-dev \ | ||
zlib1g-dev \ | ||
zip \ | ||
&& docker-php-ext-configure intl \ | ||
&& docker-php-ext-install intl \ | ||
&& docker-php-ext-configure zip --with-libzip \ | ||
&& docker-php-ext-install zip mysqli pdo pdo_mysql \ | ||
&& chmod -R 777 /etc/apache2 /var/www /var/lib/apache2 /var/log \ | ||
&& chown -R www-data:www-data /var/www \ | ||
\ | ||
#change Apache configuration | ||
\ | ||
&& sed -i "s/80/8080/g" /etc/apache2/sites-available/000-default.conf /etc/apache2/ports.conf \ | ||
&& sed -i 's/\/var\/www\/html/\/projects/g' /etc/apache2/sites-available/000-default.conf \ | ||
&& sed -i 's/\/var\/www/\/projects/g' /etc/apache2/apache2.conf \ | ||
&& sed -i 's/None/All/g' /etc/apache2/sites-available/000-default.conf \ | ||
&& echo "ServerName localhost" | tee -a /etc/apache2/apache2.conf | ||
|
||
#add composer | ||
COPY --from=composer:latest /usr/bin/composer /usr/bin/composer | ||
|
||
WORKDIR /projects | ||
|
||
CMD sleep infinity |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
#!/bin/bash | ||
# | ||
# Copyright (c) 2019 Red Hat, Inc. | ||
# This program and the accompanying materials are made | ||
# available under the terms of the Eclipse Public License 2.0 | ||
# which is available at https://www.eclipse.org/legal/epl-2.0/ | ||
# | ||
# SPDX-License-Identifier: EPL-2.0 | ||
# | ||
|
||
base_dir=$(cd "$(dirname "$0")"; pwd) | ||
. "${base_dir}"/../build.include | ||
|
||
init --name:php-dev "$@" | ||
build |
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
hello, there is no plugin endpoint in that image ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
hello, it think there isn't. This image extends official php:7-apache and will be used in dev container in PHP stack