From 5d8b8c6dbdc7369b2a4b57b915836daf94f9f8ed Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tao=20Bojl=C3=A9n?= <2803708-tao_oat@users.noreply.gitlab.com> Date: Tue, 21 Apr 2020 20:30:34 +0100 Subject: [PATCH] update README with podman instructions --- README.md | 9 ++++--- docker-compose.yml | 65 ---------------------------------------------- 2 files changed, 5 insertions(+), 69 deletions(-) delete mode 100644 docker-compose.yml diff --git a/README.md b/README.md index a7ce42c..0f0c3a1 100644 --- a/README.md +++ b/README.md @@ -20,7 +20,9 @@ Read the latest updates on Mastodon: [@fediversespace](https://mastodon.social/@ ## Requirements -Though dockerized, backend development is easiest if you have the following installed. +Note: examples here use `podman`. In most cases you should be able to replace `podman` with `docker`, `podman-compose` with `docker-compose`, and so on. + +Though containerized, backend development is easiest if you have the following installed. - For the scraper + API: - Elixir @@ -36,9 +38,8 @@ Though dockerized, backend development is easiest if you have the following inst ### Backend - `cp example.env .env` and modify environment variables as required -- `docker-compose build` -- `docker-compose up -d phoenix` - - if you don't specify `phoenix`, it'll also start `gephi` which should only be run as a regular one-off job +- `podman-compose build` +- `podman-compose -f compose.backend-services.yml -f compose.phoenix.yml` - Create the elasticsearch index: - `iex -S mix app.start` - `Elasticsearch.Index.hot_swap(Backend.Elasticsearch.Cluster, :instances)` diff --git a/docker-compose.yml b/docker-compose.yml deleted file mode 100644 index fb39f81..0000000 --- a/docker-compose.yml +++ /dev/null @@ -1,65 +0,0 @@ -version: "3" -services: - db: - image: postgres - environment: - - DATABASE_URL - ports: - - "5432:5432" - volumes: - - pgdata:/var/lib/postgresql/data - networks: - - database_network - elasticsearch: - image: elasticsearch:6.8.1 - ports: - - "9200:9200" - volumes: - - esdata:/usr/share/elasticsearch/data - networks: - - phoenix_network - - es_network - # Kibana is just for development, really - kibana: - image: kibana:6.8.1 - networks: - - es_network - ports: - - "5601:5601" - # This is for running the occasional graph layout task. It's in docker-compose.yml so that it's built at the same time - # as everything else, but it should be run regularly with a cron job or similar. - gephi: - environment: - - DATABASE_URL - build: ./gephi - volumes: - - gradle-cache:/code/.gradle - depends_on: - - db - networks: - - database_network - phoenix: - build: ./backend - networks: - - database_network - - phoenix_network - depends_on: - - db - ports: - - "${PORT}:${PORT}" - environment: - - DATABASE_URL - - SECRET_KEY_BASE - - PORT - - BACKEND_HOSTNAME -volumes: - pgdata: - esdata: - gradle-cache: -networks: - database_network: - driver: bridge - phoenix_network: - driver: bridge - es_network: - driver: bridge