Skip to content

Commit

Permalink
Php7 (#11)
Browse files Browse the repository at this point in the history
* Update Dockerfile

* Update phpstorm.desktop

* Update README.md
  • Loading branch information
gabidi authored and iainmckay committed Dec 13, 2016
1 parent 1525186 commit 392604d
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 10 deletions.
8 changes: 4 additions & 4 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -14,11 +14,11 @@ RUN apt-get update && \
rm -rf /tmp/*

RUN useradd -m -s /bin/bash developer \
&& mkdir /home/developer/.PhpStorm2016.2 \
&& touch /home/developer/.PhpStorm2016.2/.keep \
&& mkdir /home/developer/.PhpStorm2016.3 \
&& touch /home/developer/.PhpStorm2016.3/.keep \
&& chown -R developer.developer /home/developer \
&& mkdir /opt/phpstorm \
&& wget -O - https://download.jetbrains.com/webide/PhpStorm-2016.2.tar.gz | tar xzf - --strip-components=1 -C "/opt/phpstorm"
&& wget -O - https://download.jetbrains.com/webide/PhpStorm-2016.3.tar.gz | tar xzf - --strip-components=1 -C "/opt/phpstorm"

RUN php -r "readfile('https://getcomposer.org/installer');" | php -- --install-dir=/usr/bin
RUN phpenmod curl gd gmp json ldap mysql odbc pgsql pspell readline recode snmp sqlite3 tidy xml xmlrpc bcmath bz2 enchant imap interbase intl mbstring mcrypt soap sybase xsl zip xdebug memcache memcached
Expand All @@ -28,5 +28,5 @@ RUN pear install PHP_CodeSniffer
RUN npm install -g bower

USER developer
VOLUME /home/developer/.PhpStorm2016.2
VOLUME /home/developer/.PhpStorm2016.3
CMD /opt/phpstorm/bin/phpstorm.sh
10 changes: 5 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
# docker-phpstorm

Jetbrains PhpStorm 2016.2 running inside a docker container. This project is derived from [`fgrehm/docker-netbeans`](https://github.com/fgrehm/docker-netbeans).
Jetbrains PhpStorm 2016.3 running inside a docker container. This project is derived from [`fgrehm/docker-netbeans`](https://github.com/fgrehm/docker-netbeans).

## Features

* PhpStorm 2016.2
* PhpStorm 2016.3
* PHP 7
* composer
* graphviz
Expand All @@ -19,12 +19,12 @@ To launch PhpStorm we need to provide the current display and your X11 socket. Y
$ docker run -it --rm \
-e DISPLAY=$DISPLAY \
-v /tmp/.X11-unix:/tmp/.X11-unix \
-v ~/.PhpStorm2016.2:/home/developer/.PhpStorm2016.2 \
-v ~/.PhpStorm2016.3:/home/developer/.PhpStorm2016.3 \
-v ~/Projects:/workspace \
iainmckay/phpstorm:2016.2-php7
iainmckay/phpstorm:2016.3-php7
```

With this your configuration will be persisted to `/home/<user>/.PhpStorm2016.2` so that you don't lose it over subsequent runs. It also makes any sourcecode under `/home/<user>/Projects` available to PhpStorm. Inside the dockerized environment, it will be available through `/workspace`.
With this your configuration will be persisted to `/home/<user>/.PhpStorm2016.3` so that you don't lose it over subsequent runs. It also makes any sourcecode under `/home/<user>/Projects` available to PhpStorm. Inside the dockerized environment, it will be available through `/workspace`.

Note: Remember to change the ownership of the config directory on the host as it will be created as root if it does not already exist and PhpStorm won't be able to write to it.

Expand Down
2 changes: 1 addition & 1 deletion support/launcher/phpstorm.desktop
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[Desktop Entry]
Name=PhpStorm
Exec=sh -c "docker run --rm -e DISPLAY=$DISPLAY -v /tmp/.X11-unix:/tmp/.X11-unix -v ~/.PhpStorm2016.2:/home/developer/.PhpStorm2016.2 -v ~/Projects:/workspace iainmckay/phpstorm:2016.2-php7"
Exec=sh -c "docker run --rm -e DISPLAY=$DISPLAY -v /tmp/.X11-unix:/tmp/.X11-unix -v ~/.PhpStorm2016.3:/home/developer/.PhpStorm2016.3 -v ~/Projects:/workspace iainmckay/phpstorm:2016.3-php7"
Icon=phpstorm
Terminal=false
Type=Application
Expand Down

0 comments on commit 392604d

Please sign in to comment.