mirror of
https://github.com/ENSL/ensl.org.git
synced 2024-12-26 04:21:36 +00:00
Update Dockerfile + docs
This commit is contained in:
parent
b1b39e42a8
commit
86d098b74d
4 changed files with 12 additions and 6 deletions
|
@ -2,6 +2,13 @@
|
|||
|
||||
Install instructions in INSTALL.md
|
||||
|
||||
1. Everything should be running on containers.
|
||||
1. If you need to run stuff on your host (eg. ruby, rubocop, bundle install etc) run all commands from the: `Dockerfile.dev`. It should setup identical setup for your machine.
|
||||
1. Add docker container names to /etc/hosts. This makes it possible to run test from local machine without using the container since editor/IDE don't integrate with Docker so well.
|
||||
|
||||
sudo echo `docker inspect -f '{{range .NetworkSettings.Networks}}{{.IPAddress}}{{end}}' ensl_dev_db` db >> /etc/hosts
|
||||
1. To run VS Code plugin Ruby Test Explorer in docker container you need to create path to custom
|
||||
|
||||
This is just random tips for development. Not a full documentation.
|
||||
|
||||
# Handy commands
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
FROM ruby:2.4.9
|
||||
FROM ruby:2.5.7
|
||||
|
||||
ENV RAILS_ENV production
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
|
||||
ENSL Website is fairly easy to run.
|
||||
|
||||
## 1. Install docker and docker-compose
|
||||
## 1. Install requirements: docker, docker-compose and git
|
||||
|
||||
https://docs.docker.com/install/
|
||||
https://docs.docker.com/compose/install/
|
||||
|
@ -12,9 +12,7 @@ Install docker + docker-compose:
|
|||
wget -O - 'https://get.docker.com/'|bash
|
||||
sudo curl -L https://github.com/docker/compose/releases/download/1.18.0/docker-compose-`uname -s`-`uname -m` -o /usr/local/bin/docker-compose
|
||||
|
||||
## 2. Install git
|
||||
|
||||
https://git-scm.com/book/en/v2/Getting-Started-Installing-Git
|
||||
Install git: https://git-scm.com/book/en/v2/Getting-Started-Installing-Git
|
||||
|
||||
sudo apt-get install nginx
|
||||
|
||||
|
@ -36,7 +34,7 @@ Finally, Start the docker containers.
|
|||
docker-compose build
|
||||
docker-compose --rm up
|
||||
|
||||
## 4. Install reverse proxy
|
||||
## 4. Install reverse proxy (production only)
|
||||
|
||||
Install apache, nginx etc. reverse proxy. It will take requests from the users and pass them to ENSL website. Sample configuration availble @ ext/nginx.
|
||||
|
||||
|
|
|
@ -83,6 +83,7 @@ services:
|
|||
#tty: true
|
||||
command: mysqld_safe --skip-grant-tables
|
||||
image: mariadb:latest
|
||||
container_name: ensl_dev_db
|
||||
volumes:
|
||||
- "./db_data:/var/lib/mysql"
|
||||
- "./ext/mysql.conf.d:/etc/mysql/conf.d"
|
||||
|
|
Loading…
Reference in a new issue