mirror of
https://github.com/RD17/ambar.git
synced 2026-04-25 15:35:49 +03:00
[GH-ISSUE #284] How to Build Docker Containers #270
Labels
No labels
$$ Paid Support
bug
bug
enhancement
help wanted
invalid
pull-request
question
question
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/ambar#270
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @ark- on GitHub (Jun 22, 2020).
Original GitHub issue: https://github.com/RD17/ambar/issues/284
Hi. I had to work through multiple issues and the source code to get it working in my instance so I would like to pay it forward.
Build
git clone https://github.com/RD17/ambar.gitcd ~/ambar/FrontEndexport PORT={YOUR_WEB_FRONTEND_PORT)andexport FRONTEND_HOST={YOUR_HOST_IP}. I used80and192.168.1.1.node npm installnpm run compiledocker build . -t frontendcd ~/ambar/WebApidocker build . -t webapicd ~/ambar/ServiceApidocker build . -t serviceapicd ~/ambar/Redisdocker build . -t rediscd ~/ambar/Rabbitdocker build . -t rabbitcd ~/ambar/Pipelinedocker build . -t pipeline0cd ~/ambar/LocalCrawlerdocker build . -t localcrawlercd ~/ambar/MongoDBdocker build . -t mongodbcd ~/ambar/ElasticSearchdocker build . -t elasticsearchDocker Compose
My final docker compose:
The differences between my
docker-compose.ymland those listed https://ambar.cloud/docs/installation-docker/ are:imageattributes tobuildas I have built these locally- max_map_count=262144to elasticsearch environmentfrontendport to 82 as per step 3 above- apiUrl=http://serviceapi:8081to the crawler as it was polling the wrong port without thisFinally, to get it going:
@Sicaine commented on GitHub (Jul 4, 2020):
I hacked together a multi stage dockerfile for the Frontend. With it, you don't need to install anything on your host to build it:
I think it works, but i hacked it together and wanted to share it before i forget about it.
Btw. it doesn't build with nodejs 12 and there are plenty of warnings and deprecations for the used libs. So be careful if you put out the Frontend without protection.
@kitsune242 commented on GitHub (Jul 16, 2020):
THX
i build all but when docker start i have infinite loading screen and white board on localhost:82 in logs i dont see any errors. Anyone have similar problem ?
@ark- commented on GitHub (Jul 17, 2020):
I had this same issue. Take a look at step 3
If you compiling in a docker on the same machine (as I was) you'll also need to do this. Try setting these variables and see if this helps.
@kitsune242 commented on GitHub (Jul 17, 2020):
Unfortunately, it's still the same.
its look it connect to 172.17.0.2:3000 and cant connect to backend. I use this Export command i rebuild docker but still have this problem.
I may use them incorrectly or something
@mlucasdasilva commented on GitHub (Jul 28, 2020):
Instead of:
Try:
It worked for me.
It generated the files in
./FrontEnd/distwithout fixed IP and Port.@deyraka commented on GitHub (Jul 30, 2020):
I've following the instruction above. Unfortunately, I face the same issue.
there are no problem while docker-compose up. But, when I open {ipAddress}:82 it's only show white blank page with "Loading..." title
What did I miss?
@ark- commented on GitHub (Jul 30, 2020):
Unfortunately I cannot test as I have decided to stop using Ambar.
This is because 9 containers for document search is too many. Also ElasticSearch image seemed to always be using the CPU. I think Ambar was overkill for my purposes (home document scan search).
@iddqd-dev commented on GitHub (Jul 31, 2020):
Of course, windows indexing does a great job of searching through less than a million documents.
@deyraka commented on GitHub (Aug 3, 2020):
Hi, I think I found solution for my problem. Based on my trial in the last two days, I think the problem is the network config in docker-compose.yml.
When I tried the scenario to expose all service port to the host, frontend page appeared as it should. But, not when all service tried to connect each other via docker network.
It's good, finally the frontend page could be accessed. But, I'm sure that not a good choice to expose all the service port to the host which means our server would be more vulnerable from attacks.
Communication via docker network still being the best practice.
And then, I tried to modify docker-compose.yml by specifying network driver : bridge.
Voila, everything works good now.
Hopefully, this will help everyone who face the same issue
@ropheefd commented on GitHub (Aug 10, 2020):
I tried modifying docker-compose.yml with network driver: bridge, but I'm getting an error. Can you show your final docker-compose as I'm having the same issue as you are?
@stale[bot] commented on GitHub (Aug 27, 2020):
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.