MyPersonalSpace

My space on the internet.

Getting Started

  1. Install asdf: https://asdf-vm.com/guide/getting-started.html
  2. Set up Elixir and Erlang versions used by project: asdf install
  3. Install dependencies: mix deps.get
  4. Compile the code: mix compile
  5. Set up the database: mix ecto.setup (sqlite is used for the database)
  6. Seed the database with dev data (optional): mix run priv/repo/dev_seeds.exs
  7. Run the server: iex -S mix phx.server
  8. Navigate to http://localhost:4000

Common Maintenance Tasks

Updating Dependencies

  • Run mix hex.outdated to see status of deps
  • Run mix deps.update --all to update deps that won't break (according to semver)
  • To update other deps, edit mix.exs with the new version and run mix deps.get

Updating Erlang/Elixir

For new versions of either:

  1. Update .tool-versions
  2. Run asdf install
  3. Update Dockerfile

Deploying

  1. Run fly deploy to deploy code to fly.dev
  2. Verify rollout is successful

Connect to Producton via iex

  1. Connect to production instance: fly ssh console
  2. Connect to running system via iex: ./bin/my_personal_space remote