---
title: How to set up an Ubuntu Linux machine for Phoenix Elixir deployment
date: '2023-01-29T00:00:00+00:00'
url: https://www.abhinav.co/setting-up-ubuntu-linux-for-phoenix-deployment
summary: You just need install a couple of packages to prepare your Ubuntu Linux machine
tags:
- Ubuntu
- Elixir
- Phoenix
- Deployment
author: Abhinav Saxena
---

# How to set up an Ubuntu Linux machine for Phoenix Elixir deployment

## Step 1
Install Elixir and Nginx

```sh
sudo apt-get install elixir nginx erlang-dev
```

You can also install databases (Postgres or MySQL) and Redis if you need them

### Step 2
Configure `hex` and `rebar` for deployment using `mix`, the project manager for Elixir.

```sh
# hex
$ mix local.hex --force
* creating .mix/archives/hex-2.0.1

# rebar
$ mix local.rebar --force
* creating .mix/rebar
* creating .mix/rebar3
```
