Skip to content

Conversation

@kmjayadeep
Copy link

Closes #26

Application can be run in docker by using the command

docker-compose up

Signed-off-by: [email protected] [email protected]

@ankitjain28may
Copy link
Owner

@kmjayadeep Have you tried running the project with the attached docker-compose? Looks like you haven't gone through the project and added the docker-compose file.

image: mysql/mysql-server
command: --default-authentication-plugin=mysql_native_password
environment:
- MYSQL_ROOT_PASSWORD=root_pass
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What's the use of .env file if we are exposing them in docker-compose itself.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I will move them to the .env.docker file then

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As I see it .env files are great for situations where controlling the real environment variables is awkward, in the case of using docker-compose, or deploying to Kubernetes, using environment variables is usually the better and easier approach.
While env fils are well suited to local development.
What do you think @ankitjain28may?

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I just read the documentation of env_file in docker-compose, and wow, I did not realise it supported .env files directly :-) that is going to make things nicer sometimes!

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yeah, it supports .env

@kmjayadeep
Copy link
Author

@kmjayadeep Have you tried running the project with the attached docker-compose? Looks like you haven't gone through the project and added the docker-compose file.

Yes I have. Application is running fine inside docker. Actually, it didn't work properly outside docker as I have some issues with php installation. May I know what the problem is?

@ankitjain28may
Copy link
Owner

@kmjayadeep There is one more service that runs along with db and php server and that service is responsible for sending/receiving messages, Please add that service in the docker-compose and try to check whether it is working or not. The main idea of using supervisor is because of running both the services together

@kmjayadeep
Copy link
Author

Totally missed that! I will check again.
Sorry I'm no expert in php

@ankitjain28may
Copy link
Owner

@kmjayadeep No problem, if you need any help, ping me :)

Signed-off-by: Jayadeep KM <[email protected]>
@kmjayadeep
Copy link
Author

@ankitjain28may Added socket service. Please give a try.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Dockerize

3 participants