Jenkins: Setup PHP project

First, you have to create and put code to GitLab. 1. Go to Jenkins URL: 2. Click ‘New Item’ -> Create ‘Freestyle’ project 3. In Source Code Management section, add Gitlab URL, usr&pwd 4. In Build section, add following command line: mkdir -p /var/www/html/<project_name>cp -rf * /var/www/html/<project_name> chmod -R 777 /var/www/html/<project_name> chmod -R 777 […]

Teerakorn Bounoy

September 29, 2021

Linux tips

Here is the list of command lines which often used in ZTI operations. Disk Check size of diskdf -h Check disk usagedu -sh <directory>Ex.du -sh /optdu -sh * | sort -n -r Directory List directoryls -lshls -lsha Create directorymkdir -p /opt/user/usr1/docs Remove directoryrm -rf /opt/user/usr1/ Change direcotry modechmod -R 777 System Manage servicesystemctl restart <service_name>systemctl […]

Teerakorn Bounoy

September 25, 2021

Jenkins x Gitlab build trigger

เซท Jenkins ให้ build และ deploy app อัตโนมัติ หลังจาก push / merge code ไปที่ branch ‘master’ Reference: GitLab project example: Create GitLab project , (create Access Token in GitLab * you can skip this step) URL: 2. Create Jenkins Project Add GitLab project URL / Add GitLab’s username and password (or use […]

Teerakorn Bounoy

September 23, 2021
1 2