Advertisement
Guest User

Untitled

a guest
Jan 15th, 2025
227
0
180 days
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 7.12 KB | None | 0 0
  1.  
  2. # Getting Started
  3.  
  4. Welcome to the Cosmos documentation. There are two ways to run Cosmos
  5.  
  6.  * (BETA) as a standalone service on your system. This will be the recommended way to run Cosmos moving forward, as it will allow you to use all of its features. It is currently still new, so if you find an issue with the installtion, please report it on Discord or Github! Go to the [standalone service](#install-cosmos-as-a-standalone-service) section to learn how to install Cosmos this way.
  7.  
  8.  * as a Docker container. This is the easiest way to run Cosmos, but it will limit some of its features. Especially for the storage management. Go to the [Docker container](#install-cosmos-as-a-docker-container) section to learn how to install Cosmos this way.
  9.  
  10. ## Install Cosmos as a standalone service
  11.  
  12. ### Automatic installation
  13.  
  14. You can install Cosmos with the following command:
  15.  
  16. ```bash
  17. # IF YOU NEED TO CHANGE THE PORTS, DO IT BEFORE RUNNING THE COMMAND
  18. # You can overwrite any other env var by adding them here
  19. export COSMOS_HTTP_PORT=80
  20. export COSMOS_HTTPS_PORT=443
  21.  
  22. # You can run a dry run to see what will be installed
  23. curl -fsSL https://cosmos-cloud.io/get.sh | sudo -E bash -s -- --dry-run
  24.  
  25. # If you are happy with the result, you can run the command
  26. curl -fsSL https://cosmos-cloud.io/get.sh | sudo -E bash -s
  27. ```
  28.  
  29. This command will install/update dependencies such as Snapraid, Avahi, Docker, Docker-Compose, ... and finally install Cosmos as a service. It will also check your firewall setup and start the service. You can check the script [here](https://cosmos-cloud.io/get.sh). Before running it.
  30.  
  31. If Cosmos fails to start, you can either check the logs with `sudo journalctl -u CosmosCloud` or check the logs in the config folder at `/var/lib/cosmos/cosmos.log`.
  32.  
  33. Finally, you can see the logs directly by starting Cosmos manually with
  34.  
  35. ```bash
  36. sudo /opt/cosmos/cosmos
  37. ```
  38.  
  39. ### Manual installation
  40.  
  41. If you prefer to install Cosmos manually, you can follow the following steps:
  42.  
  43. 1. Install Docker and Docker-Compose. You can find the installation instructions on the [official Docker website](https://docs.docker.com/engine/installation/).
  44.  
  45. 2. Install dependencies
  46.  
  47. ```bash
  48. # for debian/ubuntu
  49. sudo apt-get update
  50. sudo apt-get install -y ca-certificates openssl fdisk mergerfs snapraid
  51.  
  52. # for centos
  53. sudo yum install -y ca-certificates openssl fdisk mergerfs snapraid
  54.  
  55. # for fedora
  56. sudo dnf install -y ca-certificates openssl fdisk mergerfs snapraid
  57.  
  58. # for arch
  59. sudo pacman -Sy ca-certificates openssl fdisk mergerfs snapraid
  60. ```
  61.  
  62. 3. Download the latest release of Cosmos from the [GitHub releases page](https://github.com/azukaar/Cosmos-Server/releases) and extract it to a folder of your choice.
  63.  
  64. 4. Run the following command to start Cosmos:
  65.  
  66. ```bash
  67. cd /path/to/cosmos
  68. sudo ./cosmos service install
  69. sudo systemctl start CosmosCloud
  70. ```
  71.  
  72. This will create a systemd service for Cosmos and start it.
  73.  
  74. ### Management
  75.  
  76. The resulting Cosmos daemon is a systemd service. You can manage it with the following commands:
  77.  
  78. ```bash
  79. sudo systemctl start CosmosCloud
  80. sudo systemctl stop CosmosCloud
  81. sudo systemctl restart CosmosCloud
  82. sudo systemctl status CosmosCloud
  83.  
  84. # If you want to see the system logs
  85. sudo journalctl -u CosmosCloud
  86. ```
  87.  
  88. You can also find the logs directly **in the config page** OR in the config folder:
  89.  
  90. ```bash
  91. # If you want to see the Cosmos logs
  92. cat /var/lib/cosmos/cosmos.log
  93.  
  94. # If you want to see the plain logs (without the terminal formatting)
  95. cat /var/lib/cosmos/cosmos.plain.log
  96. ```
  97.  
  98.  
  99. # Getting Started
  100.  
  101.  
  102. Welcome to the Cosmos documentation. There are two ways to run Cosmos
  103.  
  104.  
  105.  * (BETA) as a standalone service on your system. This will be the recommended way to run Cosmos moving forward, as it will allow you to use all of its features. It is currently still new, so if you find an issue with the installtion, please report it on Discord or Github! Go to the [standalone service](#install-cosmos-as-a-standalone-service) section to learn how to install Cosmos this way.
  106.  
  107.  
  108.  * as a Docker container. This is the easiest way to run Cosmos, but it will limit some of its features. Especially for the storage management. Go to the [Docker container](#install-cosmos-as-a-docker-container) section to learn how to install Cosmos this way.
  109.  
  110.  
  111. ## Install Cosmos as a standalone service
  112.  
  113.  
  114. ### Automatic installation
  115.  
  116.  
  117. You can install Cosmos with the following command:
  118.  
  119.  
  120. ```bash
  121. # IF YOU NEED TO CHANGE THE PORTS, DO IT BEFORE RUNNING THE COMMAND
  122. # You can overwrite any other env var by adding them here
  123. export COSMOS_HTTP_PORT=80
  124. export COSMOS_HTTPS_PORT=443
  125.  
  126.  
  127. # You can run a dry run to see what will be installed
  128. curl -fsSL https://cosmos-cloud.io/get.sh | sudo -E bash -s -- --dry-run
  129.  
  130.  
  131. # If you are happy with the result, you can run the command
  132. curl -fsSL https://cosmos-cloud.io/get.sh | sudo -E bash -s
  133. ```
  134.  
  135.  
  136. This command will install/update dependencies such as Snapraid, Avahi, Docker, Docker-Compose, ... and finally install Cosmos as a service. It will also check your firewall setup and start the service. You can check the script [here](https://cosmos-cloud.io/get.sh). Before running it.
  137.  
  138.  
  139. If Cosmos fails to start, you can either check the logs with `sudo journalctl -u CosmosCloud` or check the logs in the config folder at `/var/lib/cosmos/cosmos.log`.
  140.  
  141.  
  142. Finally, you can see the logs directly by starting Cosmos manually with
  143.  
  144.  
  145. ```bash
  146. sudo /opt/cosmos/cosmos
  147. ```
  148.  
  149.  
  150. ### Manual installation
  151.  
  152.  
  153. If you prefer to install Cosmos manually, you can follow the following steps:
  154.  
  155.  
  156. 1. Install Docker and Docker-Compose. You can find the installation instructions on the [official Docker website](https://docs.docker.com/engine/installation/).
  157.  
  158.  
  159. 2. Install dependencies
  160.  
  161.  
  162. ```bash
  163. # for debian/ubuntu
  164. sudo apt-get update
  165. sudo apt-get install -y ca-certificates openssl fdisk mergerfs snapraid
  166.  
  167.  
  168. # for centos
  169. sudo yum install -y ca-certificates openssl fdisk mergerfs snapraid
  170.  
  171.  
  172. # for fedora
  173. sudo dnf install -y ca-certificates openssl fdisk mergerfs snapraid
  174.  
  175.  
  176. # for arch
  177. sudo pacman -Sy ca-certificates openssl fdisk mergerfs snapraid
  178. ```
  179.  
  180.  
  181. 3. Download the latest release of Cosmos from the [GitHub releases page](https://github.com/azukaar/Cosmos-Server/releases) and extract it to a folder of your choice.
  182.  
  183.  
  184. 4. Run the following command to start Cosmos:
  185.  
  186.  
  187. ```bash
  188. cd /path/to/cosmos
  189. sudo ./cosmos service install
  190. sudo systemctl start CosmosCloud
  191. ```
  192.  
  193.  
  194. This will create a systemd service for Cosmos and start it.
  195.  
  196.  
  197. ### Management
  198.  
  199.  
  200. The resulting Cosmos daemon is a systemd service. You can manage it with the following commands:
  201.  
  202.  
  203. ```bash
  204. sudo systemctl start CosmosCloud
  205. sudo systemctl stop CosmosCloud
  206. sudo systemctl restart CosmosCloud
  207. sudo systemctl status CosmosCloud
  208.  
  209.  
  210. # If you want to see the system logs
  211. sudo journalctl -u CosmosCloud
  212. ```
  213.  
  214.  
  215. You can also find the logs directly **in the config page** OR in the config folder:
  216.  
  217.  
  218. ```bash
  219. # If you want to see the Cosmos logs
  220. cat /var/lib/cosmos/cosmos.log
  221.  
  222.  
  223. # If you want to see the plain logs (without the terminal formatting)
  224. cat /var/lib/cosmos/cosmos.plain.log
  225. ```
  226.  
  227.  
  228.  
  229.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement