When a Jenkins job executes, it sets some environment variables that you may use in your shell script, batch command, Ant script or Maven POM. Environment Variable Description BUILD_NUMBER The current build number, such as "153" BUILD_ID The current build id, such as "2005-08-22_23-59-59" (YYYY-MM-DD_hh-mm-ss, defunct since version 1.597) BUILD_URL The URL where the results of this build … Continue reading Jenkins Environment Variables
Author: mshaik
gradle
[root@localhost ~]# wget https://services.gradle.org/distributions/gradle-4.6-bin.zip [root@localhost ~]# mkdir /opt/gradle [root@localhost ~]# unzip -d /opt/gradle/ gradle-4.6-bin.zip [root@localhost ~]# export PATH=$PATH:/opt/gradle/gradle-4.6/bin/ [root@localhost ~]# printenv |grep gradle PATH=/usr/local/sbin:/sbin:/bin:/usr/sbin:/usr/bin:/root/bin:/opt/gradle/gradle-4.6/bin/ [root@localhost ~]# gradle -v ------------------------------------------------------------ Gradle 4.6 ------------------------------------------------------------ Build time: 2018-02-28 13:36:36 UTC Revision: 8fa6ce7945b640e6168488e4417f9bb96e4ab46c Groovy: 2.4.12 Ant: Apache Ant(TM) version 1.9.9 compiled on February 2 2017 JVM: 1.8.0_161 (Oracle Corporation … Continue reading gradle
Maven sample build
[root@localhost ~]# yum provides */mvn Loaded plugins: fastestmirror Loading mirror speeds from cached hostfile * base: centos.mirror.net.in * epel: del-mirrors.extreme-ix.org * extras: mirror.vbctv.in * updates: mirror.vbctv.in maven-3.0.5-17.el7.noarch : Java project management and project comprehension tool Repo : base Matched from: Filename : /usr/share/maven/bin/mvn Filename : /usr/bin/mvn xmvn-1.3.0-6.el7_3.noarch : Local Extensions for Apache Maven Repo : … Continue reading Maven sample build
Ant
[root@localhost ~]# yum install epel-release -y [root@localhost ~]# rpm -qa ant [root@localhost ~]# ant -bash: ant: command not found [root@localhost ~]# yum install ant [root@localhost ~]# ant -version Apache Ant(TM) version 1.9.2 compiled on June 10 2014 [root@localhost ~]# java -version openjdk version "1.8.0_161" OpenJDK Runtime Environment (build 1.8.0_161-b14) OpenJDK 64-Bit Server VM (build 25.161-b14, … Continue reading Ant
AWS with Ansible and Terraform
mshaik@noc:~$ lsb_release -a No LSB modules are available. Distributor ID: Ubuntu Description: Ubuntu 16.04.4 LTS Release: 16.04 Codename: xenial mshaik@noc:~$ python --version Python 2.7.12 mshaik@noc:~$ sudo apt-get install python-pip Reading package lists... Done Building dependency tree Reading state information... Done python-pip is already the newest version (8.1.1-2ubuntu0.4). The following packages were automatically installed and are … Continue reading AWS with Ansible and Terraform
elasticbeanstalk
mshaik@noc:~$ pip install awsebcli --upgrade --user The program 'pip' is currently not installed. You can install it by typing: sudo apt install python-pip mshaik@noc:~$ sudo apt install python-pip mshaik@noc:~$ pip install awsebcli --upgrade --user Collecting awsebcli Downloading awsebcli-3.12.3.tar.gz (242kB) 100% |████████████████████████████████| 245kB 689kB/s Collecting pyyaml>=3.11 (from awsebcli) Downloading PyYAML-3.12.tar.gz (253kB) 100% |████████████████████████████████| 256kB 1.4MB/s Collecting … Continue reading elasticbeanstalk
aws cli help
mshaik@noc:~$ sudo apt-get install awscli mshaik@noc:~$ aws help AWS() AWS() NAME aws - DESCRIPTION The AWS Command Line Interface is a unified tool to manage your AWS services. SYNOPSIS aws [options] <command> <subcommand> [parameters] Use aws command help for information on a specific command. Use aws help topics to view a list of available help … Continue reading aws cli help
puppet help doc
mshaik@noc:~$ sudo apt-get install puppet mshaik@noc:~$ puppet --version 3.8.5 mshaik@noc:~$ puppet resource package |less package { 'vagrant': ensure => '1:2.0.2', } package { 'telnet': ensure => '0.17-40', } mshaik@noc:~$ puppet resource package whois package { 'whois': ensure => '5.2.11', } mshaik@noc:~$ puppet resource package nmap package { 'nmap': ensure => 'purged', } mshaik@noc:~$ puppet resource … Continue reading puppet help doc
AWS CERTIFIED DEVOPS ENGINEER – PROFESSIONAL LEVEL SAMPLE QUESTIONS
1) Select all deployment methods that never require a DNS change: "All at Once", Rolling, Immutable environments Explanation All the above do not require a DNS change except for Blue/Green. The key word is never. In Blue/Green we need to change DNS settings to point to the new environment, especially if you are using Elastic … Continue reading AWS CERTIFIED DEVOPS ENGINEER – PROFESSIONAL LEVEL SAMPLE QUESTIONS
Read-only file system
[root@localhost ~]# touch sample touch: cannot touch ‘sample’: Read-only file system [root@localhost ~]# df -hT Filesystem Type Size Used Avail Use% Mounted on /dev/xvda2 ext3 25G 1.7G 22G 8% / devtmpfs devtmpfs 908M 0 908M 0% /dev tmpfs tmpfs 917M 0 917M 0% /dev/shm tmpfs tmpfs 917M 25M 893M 3% /run tmpfs tmpfs 917M 0 … Continue reading Read-only file system

