5/4/20 Devops
Whatever products we implement, there are many tools that intergate with each other
Somethings that we have learned today:
1. Integrate Jenkins with Docker
2.Used cases of Jenkins, Docker
3.Chaining between jobs
4.Jenkins server
Notes:
If you want to download a program/service, youll need Operating System
Os - UM (Virtual)
Program/service --> [Container] - (Also known as provisioning) installed but login
Docker is Agile/rapid
It will start provision you
Dockerhub is the placed to download docker
They don't give
docker images is used to check if you have docker
docker run -t -i --name myos1 ubuntu
docker ps tells you how many os
Docker has own ip
Ubuntu command os apt
exit to get out from docker
COmputer -> github -fitch--> Jenkins deployed
Rhel 8 |
| |
| v
System -> OS -> Webserver
^
|
|
Manual and fast
Docker image for webserver
httpd for the webserver which they already made avaliable
If you want to use the image, do docker pull httpd
httpd
______
Own dockerimage
has -webserver OS
If someone asks you to download
docker run to launch OS
docker run -d -t -i --name myweb1 httpd
You'll its not docker because the d is detach
Running one command, your container technology they configure the webserver for you
client can connect to webserver
since docker has its own ip you can check it by typing IP
We'll use the same setup and the same envolvement for httpd
run docker ten times to create 10 OS servers
[index.html ]
[Ubuntu server]
[O.S. ]
[Phy ]
You can check the commands of docker by doing man docker
copy/deploy
cat index.html
You have to copy he os from the folder
cp to copy
keep on changing the code
-----------------------------------------
mkdir /lwweb
cd /lwweb
ls
cat > index.html
cat > lw.html
cat > samsweb.html
------------------------------------------------------------
Instead of copy
its operated in /lwweb:/usr/local/apache2/html
-------------------------------------------------------------------
cd /lwweb/
pwd
/lwweb
ls
__________________
VM
|
\
v
[RHEL]
_______________________________
httpd
| \
[IP] v
docker
_____________________________________
docker
\
When you launch any OS ===ENV
security reason, they launch the os
security -> Isolated
Rhel 8
_______________________
[docker] [docker]
IP___|_________________|___IP
Inside Redhat, 2 OS are running
In the OS, webserver is running
ipconfig
the outside world can connect with the IP adress
Ask the outside world, if you want to connect to the Docker I have, In the system, ask the system to connect
The computer will ask the owner of the docker and give permission to come in
Client
|
|
v
IP
RHEL8 docker
---------------------------------
[/;wweb] [/userlexl----------/
----------------------------------------------------------
[Client]-------- /
/
|-------------/
[JENKINS] -------->[RHEL 8]
\
\
JOB -> github 9down -> copy
|
----job -> deploy [ENV]
------------------------------------------------------------------
win---
|
v
[DEV]
|
--->6 month
---------------------------------------------------------------------
Repo in git and jenkins
jenkins all=(all)
jenkins power password
jenkins power is equivelent to root user
sudo cp -v -r -f * /
if date
TO shut down:
: you can check from jenkins
We achieved job 1 and 2
github
|
v
job1
Basically you might need to know html in order to know this
OS is running inside the java
Job1
|
v
Job2
downstreamed from job1 to job2
Without touching a job you can do stuff
If it is sucessful it will do it on job2
downstream projects are seen with associated server so in this case job 1
Awesome, Great work👍👍...Keep posting