IPFS.vue 3.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105
  1. <template>
  2. <NuxtLayout name="guides">
  3. <template #intro>
  4. <div class="max-w-xl">
  5. <h2 class="text-4xl font-extrabold text-gray-100 sm:text-5xl sm:tracking-tight lg:text-6xl">
  6. IPFS
  7. </h2>
  8. <p class="mt-5 text-xl text-indigo-300">
  9. Best practices when using IPFS.
  10. </p>
  11. </div>
  12. </template>
  13. <template #links>
  14. <div class="mt-10 w-full max-w-xs lg:mt-0">
  15. <label for="currency" class="block text-2xl font-medium text-indigo-400">
  16. Recommended Links
  17. </label>
  18. <div class="flex flex-col mt-1.5 pl-3 relative text-indigo-200">
  19. <div>
  20. ↳ <a href="https://docs.docker.com/engine/install/" target="_blank" class="hover:underline">
  21. Docker Engine Installation
  22. </a>
  23. </div>
  24. <div>
  25. ↳ <NuxtLink>
  26. Nuxt Link #2
  27. </NuxtLink>
  28. </div>
  29. <div>
  30. ↳ <NuxtLink>
  31. Nuxt Link #3
  32. </NuxtLink>
  33. </div>
  34. </div>
  35. </div>
  36. </template>
  37. <!-- Page Section -->
  38. <template #main>
  39. <section class="p-3 h-full bg-gradient-to-r from-gray-50 to-gray-100">
  40. <h1 class="mt-5 text-3xl font-bold">
  41. Deploy IPFS
  42. <small class="text-xs text-gray-500 uppercase">Infrastructure</small>
  43. </h1>
  44. <section class="py-10 max-w-5xl mx-auto">
  45. <div class="mt-3 p-5 font-medium bg-gray-100 border-4 border-gray-300 rounded-xl">
  46. Start IPFS (in a Docker container)
  47. <small class="block">
  48. NOTE: Create an executable file `start-ipfs.sh`
  49. </small>
  50. </div>
  51. <pre class="mt-5 p-5 bg-yellow-100 border-4 border-yellow-300 rounded-xl">
  52. <code>docker run
  53. -d
  54. --restart always
  55. --name ipfs_host
  56. -e IPFS_PROFILE=server
  57. -v $IPFS_STAGING:/export
  58. -v $IPFS_DATA:/data/ipfs
  59. -p 4001:4001
  60. -p 4001:4001/udp
  61. -p 127.0.0.1:8080:8080
  62. -p 127.0.0.1:5001:5001
  63. ipfs/kubo:latest</code></pre>
  64. </section>
  65. <section class="py-10 max-w-5xl mx-auto">
  66. <div class="mt-3 p-5 font-medium bg-gray-100 border-4 border-gray-300 rounded-xl">
  67. (optional) Mount to the Host System
  68. <small class="block">
  69. NOTE: Create an executable file `start-gateway.sh`
  70. </small>
  71. </div>
  72. <pre class="mt-5 p-5 bg-yellow-100 border-4 border-yellow-300 rounded-xl">
  73. <code>while true; do eval "$(cat /gateway/pipe)" &> /gateway/output; done</code></pre>
  74. </section>
  75. <!-- <h3 class="mt-10 text-2xl font-medium">
  76. Install Docker and Docker Compose
  77. </h3>
  78. <div class="my-5 w-3/4 border-4 border-yellow-300 bg-yellow-100 rounded-xl overflow-hidden">
  79. <textarea rows="1" class="-mb-2 p-5 w-full border-0 bg-yellow-100 line-through">apt install -y docker-ce docker-compose (DEPRECATED)</textarea>
  80. </div> -->
  81. </section>
  82. </template>
  83. <!-- <section class="mt-5">
  84. <p>
  85. Lorem ipsum dolor sit amet consectetur adipisicing elit. Ducimus, quasi magnam! Qui deleniti, nulla ipsam voluptatum, non quis ut libero at ipsum delectus, placeat perspiciatis. Atque repellat id earum dolorem?
  86. </p>
  87. </section> -->
  88. </NuxtLayout>
  89. </template>