Chapter 5

Devops

DevOPS process

General

CICD:
  CI:
    build:
      - jenkins:
        - list some plugins and their use cases
        - type of jobs (freestyle,pipeline,multibranch ...)
        - scripted/declarative pipelines (ask for some example where candidate had some participation)
        - best practice for secrets
        - shared library usage and implementation (if candidate used it and how/for which purpose)
        - init.groovy.d scripts usage and implementation (if candidate used it and how/for which purpose)
      - maven:
        - define some goals,cycles or phases
        - TBD
      - cloud based cicd usage (gitlab-ci,githab actions,circleci)
    vcs:
      - git:
        - define minimal PR process (add+commit+push+ creating PR on remote UI)
        - diff between fetch and pull (former just downloads, latter downloads and integrate with current workspace)
        - diff between reset and revert (former reset to some target with discarding changes between current and target commits,revert is creating a new commit with changes which will undo all data between current and target commit)
        - https://about.gitlab.com/images/press/git-cheat-sheet.pdf
      - svn:
        - TBD
    code:
      - python:
        - list comprehension (what is and name some use-cases)
        - iterable vs list (former represents an object capable of returing its members one at a time)
      - bash
        - what is the meaning for `$?`
        - what is the most complex script that candidate wrote or worked on
      - groovy
        - TBD

  CD:
    deploy:
      ansible:
        - structure of the role (file,vars,default,templates,...)
        - what is host and group vars
        - where ansible store secrets and how
        - where and how ansible find targets which needs an update
        - difference between task and playbook
        - check if candidate created some role from the scratch
        - name some resource types(tasks) and their use cases (copy,template,user,file,uri,apt,yum,...)
        - explain architecture which is used in ansible (workstation + targets, agentless infra)
      puppet:
        - explain architecture which is used in puppet (workstation + server + targets,agent on the targets)
        - name some resource types(tasks) and their use cases (file,user,service,package,exec...)
        - what is hiera and what is its use case
        - structure of the module (files,mainfests,templates,...)
        - diff between `include` and `contain` (former has no ordering relationships,latter sets relationships)

Monitoring:
  - nagios:
    - TBD
  - prometheus:
    - TBD

Logging:
  - TBD

IaC:
  - terraform:
    - name some actions and explain their use cases (init,plan,apply,destroy,state,...)
    - where terraform should store its state based on best practice (s3,consul or some other high availability storage (if possible + encrypted) with option for locking (dynamodb,consul,...) )
    - https://www.terraform-best-practices.com/

Cloud:
  - AWS
    - TBD if needed

Containers:
  - docker
    - minimal Dockfile (FROM + CMD)
    - what features of kernel is docker leverage (namespace,cgroup,...)
    - can you use windows image on linux box and why (docker utilizes OS kernel so linux on linux,windows on windows,...)
    - what is purpose of docker-compose
    - diff between COPY and ADD (former copy local files as it is,latter can extract some files(gz,bzip),download from URL in addition to former functions)
    - diff between ENV and ARG (former providing default values for environment variables inside container,latter is only used in build action)
    - diff between CMD and ENTRYPOINT (former set default executable,latter set main command for container,cmd+entrypoint can be used together as well where cmd is used as default action(changeble) and entyrpoint as nonchangable action)
  - kubernetes
    - name some of the resource types and explain their purpose(pod,ingress,replicatincontroller,replicaset,deployment,endpoint)
    - what is ingress and what is its use case (is it mandatory)
    - diff between drain and cordon (former is setting NoExecute taint to node where pods will move to another node,latter is setting NoSchedule taint where just no new pods will be assigned to this node)
    - components of master (api,etcd,controller and scheduler) and node (kubelet,container daemon,kube proxy)
    - types of service (nodeport,load balancer(cloud),externalname,clusterip)
    - types of workloads and their purposes (deployment/rs(stateless apps),statefulset(dbs),daemonset(included on all nodes,e.g. siem tools),job/cron(batch))
  - helm
    - diff between helm2 and helm3 (former is client/server model and have tiller,latter is using only api)

REFERENCES