File tree Expand file tree Collapse file tree 5 files changed +72
-4
lines changed
module/DeployAgent/src/Task Expand file tree Collapse file tree 5 files changed +72
-4
lines changed Original file line number Diff line number Diff line change @@ -16,7 +16,14 @@ It manages automated deployment workflows based on webhooks for your projects.
1616* PHP mcrypt extension
1717* sqlite or other doctrine compatible SGBD (sqlite is currently the only one officially supported)
1818
19- # Installation
19+ # Installation by Docker ( Container Service )
20+
21+ You can use our [ Docker image] ( https://hub.docker.com/r/continuous/deploy-agent/ ) as a container service.
22+ The container is isolated from the rest of your Server and you have not to worry about server dependencies or security.
23+
24+ Thanks to report to [ Docker-Hub documentation] ( https://hub.docker.com/r/continuous/deploy-agent/ ) .
25+
26+ # Installation by Composer
2027
2128* Download [ Composer] ( https://getcomposer.org/download/ ) : ` curl -sS https://getcomposer.org/composer.phar -o composer.phar `
2229* Install the Deploy Agent: ` php composer.phar create-project continuousphp/deploy-agent `
@@ -124,4 +131,4 @@ Configure it as following:
124131Please note that this project is released with a [Contributor Code of Conduct](http://contributor-covenant.org/version/1/2/0/).
125132By participating in this project you agree to abide by its terms.
126133
127- Feel free to fork the project, create a feature branch, and send us a pull request!
134+ Feel free to fork the project, create a feature branch, and send us a pull request!
Original file line number Diff line number Diff line change 1+ FROM php:7.0-apache
2+
3+ # Set default system timezone
4+ RUN ln -sf /usr/share/zoneinfo/Europe/Paris /etc/localtime
5+
6+ # Install last update and php extension
7+ RUN apt-get update && apt-get install -y \
8+ git \
9+ vim \
10+ bzip2 \
11+ zip \
12+ libbz2-dev \
13+ libmcrypt-dev \
14+ libicu-dev \
15+ && docker-php-ext-configure mysqli \
16+ && docker-php-ext-install mysqli pdo_mysql bz2 mcrypt intl
17+
18+ # Install composer
19+ RUN curl -sS https://getcomposer.org/installer | php \
20+ && mv composer.phar /usr/bin/composer
21+
22+ # Enable Apache Rewrite module
23+ RUN a2enmod rewrite
24+
25+ # Default Vhost for developement
26+ COPY infra/docker/vhost.conf /etc/apache2/sites-available/000-default.conf
27+
28+ # Implement application
29+ COPY . /var/app/
30+
31+ RUN rm -rf /var/app/.git
32+ RUN cd /var/app; \
33+ /usr/bin/composer update; \
34+ ./scripts/post-create-project
35+
36+ CMD ["apache2-foreground" ]
Original file line number Diff line number Diff line change 1+ version : ' 2'
2+
3+ services :
4+ cphp-deploy-agent :
5+ image : continuous/deploy-agent:latest
6+ ports :
7+ - 8080:80
8+ volumes :
9+ - ./db:/var/app/data/db
10+ - ./logs:/var/app/data/logs
11+ - ./packages:/var/app/data/packages
12+ - ./myApplication:/mnt/applications/blueprint-cphp
Original file line number Diff line number Diff line change 1+ <VirtualHost *>
2+ DocumentRoot /var/app/public
3+ <Directory /var/app/public>
4+ DirectoryIndex index.php
5+ AllowOverride All
6+ Require all granted
7+ </Directory>
8+ </VirtualHost>
Original file line number Diff line number Diff line change @@ -290,11 +290,16 @@ public function activate(EventInterface $event)
290290 $ message = 'Starting ' . $ application ->getName () . ' ( ' . $ build . ') ' ;
291291 $ this ->getLogger ()->info ($ message );
292292
293+ $ pwd = getcwd ();
294+ chdir ($ application ->getPath () . DIRECTORY_SEPARATOR );
295+
293296 symlink (
294- $ application -> getPath () . DIRECTORY_SEPARATOR . $ build ,
295- $ application -> getPath () . DIRECTORY_SEPARATOR . 'current '
297+ $ build ,
298+ 'current '
296299 );
297300
301+ chdir ($ pwd );
302+
298303 $ application ->getEventManager ()->trigger ($ application ::EVENT_AFTER_ACTIVATE );
299304
300305 $ message = $ application ->getName () . ' ( ' . $ build . ') has successfully started ' ;
You can’t perform that action at this time.
0 commit comments