-
Notifications
You must be signed in to change notification settings - Fork 28
/
Dockerfile
36 lines (27 loc) · 1.38 KB
/
Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
FROM wordpress:latest
LABEL maintainer="[email protected]"
ARG PackageName
ARG PackageVersion
ARG NexusUser
ARG NexusPassword
RUN apt-get update -y
RUN apt-get install -y --no-install-recommends wget unzip
RUN /bin/mkdir -p /var/www/html/wp-content/plugins/froala
COPY . /var/www/html/wp-content/plugins/froala
RUN wget --no-check-certificate --user ${NexusUser} --password ${NexusPassword} https://nexus.tools.froala-infra.com/repository/Froala-npm/${PackageName}/-/${PackageName}-${PackageVersion}.tgz \
&& sleep 10 \
&& tar -zxvf ${PackageName}-${PackageVersion}.tgz \
&& /bin/cp -rf package/css/* /var/www/html/wp-content/plugins/froala/public/css/ \
&& /bin/cp -rf package/js/* /var/www/html/wp-content/plugins/froala/public/js/ \
&& rm -rf /var/www/html/wp-content/plugins/froala/admin/css/* \
&& rm -rf /var/www/html/wp-content/plugins/froala/admin/js/* \
&& /bin/cp -rf package/css/* /var/www/html/wp-content/plugins/froala/admin/css/ \
&& /bin/cp -rf package/js/* /var/www/html/wp-content/plugins/froala/admin/js/ \
&& chown -R www-data:www-data /var/www/html/wp-content/plugins \
&& /bin/cp -r package /
RUN wget https://raw.githubusercontent.com/wp-cli/builds/gh-pages/phar/wp-cli.phar \
&& chmod +x wp-cli.phar \
&& cp -p wp-cli.phar /usr/local/bin/wp \
&& cd /var/www/html/ \
&& echo "wp-cli installed..."
EXPOSE 80