{"id":1434,"date":"2018-09-18T23:55:43","date_gmt":"2018-09-18T14:55:43","guid":{"rendered":"https:\/\/xn--o9j8h1c9hb5756dt0ua226amc1a.com\/?p=1434"},"modified":"2020-02-23T01:33:18","modified_gmt":"2020-02-22T16:33:18","slug":"git%e3%82%b5%e3%83%bc%e3%83%90%e3%83%bc%e3%82%92centos-7%e3%81%a7%e6%a7%8b%e7%af%89%e3%81%99%e3%82%8b%e6%96%b9%e6%b3%95%e3%81%a8%e8%a8%ad%e5%ae%9a%e6%89%8b%e9%a0%86","status":"publish","type":"post","link":"https:\/\/xn--o9j8h1c9hb5756dt0ua226amc1a.com\/?p=1434","title":{"rendered":"Git \u30b5\u30fc\u30d0\u30fc\u3092 CentOS 7 \u3067\u69cb\u7bc9\u3059\u308b\u65b9\u6cd5\u3068\u8a2d\u5b9a\u624b\u9806"},"content":{"rendered":"<p>\u30d0\u30fc\u30b8\u30e7\u30f3\u7ba1\u7406\u30c4\u30fc\u30eb\u300cGit\u300d\u306e\u30b5\u30fc\u30d0\u30fc\u69cb\u7bc9\u624b\u9806\u3092\u7d39\u4ecb\u3057\u307e\u3059\u3002<br \/>\nGitHub \u7b49\u306e\u5916\u90e8\u30b5\u30fc\u30d3\u30b9\u4ee5\u5916\u306b\u3082\u3001\u81ea\u524d\u3067 Git \u30b5\u30fc\u30d0\u30fc\u3092\u7528\u610f\u3059\u308b\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002<\/p>\n<p>\u4eca\u56de\u306f CentOS 7 \u3092\u4f7f\u7528\u3057\u3066\u3001\u30d1\u30b9\u30ef\u30fc\u30c9\u8a8d\u8a3c\u3092\u8a2d\u5b9a\u3059\u308b\u307e\u3067\u306e\u624b\u9806\u3092\u89e3\u8aac\u3057\u307e\u3059\u3002<\/p>\n<p><script async src=\"\/\/pagead2.googlesyndication.com\/pagead\/js\/adsbygoogle.js\"><\/script><br\/><ins class=\"adsbygoogle\" style=\"display:block\" data-ad-client=\"ca-pub-9913955142682871\" data-ad-slot=\"7236093749\" data-ad-format=\"auto\" data-full-width-responsive=\"true\"><\/ins><br\/><script>(adsbygoogle=window.adsbygoogle||[]).push({});<\/script><\/p>\n<h2>Git \u30b5\u30fc\u30d0\u30fc\u3092 CentOS 7 \u306b\u6e96\u5099\u3059\u308b<\/h2>\n<p><strong>\u3010\u524d\u63d0\u6761\u4ef6\u3011<\/strong>CentOS 7 \u30b5\u30fc\u30d0\u30fc\u306b SSH \u3067\u63a5\u7d9a\u3067\u304d\u308b\u3053\u3068<\/p>\n<p>CentOS \u306e <code>yum<\/code> \u30b3\u30de\u30f3\u30c9\u3067 <code>git<\/code> \u3092\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3057\u307e\u3059\u3002<\/p>\n<pre><code># yum install git\n<\/code><\/pre>\n<p>git \u304c\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3067\u304d\u305f\u3089\u3001\u30d0\u30fc\u30b8\u30e7\u30f3\u3092\u78ba\u8a8d\u3057\u3066\u304a\u304d\u307e\u3059\u3002<\/p>\n<pre><code># git version\ngit version 2.14.4\n<\/code><\/pre>\n<p>git \u3067\u4f7f\u7528\u3059\u308b\u305f\u3081\u306e <code>git<\/code> \u30e6\u30fc\u30b6\u3092\u4f5c\u6210\u3057\u307e\u3059\u3002\uff08\u65e2\u306b\u5b58\u5728\u3059\u308b\u5834\u5408\u306f\u4e0d\u8981\uff09<\/p>\n<pre><code># useradd git\n<\/code><\/pre>\n<p>git \u30e6\u30fc\u30b6\u306e\u30d1\u30b9\u30ef\u30fc\u30c9\u3092\u65b0\u898f\u4f5c\u6210\u3057\u307e\u3059\u30022\u56de\u5165\u529b\u304c\u5fc5\u8981\u3067\u3059\u3002<\/p>\n<pre><code>$ passwd git\nChanging password for user git.\nNew password:\nRetype new password:\n<\/code><\/pre>\n<h2>git \u30b5\u30fc\u30d0\u30fc\u306e\u30c6\u30b9\u30c8\u30ea\u30dd\u30b8\u30c8\u30ea\u3092\u4f5c\u6210\u3059\u308b<\/h2>\n<p><code>git<\/code> \u30e6\u30fc\u30b6\u306b\u5207\u308a\u66ff\u3048\u3001\u30c6\u30b9\u30c8\u7528\u306e\u30ea\u30dd\u30b8\u30c8\u30ea\u3092\u4f5c\u6210\u3057\u3066\u304a\u304d\u307e\u3059\u3002<br \/>\n<code>git push<\/code> \u3055\u308c\u305f\u30d5\u30a1\u30a4\u30eb\u304c\u683c\u7d0d\u3055\u308c\u308b\u5834\u6240\u3068\u306a\u308a\u307e\u3059\u3002<\/p>\n<pre><code># su - git\n$ mkdir \/home\/git\/testrepo.git\n$ cd \/home\/git\/testrepo.git\n$ git init --bare --shared=true\n<\/code><\/pre>\n<p>\u4e0a\u8a18\u306e\u624b\u9806\u3067\u3001\u30ea\u30dd\u30b8\u30c8\u30ea\u30921\u4ef6\u4f5c\u6210\u3067\u304d\u307e\u3057\u305f\u3002<br \/>\n\u4eee\u306b2\u3064\u76ee\u306e\u30ea\u30dd\u30b8\u30c8\u30ea\u3092\u4f5c\u6210\u3059\u308b\u5834\u5408\u306f\u3001\u540c\u3058\u30b3\u30de\u30f3\u30c9\u3092\u7e70\u308a\u8fd4\u3057\u307e\u3059\u3002<\/p>\n<pre><code>$ mkdir \/home\/git\/testrepo2.git\n$ cd \/home\/git\/testrepo2.git\n$ git init --bare --shared=true\n<\/code><\/pre>\n<h2>git \u30b5\u30fc\u30d0\u30fc\u306e\u52d5\u4f5c\u3092\u78ba\u8a8d\u3059\u308b<\/h2>\n<p><strong>\u30af\u30e9\u30a4\u30a2\u30f3\u30c8\u7aef\u672b\u304b\u3089<\/strong>\u30ea\u30dd\u30b8\u30c8\u30ea\u3092\u30af\u30ed\u30fc\u30f3\u3057\u307e\u3059\u3002<br \/>\nWindows \u306e\u5834\u5408\u306f Git Bash\u3001Mac \u306e\u5834\u5408\u306f\u30bf\u30fc\u30df\u30ca\u30eb\u3067\u30b3\u30de\u30f3\u30c9\u3092\u5b9f\u884c\u3057\u307e\u3059\u3002<\/p>\n<pre><code>$ git clone git@&lt;Git\u30b5\u30fc\u30d0\u30fc\u306eIP&gt;:testrepo.git\nCloning into 'testrepo'...\ngit@xx.xx.xx.xx's password:\n<\/code><\/pre>\n<p>\u30d1\u30b9\u30ef\u30fc\u30c9\u3092\u6c42\u3081\u3089\u308c\u308b\u305f\u3081\u3001\u5148\u307b\u3069\u4f5c\u6210\u3057\u305f git \u30e6\u30fc\u30b6\u306e\u30d1\u30b9\u30ef\u30fc\u30c9\u3092\u5165\u529b\u3057\u307e\u3059\u3002<\/p>\n<p>\u7121\u4e8b\u306b\u30af\u30ed\u30fc\u30f3\u304c\u5b8c\u4e86\u3059\u308c\u3070\u6210\u529f\u3067\u3059\u3002Git \u30b5\u30fc\u30d0\u30fc\u306e\u63a5\u7d9a\u5148\u3092\u78ba\u8a8d\u3057\u3066\u5b8c\u4e86\u3067\u3059\u3002<\/p>\n<pre><code>$ cd testrepo\n$ git remote -v\norigin  git@xx.xx.xx.xx:testrepo.git (fetch)\norigin  git@xx.xx.xx.xx:testrepo.git (push)\n<\/code><\/pre>\n<h2>\u307e\u3068\u3081<\/h2>\n<p>Git \u30b5\u30fc\u30d0\u30fc\u306e\u69cb\u7bc9\u624b\u9806\u306b\u3064\u3044\u3066\u7d39\u4ecb\u3057\u307e\u3057\u305f\u3002<br \/>\nLinux \u30b5\u30fc\u30d0\u30fc\u3067\u3042\u308c\u3070\u3001git \u30d1\u30c3\u30b1\u30fc\u30b8\u306e\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3060\u3051\u3067\u7c21\u5358\u306b\u69cb\u7bc9\u3067\u304d\u307e\u3059\u3002<\/p>\n<p>\u4eca\u56de\u306f\u30d1\u30b9\u30ef\u30fc\u30c9\u8a8d\u8a3c\u3092\u5229\u7528\u3057\u307e\u3057\u305f\u304c\u3001\u516c\u958b\u9375\u8a8d\u8a3c\u306e\u624b\u9806\u306b\u3064\u3044\u3066\u3082\u8ffd\u3063\u3066\u89e3\u8aac\u3057\u307e\u3059\u3002<\/p>\n<p><strong>\u3010\u95a2\u9023\u8a18\u4e8b\u3011<\/strong><br \/>\n\u21d2 <a href=\"\/?p=681\">CentOS \u3067\u8d77\u52d5\u4e2d\u306e\u30b5\u30fc\u30d3\u30b9\u4e00\u89a7\u3092\u78ba\u8a8d<\/a><br \/>\n\u21d2 <a href=\"\/?p=1540\">Redis 4 \u3092\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3059\u308b (CentOS)<\/a><br \/>\n\u21d2 <a href=\"\/?p=1591\">memcached \u3092\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3059\u308b (CentOS)<\/a><br \/>\n\u21d2 <a href=\"\/?p=1519\">\u30c7\u30a3\u30b9\u30af\u304c\u67af\u6e07\u3057\u305f\u5834\u5408\u306e\u8abf\u67fb\u65b9\u6cd5\u3068\u5bfe\u51e6<\/a><\/p>\n<p><script async src=\"\/\/pagead2.googlesyndication.com\/pagead\/js\/adsbygoogle.js\"><\/script><ins class=\"adsbygoogle\" style=\"display:block\" data-ad-client=\"ca-pub-9913955142682871\" data-ad-slot=\"6645392458\" data-ad-format=\"auto\" data-full-width-responsive=\"true\"><\/ins><script>(adsbygoogle = window.adsbygoogle || []).push({});<\/script><\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u30d0\u30fc\u30b8\u30e7\u30f3\u7ba1\u7406\u30c4\u30fc\u30eb\u300cGit\u300d\u306e\u30b5\u30fc\u30d0\u30fc\u69cb\u7bc9\u624b\u9806\u3092\u7d39\u4ecb\u3057\u307e\u3059\u3002 GitHub \u7b49\u306e\u5916\u90e8\u30b5\u30fc\u30d3\u30b9\u4ee5\u5916\u306b\u3082\u3001\u81ea\u524d\u3067 Git \u30b5\u30fc\u30d0\u30fc\u3092\u7528\u610f\u3059\u308b\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002 \u4eca\u56de\u306f CentOS 7 \u3092\u4f7f\u7528\u3057\u3066\u3001\u30d1\u30b9\u30ef\u30fc\u30c9\u8a8d\u8a3c\u3092\u8a2d\u5b9a\u3059\u308b\u307e&#8230;<\/p>\n","protected":false},"author":1,"featured_media":1485,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"spay_email":""},"categories":[16],"tags":[6,61],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v16.4 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>Git \u30b5\u30fc\u30d0\u30fc\u3092 CentOS 7 \u3067\u69cb\u7bc9\u3059\u308b\u65b9\u6cd5\u3068\u8a2d\u5b9a\u624b\u9806 - \u30b5\u30fc\u30d0\u30fc\u69cb\u7bc9\u3068\u8a2d\u5b9a \uff5e\u521d\u5fc3\u8005\u306b\u3082\u5206\u304b\u308a\u3084\u3059\u304f\u89e3\u8aac\uff5e<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/xn--o9j8h1c9hb5756dt0ua226amc1a.com\/?p=1434\" \/>\n<meta property=\"og:locale\" content=\"ja_JP\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Git \u30b5\u30fc\u30d0\u30fc\u3092 CentOS 7 \u3067\u69cb\u7bc9\u3059\u308b\u65b9\u6cd5\u3068\u8a2d\u5b9a\u624b\u9806 - \u30b5\u30fc\u30d0\u30fc\u69cb\u7bc9\u3068\u8a2d\u5b9a \uff5e\u521d\u5fc3\u8005\u306b\u3082\u5206\u304b\u308a\u3084\u3059\u304f\u89e3\u8aac\uff5e\" \/>\n<meta property=\"og:description\" content=\"\u30d0\u30fc\u30b8\u30e7\u30f3\u7ba1\u7406\u30c4\u30fc\u30eb\u300cGit\u300d\u306e\u30b5\u30fc\u30d0\u30fc\u69cb\u7bc9\u624b\u9806\u3092\u7d39\u4ecb\u3057\u307e\u3059\u3002 GitHub \u7b49\u306e\u5916\u90e8\u30b5\u30fc\u30d3\u30b9\u4ee5\u5916\u306b\u3082\u3001\u81ea\u524d\u3067 Git \u30b5\u30fc\u30d0\u30fc\u3092\u7528\u610f\u3059\u308b\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002 \u4eca\u56de\u306f CentOS 7 \u3092\u4f7f\u7528\u3057\u3066\u3001\u30d1\u30b9\u30ef\u30fc\u30c9\u8a8d\u8a3c\u3092\u8a2d\u5b9a\u3059\u308b\u307e...\" \/>\n<meta property=\"og:url\" content=\"https:\/\/xn--o9j8h1c9hb5756dt0ua226amc1a.com\/?p=1434\" \/>\n<meta property=\"og:site_name\" content=\"\u30b5\u30fc\u30d0\u30fc\u69cb\u7bc9\u3068\u8a2d\u5b9a \uff5e\u521d\u5fc3\u8005\u306b\u3082\u5206\u304b\u308a\u3084\u3059\u304f\u89e3\u8aac\uff5e\" \/>\n<meta property=\"article:published_time\" content=\"2018-09-18T14:55:43+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2020-02-22T16:33:18+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/xn--o9j8h1c9hb5756dt0ua226amc1a.com\/wp-content\/uploads\/2018\/09\/a049.png\" \/>\n\t<meta property=\"og:image:width\" content=\"480\" \/>\n\t<meta property=\"og:image:height\" content=\"200\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"\u63a8\u5b9a\u8aad\u66f8\u6642\u9593\" \/>\n\t<meta name=\"twitter:data1\" content=\"1\u5206\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebSite\",\"@id\":\"https:\/\/xn--o9j8h1c9hb5756dt0ua226amc1a.com\/#website\",\"url\":\"https:\/\/xn--o9j8h1c9hb5756dt0ua226amc1a.com\/\",\"name\":\"\\u30b5\\u30fc\\u30d0\\u30fc\\u69cb\\u7bc9\\u3068\\u8a2d\\u5b9a \\uff5e\\u521d\\u5fc3\\u8005\\u306b\\u3082\\u5206\\u304b\\u308a\\u3084\\u3059\\u304f\\u89e3\\u8aac\\uff5e\",\"description\":\"\\u30b5\\u30fc\\u30d0\\u30fc\\u306e\\u69cb\\u7bc9\\u65b9\\u6cd5\\u3084\\u8a2d\\u5b9a\\u624b\\u9806\\u3001\\u30df\\u30c9\\u30eb\\u30a6\\u30a7\\u30a2\\u306e\\u30a4\\u30f3\\u30b9\\u30c8\\u30fc\\u30eb\\u624b\\u9806\\u30fb\\u30c8\\u30e9\\u30d6\\u30eb\\u5bfe\\u5fdc\\u306a\\u3069\\u3092\\u30b3\\u30de\\u30f3\\u30c9\\u4ed8\\u304d\\u3067\\u8a73\\u3057\\u304f\\u89e3\\u8aac\\u3057\\u307e\\u3059\\u3002\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":\"https:\/\/xn--o9j8h1c9hb5756dt0ua226amc1a.com\/?s={search_term_string}\",\"query-input\":\"required name=search_term_string\"}],\"inLanguage\":\"ja\"},{\"@type\":\"ImageObject\",\"@id\":\"https:\/\/xn--o9j8h1c9hb5756dt0ua226amc1a.com\/?p=1434#primaryimage\",\"inLanguage\":\"ja\",\"url\":\"https:\/\/xn--o9j8h1c9hb5756dt0ua226amc1a.com\/wp-content\/uploads\/2018\/09\/a049.png\",\"contentUrl\":\"https:\/\/xn--o9j8h1c9hb5756dt0ua226amc1a.com\/wp-content\/uploads\/2018\/09\/a049.png\",\"width\":480,\"height\":200},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/xn--o9j8h1c9hb5756dt0ua226amc1a.com\/?p=1434#webpage\",\"url\":\"https:\/\/xn--o9j8h1c9hb5756dt0ua226amc1a.com\/?p=1434\",\"name\":\"Git \\u30b5\\u30fc\\u30d0\\u30fc\\u3092 CentOS 7 \\u3067\\u69cb\\u7bc9\\u3059\\u308b\\u65b9\\u6cd5\\u3068\\u8a2d\\u5b9a\\u624b\\u9806 - \\u30b5\\u30fc\\u30d0\\u30fc\\u69cb\\u7bc9\\u3068\\u8a2d\\u5b9a \\uff5e\\u521d\\u5fc3\\u8005\\u306b\\u3082\\u5206\\u304b\\u308a\\u3084\\u3059\\u304f\\u89e3\\u8aac\\uff5e\",\"isPartOf\":{\"@id\":\"https:\/\/xn--o9j8h1c9hb5756dt0ua226amc1a.com\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/xn--o9j8h1c9hb5756dt0ua226amc1a.com\/?p=1434#primaryimage\"},\"datePublished\":\"2018-09-18T14:55:43+00:00\",\"dateModified\":\"2020-02-22T16:33:18+00:00\",\"author\":{\"@id\":\"https:\/\/xn--o9j8h1c9hb5756dt0ua226amc1a.com\/#\/schema\/person\/eca4427d8eab937cb2651081ddfb91ac\"},\"breadcrumb\":{\"@id\":\"https:\/\/xn--o9j8h1c9hb5756dt0ua226amc1a.com\/?p=1434#breadcrumb\"},\"inLanguage\":\"ja\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/xn--o9j8h1c9hb5756dt0ua226amc1a.com\/?p=1434\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/xn--o9j8h1c9hb5756dt0ua226amc1a.com\/?p=1434#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"item\":{\"@type\":\"WebPage\",\"@id\":\"https:\/\/xn--o9j8h1c9hb5756dt0ua226amc1a.com\/\",\"url\":\"https:\/\/xn--o9j8h1c9hb5756dt0ua226amc1a.com\/\",\"name\":\"\\u30db\\u30fc\\u30e0\"}},{\"@type\":\"ListItem\",\"position\":2,\"item\":{\"@id\":\"https:\/\/xn--o9j8h1c9hb5756dt0ua226amc1a.com\/?p=1434#webpage\"}}]},{\"@type\":\"Person\",\"@id\":\"https:\/\/xn--o9j8h1c9hb5756dt0ua226amc1a.com\/#\/schema\/person\/eca4427d8eab937cb2651081ddfb91ac\",\"name\":\"\\u7ba1\\u7406\\u4eba\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","jetpack_featured_media_url":"https:\/\/xn--o9j8h1c9hb5756dt0ua226amc1a.com\/wp-content\/uploads\/2018\/09\/a049.png","_links":{"self":[{"href":"https:\/\/xn--o9j8h1c9hb5756dt0ua226amc1a.com\/index.php?rest_route=\/wp\/v2\/posts\/1434"}],"collection":[{"href":"https:\/\/xn--o9j8h1c9hb5756dt0ua226amc1a.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/xn--o9j8h1c9hb5756dt0ua226amc1a.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/xn--o9j8h1c9hb5756dt0ua226amc1a.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/xn--o9j8h1c9hb5756dt0ua226amc1a.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=1434"}],"version-history":[{"count":1,"href":"https:\/\/xn--o9j8h1c9hb5756dt0ua226amc1a.com\/index.php?rest_route=\/wp\/v2\/posts\/1434\/revisions"}],"predecessor-version":[{"id":4376,"href":"https:\/\/xn--o9j8h1c9hb5756dt0ua226amc1a.com\/index.php?rest_route=\/wp\/v2\/posts\/1434\/revisions\/4376"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/xn--o9j8h1c9hb5756dt0ua226amc1a.com\/index.php?rest_route=\/wp\/v2\/media\/1485"}],"wp:attachment":[{"href":"https:\/\/xn--o9j8h1c9hb5756dt0ua226amc1a.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=1434"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/xn--o9j8h1c9hb5756dt0ua226amc1a.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=1434"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/xn--o9j8h1c9hb5756dt0ua226amc1a.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=1434"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}