Giter VIP home page Giter VIP logo

Comments (20)

mateomorrison avatar mateomorrison commented on July 21, 2024

First: Create your Docker Machine.

docker-machine create \
  --driver digitalocean \
  --digitalocean-access-token <Your API Key> \
  --digitalocean-size 1gb \
yoonic

Second: Point your Docker to launch containers
eval "$(docker-machine env yoonic)"

Third: Run Yoonic

??? How to do it

from nicistore.

mateomorrison avatar mateomorrison commented on July 21, 2024

@andreftavares When running the command, I think the structure should be like this:

docker run -d
-p 80:80 (what port?)
-e ROOT_URL="http://website.com"
docker:docker what hub.docker.com repository, if there is any?

from nicistore.

andrecrt avatar andrecrt commented on July 21, 2024

Well... it all depends on the level of orchestration you want. The simplest approach is to launch a droplet using the Docker Application they provide, which provide you an environment suitable for running your containers out-of-the-box.

Then you would launch 3 containers: rethinkdb, atlas and nicistore.

You can use the "Dockerfile" from atlas/nicistore or base your own on it. They are in a production state of development, so you can use them.

from nicistore.

mateomorrison avatar mateomorrison commented on July 21, 2024

Can you tell me which commands to use to get it started? First lo launch nicistore and test it against nicistore.com API. @andreftavares

from nicistore.

andrecrt avatar andrecrt commented on July 21, 2024
  1. docker build -t yoonic/nicistore .
  2. docker run -d --name nicistore -p 3000:3000 -t yoonic/nicistore

from nicistore.

mateomorrison avatar mateomorrison commented on July 21, 2024

@andreftavares Some errors found:
docker-build -t yoonic/nicistore

"docker build" requires exactly 1 argument(s).
See 'docker build --help'

Usage: docker build [OPTIONS] PATH | URL | -

Build an image from a Dockerfile`

and docker run -d --name nicistore -p 3000:3000 -t yoonic/nicistore

Unable to find image 'yoonic/nicistore:latest' locally
docker: Error response from daemon: repository yoonic/nicistore not found: does not exist or no pull access.
See 'docker run --help'.

I think you should have a repository on https://hub.docker.com/ too to have it working.

from nicistore.

andrecrt avatar andrecrt commented on July 21, 2024
  1. You need the "." on the end of the build command I posted. It means that the dockerfile is in the current directory.
  2. Run won't work if the image does not exist. Since build failed, run will fail.

from nicistore.

mateomorrison avatar mateomorrison commented on July 21, 2024

If anyone gets confused. To run the commands the actual process is:

  1. git clone https://github.com/yoonic/nicistore.git && cd nicistore
    Need to git clone
  2. docker build -t yoonic/nicistore .
    This step will actually build the environment and run all needed commands.
  3. docker run -d --name nicistore -p 3000:3000 -t yoonic/nicistore
    Running your macine!
  4. Check docker-machine ls it should show Running on STATE.
  5. Check docker ps -a it should have yoonic/nicistore on IMAGE.

Added as a gist for those interested πŸ’―
This worked for me!

from nicistore.

mateomorrison avatar mateomorrison commented on July 21, 2024

Thanks @andreftavares

One more thing:
When I docker-machine ip <machine name> it outputs my IP Address. But when I access it on my website it's not showing anything. So I can't point out my DNS.

Maybe because it's showing to 0.0.0.0:3000 instead of :3000?

If so how to fix it?
screen shot 2017-02-26 at 8 05 41 pm

from nicistore.

mateomorrison avatar mateomorrison commented on July 21, 2024

When I docker inspect the container it shows me the host IP as 0.0.0.0 and Port 3000. Why is this container not connecting to my docker-machine and actually now showing anything. Something done wrong? @andreftavares

from nicistore.

andrecrt avatar andrecrt commented on July 21, 2024

I don't have any experience with Docker Machine. Sorry, can't help you with that :/

from nicistore.

phoenixvk avatar phoenixvk commented on July 21, 2024

from nicistore.

mateomorrison avatar mateomorrison commented on July 21, 2024

@phoenixvk Any quickstart? Which commands should I use?

pm2 -v
2.4.0

node -v
4.8.0

npm -v
2.15.11

from nicistore.

mateomorrison avatar mateomorrison commented on July 21, 2024

@andreftavares @phoenixvk
I don't think open a new issue is necessary. I successfully installed npm install the nicistore like it was on my PC. But still the ip 0.0.0.0 is giving error. You should fix that to auto assign the IP, otherwise I don't see any other way to have this as a real store than just hacking around in the local machine.

It all compiled perfect but when going to the IP Address. Nothing shows up. Here is the timeline

  1. git clone https://github.com/yoonic/nicistore.git && cd nicistore
  2. npm install
    Had to add a SWAP file because npm is memory consuming
  3. **Success, installed πŸ‘ **
  4. Running npm run build ... Done
  5. Running npm run dev ... Done .... Until
  6. Stopped at 'webpack: Compiled successfully.'
    Huh? Maybe it's already working! Let me go to my Digital Ocean Droplet IPV4 address.
  7. Nothing shows up πŸ‘Ž

UPDATE: To fix it, access YOUR.IP.ADDRESS.HERE:**3000**

Accessing using the port 3000 fix the issue πŸ‘

If you need to point out DNS to your IP droplet, run this command and it will redirect any request from port 80 to port 3000, which is where Nicistore is listening.
sudo iptables -t nat -A PREROUTING -i eth0 -p tcp --dport 80 -j REDIRECT --to-port 3000

Source

from nicistore.

phoenixvk avatar phoenixvk commented on July 21, 2024

I did follow this tutorial. It worked for me πŸ‘ https://www.youtube.com/watch?v=kR06NoSzAXY

from nicistore.

mateomorrison avatar mateomorrison commented on July 21, 2024

@phoenixvk It was great! I learned how to do both, by failing over and over. However I strongly recommend hosting it on a container of Docker. Learning how to Nginx and Lets Encrypt docker now.

from nicistore.

phoenixvk avatar phoenixvk commented on July 21, 2024

@mateomorrison how did you fix issue with ip address 0.0.0.0:3000? I'm not getting I'm having same issue with docker

from nicistore.

phoenixvk avatar phoenixvk commented on July 21, 2024

@andreftavares How did you deploy Nicistore and Atlas any doc available?

from nicistore.

phoenixvk avatar phoenixvk commented on July 21, 2024

@mateomorrison anybody can elaborate step by step process to deploy this app using docker

from nicistore.

phoenixvk avatar phoenixvk commented on July 21, 2024

@andreftavares @mateomorrison @briankereszturi I've same query which mateo have that

When I docker inspect the container it shows me the host IP as 0.0.0.0 and Port 3000. Why is this container not connecting to my docker-machine and actually now showing anything. Something done wrong?
Please resolve my issue. thank you.

from nicistore.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    πŸ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. πŸ“ŠπŸ“ˆπŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❀️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.