# Installing This document describes how to install the dsfx server on your machine. The dsfx server is a decentralized file exchange server that allows you to share files with other users in a secure and private way. The server is designed to be easy to install and configure, and it can be run on a variety of platforms. The server is written in Go, and it uses the Go toolchain for building and installing. The server is designed to be run as a standalone application, and it does not require any external dependencies. - [Setup](#setup) - [Dependencies](#dependencies) - [Git Setup](#git-setup) - [Installation](#installation) --- ## Setup Due to the maturity of the project, we haven't yet created a release strategy. We have, however, fully embraced the go ecosystem - so you can use the go toolchain to install the project from source. This is the recommended way to install the project, as it will always give you the latest version of the code. ### Dependencies - [git](https://git-scm.com/) - [golang](https://go.dev/) In many cases, these tools are available in your system package manager. Here are a few commands for various operating systems (not comprehensive): - **Ubuntu**: `sudo apt-get install git golang` - **Fedora**: `sudo dnf install git golang` - **Arch**: `sudo pacman -S git go` - **macOS**: `brew install git go` If the above commands don't work for you, please refer to the official documentation for your operating system. ### Git Setup Currently we are hosted on **gitea cloud**, which hides everything from the public internet by default. This means that the machine you are deploying to will need to be able to access the gitea cloud instance. One way to do this is to use the `.netrc` file in conjunction with a personal access token. Once you have a personal access token, you can create a `.netrc` file in your home directory with the following contents: ```plaintext machine koti.casa login password ``` Finally, you'll need to set the `GOPRIVATE` environment variable to allow go to fetch private repositories. You can do this by running the following command: ```bash export GOPRIVATE=koti.casa ``` If you want to persist this setting across sessions, you can add the above line to your `~/.bashrc` or `~/.bash_profile`. ### Stopping Point At this point, you should have the go toolchain installed and configured. If you only want to run the server, and you don't care to actually install it, you can you can skip directly the [deploying docs](./deploying.md). ### Installation Now that you have the go toolchain set up with access to our repository, you can simply install the project by using the `go install` command. ```bash go install koti.casa/numenorlabs/dsfx/cmd/dsfx@main ``` Assuming that you have the `GOPATH` environment variable set up correctly, you will now be able to run the `dsfx` command from the command line. If you are not able to, then you must configure your `GOPATH` environment variable.