Hi Folks, Today we are configuring our Jenkins to replace tokens in code before deployment. Please follow below steps. Create Project in git ( github or any other git providing tool) Create a project which will contains all token values. in my case here is public demo project . Deploy it in Jenkins as freestyle project , select git in Source Code Management and paste your git repository URL. If it is public then you don't need credentials to enter otherwise you have to. Build your project and check console output. Copy directory structure ( ref: below console snapshot). This is the physical directory structure of our deployed code in Jenkins hosted docker/OS. Configure project (in which token need to be changed) Create build.xml in your project root and past below code <project name="demo-app-tokenparser" default="useregex" basedir="."> <target name="useregex"> <property file="/var/jenkins_home/works...
Hi Folks, In my previouspost we have configured Jenkins docker with Docker-Outside-Of-Docker approach. Today we will be creating docker from php application and deploying through Jenkins as sibling to Jenkins docker. Below are the detail steps Configure PHP code I will be using yii2 application which will help those who want to deploy other php framework applications. · Create a file with name: Dockerfile on your project root. Paste below contents in the file created FROM webdevops/php-apache-dev COPY . /app RUN apt-get update COPY ./config/vhost.conf /opt/docker/etc/httpd/vhost.conf COPY ./config/10-server.conf /opt/docker/etc/httpd/conf.d RUN chmod 777 /app/runtime RUN chmod 777 /app/web/assets · Create a folder with name : config on your project root. · ...