{"id":9031,"date":"2020-01-20T07:45:33","date_gmt":"2020-01-20T07:45:33","guid":{"rendered":"https:\/\/www.devopsschool.com\/blog\/?p=9031"},"modified":"2021-11-13T07:06:14","modified_gmt":"2021-11-13T07:06:14","slug":"ansible-interview-questions-and-answer-part-11","status":"publish","type":"post","link":"https:\/\/www.devopsschool.com\/blog\/ansible-interview-questions-and-answer-part-11\/","title":{"rendered":"Ansible Interview Questions and Answer \u2013 Part 11"},"content":{"rendered":"\n<p><strong>What is the best way to allow a Docker client running in a container access to the underlying Docker host?<\/strong><\/p>\n\n\n\n<ul class=\"wp-block-list\"><li>Map the root filesystem to the container.<\/li><li>You shouldn&#8217;t do this; instead, run Docker in Docker.<\/li><li>Configure the container to communicate with the Docker Host over a network socket.<\/li><li><strong>Map \/var\/run\/docker.sock to the container.  (Ans)<\/strong><\/li><\/ul>\n\n\n\n<p>Which of the following is the most efficient method of obtaining configuration data about your AWS resources and services in Ansible playbooks?<\/p>\n\n\n\n<ul class=\"wp-block-list\"><li>Use the AWS CLI to query your resources.<\/li><li><strong>Organize your resources into CloudFormation stacks, and define stack outputs as required to meet your needs. (Ans)<\/strong><\/li><li>Organize your resources into CloudFormation stacks, and refer to the resource outputs to obtain configuration data. <\/li><li>Use the AWS Console to query your resources. <\/li><\/ul>\n\n\n\n<p><strong>Which of the following statements is true about continuous delivery?<\/strong><\/p>\n\n\n\n<ul class=\"wp-block-list\"><li>You release lots of features at once.<\/li><li>You release in two-week sprints.<\/li><li><strong>You release small changes. (Ans)<\/strong><\/li><li>You always release immediately to production.<\/li><\/ul>\n\n\n\n<p><strong>Which statement best describes a dangling image?<\/strong><\/p>\n\n\n\n<ul class=\"wp-block-list\"><li>An image layer that is not the top level layer in the image<\/li><li>An image that has no running containers<\/li><li>An image whose volumes have been deleted<\/li><li><strong>An image whose tag has been superseded by a newer image  (Ans)<\/strong><\/li><\/ul>\n\n\n\n<p><strong>Which of the following can trigger the continuous delivery pipeline?<\/strong><\/p>\n\n\n\n<ul class=\"wp-block-list\"><li>Automated build of the parent image of the base image for your Docker application<\/li><li>Commit to Git repository<\/li><li>Automated build of base image for your Docker application <\/li><li><strong>All of these  (Ans)<\/strong><\/li><\/ul>\n\n\n\n<p><strong>An application is not terminating gracefully when its Docker container is stopped. Why would this happen?<\/strong><\/p>\n\n\n\n<ul class=\"wp-block-list\"><li>Docker needs to be configured to terminate the container gracefully.<\/li><li>Docker doesn&#8217;t support terminating containers gracefully.<\/li><li>The application needs to be configured to terminate gracefully when it receives a SIGKILL signal.<\/li><li><strong>The application is not running as the parent process in the Docker container.  (Ans)<\/strong><\/li><\/ul>\n\n\n\n<p><strong>Which strategies can be used to exchange files between a Docker Client and Docker Containers?<\/strong><\/p>\n\n\n\n<ul class=\"wp-block-list\"><li>Use the docker cp command to copy files from Docker Containers to the Docker Client.<\/li><li>Use the COPY or ADD directive to copy files into a Docker image.<\/li><li><strong>All of these (Ans)<\/strong><\/li><li>Use the docker cp command to copy files to Docker Containers from the Docker Client. <\/li><\/ul>\n\n\n\n<p><strong>What is the best way to avoid having to add sensitive AWS credentials to a Jenkins deployment job?<\/strong><\/p>\n\n\n\n<ul class=\"wp-block-list\"><li>Specify the credentials as a password build parameter on each run.<\/li><li>Specify the credentials as a password build parameter with a default value.<\/li><li><strong>Assign an EC2 IAM role to the Jenkins EC2 instance with appropriate permissions to access AWS services. (Ans)<\/strong><\/li><li>Create an AWS credential profile on each Jenkins host. <\/li><\/ul>\n\n\n\n<p><strong>Which of the following platforms is supported by Docker Machine?<\/strong><\/p>\n\n\n\n<ul class=\"wp-block-list\"><li>VMWare Fusion<\/li><li>Parallels<\/li><li><strong>All of these  (Ans)<\/strong><\/li><li>VirtualBox <\/li><\/ul>\n\n\n\n<p><strong>Which of the following build triggers can Jenkins automatically manage for you?<\/strong><\/p>\n\n\n\n<ul class=\"wp-block-list\"><li><strong>GitHub (Ans)<\/strong><\/li><li>None of these<\/li><li>Docker Hub<\/li><li>GitHub and Docker Hub <\/li><\/ul>\n\n\n\n<p><strong>How can you best deal with waiting for a service dependency to fully initialize in a Docker Compose environment?<\/strong><\/p>\n\n\n\n<ul class=\"wp-block-list\"><li>Make containers that rely on the service depencency sleep for 30 seconds.<\/li><li><strong>Create your own service that probes if the service dependency has fully initialized. (Ans)<\/strong><\/li><li>There is no way to deal with this currently.<\/li><li>Use the wait_for Docker Compose configuration option. <\/li><\/ul>\n\n\n\n<p><strong>What is the registry name for Docker Hub?<\/strong><\/p>\n\n\n\n<ul class=\"wp-block-list\"><li>docker.com<\/li><li><strong>docker.io (Ans)<\/strong><\/li><li>registry.docker.com <\/li><li>index.docker.io <\/li><\/ul>\n\n\n\n<p><strong>What is basic use of Artifactory?<\/strong><\/p>\n\n\n\n<ul class=\"wp-block-list\"><li><strong>Binary and Package management system (Ans)<\/strong><\/li><li>Source code management system<\/li><li>Configuration management system<\/li><li>Code management system<\/li><\/ul>\n\n\n\n<p><strong>What is the JAVA path need to be set before artifactory installation?<\/strong><\/p>\n\n\n\n<ul class=\"wp-block-list\"><li><strong>JAVA_HOME (Ans)    <\/strong><\/li><li>JAVA_PATH<\/li><li>JRE_PATH<\/li><li>JDK_PATH<\/li><\/ul>\n\n\n\n<p><strong>What is the use of $ARTIFACTORY_HOME\/bin\/artifactory.sh file<\/strong><\/p>\n\n\n\n<ul class=\"wp-block-list\"><li><strong>To Start the Artifactory Services in Linux (Ans)<\/strong><\/li><li>To Start the Artifactory Services in Windows<\/li><li>To Start the Artifactory Services in Mac<\/li><li>To Start the Artifactory Services in All Platforms<\/li><\/ul>\n\n\n\n<p><strong>What is the use of $ARTIFACTORY_HOME\/bin\/artifactoryctl start<\/strong><\/p>\n\n\n\n<ul class=\"wp-block-list\"><li>To Start the Artifactory Services in Linux as a daemon process<\/li><li>To Start the Artifactory Services in Windows as a daemon process<\/li><li>To Start the Artifactory Services in Mac as a daemon process<\/li><li><strong>To Start the Artifactory Services in All Platforms as a daemon process (Ans)<\/strong><\/li><\/ul>\n\n\n\n<p><strong>How to access default Artifactory application over the internet browsers?<\/strong><\/p>\n\n\n\n<ul class=\"wp-block-list\"><li><strong>http:\/\/SERVER_DOMAIN:8081\/artifactory (Ans)<\/strong><\/li><li>http:\/\/SERVER_DOMAIN:8080\/artifactory<\/li><li>http:\/\/SERVER_DOMAIN:8090\/artifactory<\/li><li>http:\/\/SERVER_DOMAIN:8085\/artifactory<\/li><\/ul>\n\n\n\n<p><strong>What is the use of &#8220;Artifacts&#8221; menu in Dashboard?<\/strong><\/p>\n\n\n\n<ul class=\"wp-block-list\"><li><strong>The Artifacts module is used to browse the repositories in your system and search for artifacts using a number of different methods. (Ans)<\/strong><\/li><li>The Artifacts module is used to browse the Artifacts in your system and search for artifacts using a number of different methods.<\/li><li>The Artifacts module is used to browse the Binary in your system and search for artifacts using a number of different methods.<\/li><li>The Artifacts module is used to browse the Plugins in your system and search for artifacts using a number of different methods.<\/li><\/ul>\n\n\n\n<p><strong>What is the function of &#8220;Build&#8221; menu in Artifactory Dashboard?<\/strong><\/p>\n\n\n\n<ul class=\"wp-block-list\"><li><strong>The Build module displays the Build Browser where you can view all the CI server projects that output their builds to Artifactory. (Ans)<\/strong><\/li><li>The Build module displays the Artifact Browser where you can view all the Artifact server projects that output their builds to Artifactory.<\/li><li>The Build module displays the repositories Browser where you can view all the repositories server projects that output their builds to Artifactory.  <\/li><li>The Build module displays the binary Browser where you can view all the binary server projects that output their builds to Artifactory.<\/li><\/ul>\n\n\n\n<p><strong>What is not a right repostory type is avaiable in Artifactory<\/strong><\/p>\n\n\n\n<ul class=\"wp-block-list\"><li>Local<\/li><li>Remote<\/li><li>Virtual<\/li><li><strong>Group (Ans)<\/strong><\/li><\/ul>\n\n\n\n<p><strong>What is not a right terminolgy for bintray?<\/strong><\/p>\n\n\n\n<ul class=\"wp-block-list\"><li>A global distribution network (CDN)<\/li><li>Extreme throughput and redundancy for downloads<\/li><li><strong>CI servers metadata integration (Ans)<\/strong><\/li><li>Product and EULA support<\/li><\/ul>\n\n\n<div class=\"epyt-gallery\" data-currpage=\"1\" id=\"epyt_gallery_36687\"><figure class=\"wp-block-embed wp-block-embed-youtube is-type-video is-provider-youtube epyt-figure\"><div class=\"wp-block-embed__wrapper\"><iframe loading=\"lazy\"  id=\"_ytid_20657\"  width=\"760\" height=\"427\"  data-origwidth=\"760\" data-origheight=\"427\" src=\"https:\/\/www.youtube.com\/embed\/?enablejsapi=1&#038;autoplay=0&#038;cc_load_policy=0&#038;cc_lang_pref=&#038;iv_load_policy=1&#038;loop=0&#038;rel=1&#038;fs=1&#038;playsinline=0&#038;autohide=2&#038;theme=dark&#038;color=red&#038;controls=1&#038;disablekb=0&#038;\" class=\"__youtube_prefs__  no-lazyload\" title=\"YouTube player\"  data-epytgalleryid=\"epyt_gallery_36687\"  allow=\"fullscreen; accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share\" referrerpolicy=\"strict-origin-when-cross-origin\" allowfullscreen data-no-lazy=\"1\" data-skipgform_ajax_framebjll=\"\"><\/iframe><\/div><\/figure><div class=\"epyt-gallery-list\"><div>Sorry, there was a YouTube error.<\/div><\/div><\/div>","protected":false},"excerpt":{"rendered":"<p>What is the best way to allow a Docker client running in a container access to the underlying Docker host? Map the root filesystem to the container. You shouldn&#8217;t do this; instead, run Docker in Docker. Configure the container to communicate with the Docker Host over a network socket. Map \/var\/run\/docker.sock to the container. (Ans)&#8230;<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_kad_post_transparent":"","_kad_post_title":"","_kad_post_layout":"","_kad_post_sidebar_id":"","_kad_post_content_style":"","_kad_post_vertical_padding":"","_kad_post_feature":"","_kad_post_feature_position":"","_kad_post_header":false,"_kad_post_footer":false,"_kad_post_classname":"","_joinchat":[],"footnotes":""},"categories":[5038],"tags":[639,767,766,482],"class_list":["post-9031","post","type-post","status-publish","format-standard","hentry","category-ansible","tag-ansible","tag-answer","tag-interview","tag-questions"],"_links":{"self":[{"href":"https:\/\/www.devopsschool.com\/blog\/wp-json\/wp\/v2\/posts\/9031","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.devopsschool.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.devopsschool.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.devopsschool.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.devopsschool.com\/blog\/wp-json\/wp\/v2\/comments?post=9031"}],"version-history":[{"count":4,"href":"https:\/\/www.devopsschool.com\/blog\/wp-json\/wp\/v2\/posts\/9031\/revisions"}],"predecessor-version":[{"id":25052,"href":"https:\/\/www.devopsschool.com\/blog\/wp-json\/wp\/v2\/posts\/9031\/revisions\/25052"}],"wp:attachment":[{"href":"https:\/\/www.devopsschool.com\/blog\/wp-json\/wp\/v2\/media?parent=9031"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.devopsschool.com\/blog\/wp-json\/wp\/v2\/categories?post=9031"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.devopsschool.com\/blog\/wp-json\/wp\/v2\/tags?post=9031"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}