New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changed docker config and readme file #607
Conversation
Codecov Report
@@ Coverage Diff @@
## master #607 +/- ##
=======================================
Coverage 79.25% 79.25%
=======================================
Files 75 75
Lines 1523 1523
=======================================
Hits 1207 1207
Misses 316 316 Continue to review full report at Codecov.
|
@@ -23,8 +23,6 @@ services: | |||
|
|||
db: | |||
image: postgres:10 | |||
ports: | |||
- "5432:${CODEBATTLE_DB_PORT}" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Это нужно для локального запуска сервера при с использованием базы в докере. Вероятно мы можем поменять порт на другой, но удалять не стоит
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Я пробовала удалять, и локально всё запустилось, или оно на что-то другое может влиять?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Просто не всегда удобно запускать в докере сервер, но по-умолчанию рекомендуется запускать все в докере.
Тем не менее хочется сохранить все способы запуска
@@ -5,7 +5,6 @@ vault_codebattle_github_secret: "eaac6e0cb603e652a133bde58902507a13cb0901" | |||
vault_codebattle_db_hostname: "db" | |||
vault_codebattle_db_username: "postgres" | |||
vault_codebattle_db_password: "" | |||
vault_codebattle_db_port: 5432 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Переменную просто так удалять нельзя
@@ -20,7 +20,7 @@ | |||
- Clone repo | |||
|
|||
```bash | |||
$ git clone https://github.com/hexlet-codebattle/codebattle.git | |||
$ git clone git@github.com:hexlet-codebattle/codebattle.git | |||
$ cd codebattle | |||
$ mkdir -p tmp | |||
$ echo 'asdf' > tmp/ansible-vault-password |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Можно сократить шаги, добавив в development playbook шаг по добавлению "asdf" в tmp/ansible-vault-password
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
а, этого не нужно делать.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
достаточно удалить строку
https://github.com/hexlet-codebattle/codebattle/blob/master/ansible.cfg#L2
@@ -5,7 +5,7 @@ vault_codebattle_github_secret: "eaac6e0cb603e652a133bde58902507a13cb0901" | |||
vault_codebattle_db_hostname: "db" | |||
vault_codebattle_db_username: "postgres" | |||
vault_codebattle_db_password: "" | |||
vault_codebattle_db_port: 5432 | |||
vault_codebattle_db_port: 5445 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Вообще при разработке в докере эта переменная живет внутри контейнеров и ее значение никак не влияет на запуск. Достаточно той, которую экспоузит docker-compose
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
В таком случае какая разница, какой тут указан порт?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Это не так важно, но лучше дефолтный, потому что кастомный при отладке может сбить с толку
Minor changes have been made to simplify the installation of the project.