CDS (Continuous Delivery Service) is an open-source, enterprise-grade Continuous Integration and Continuous Delivery platform that you can use to automate building, testing, and deploying your applications. In this tutorial, we will guide you through the process of installing CDS onto NixOS Latest using the official package from the CDS website.
Before we start, ensure that you have:
To begin, we need to enable the CDS Nix package repository. To do this, we have to add the following lines to the /etc/nixos/configuration.nix
file.
nixpkgs.config.packageOverrides = pkgs: {
cds = pkgs.callPackage (builtins.fetchTarball "https://github.com/ovh/cds/archive/v0.44.1.tar.gz") {
skipSensors = true;
};
};
Note: The above code will install CDS version 0.44.1
, but you can replace it with any release you prefer.
Save the configuration file and run the following command to update the NixOS system:
sudo nixos-rebuild switch
Next, we need to create a system user account for CDS.
sudo useradd -r -U -d /var/lib/cds -s /bin/false cds
This command will create a system user account with no home directory (/var/lib/cds
), no login shell (/bin/false
), and no password (-r
).
Now we need to create a configuration directory for CDS and ensure that the cds
user has read and write permissions to this directory.
sudo mkdir -p /etc/cds
sudo chown -R cds:cds /etc/cds
CDS requires a data directory to store all its data files, which can be created using the following command:
sudo mkdir -p /var/lib/cds
sudo chown -R cds:cds /var/lib/cds
Finally, we can start the CDS daemon by running the following command:
sudo systemctl start cds
To ensure that the CDS daemon starts automatically at boot time, run the following command:
sudo systemctl enable cds
That's it! Now you have successfully installed CDS on NixOS Latest. You can access the web interface by opening a web browser and pointing it to http://your-server-ip:8080
. If you have any questions, feel free to refer to the official CDS documentation or the NixOS community.
If you want to self-host in an easy, hands free way, need an external IP address, or simply want your data in your own hands, give IPv6.rs a try!
Alternatively, for the best virtual desktop, try Shells!