Giter VIP home page Giter VIP logo

Comments (7)

inshop avatar inshop commented on August 24, 2024

Hi, try to remove DB volume db-data and recreate docker containers, if you updated .env file after the first setup.

from inshop-crm-admin.

chephei avatar chephei commented on August 24, 2024

I remade my docker-compose and the removal of the container and volumes, but it is still showing error in the script execution:
docker-compose exec --user=www-data php sh ./setup.sh
In Http.php line 190: Couldn't resolve host

Log PHP:

client_1         | 192.168.192.1 - - [22/Sep/2020:14:49:19 +0000] "GET /signin HTTP/1.1" 304 0 "-" "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/85.0.4183.121 Safari/537.36"
php_1            | 192.168.176.7 -  22/Sep/2020:14:49:22 +0000 "POST /index.php" 401

from inshop-crm-admin.

inshop avatar inshop commented on August 24, 2024

Please check if all your container running by command docker-compose ps

from inshop-crm-admin.

chephei avatar chephei commented on August 24, 2024
           Name                         Command                State           Ports        
--------------------------------------------------------------------------------------------
inshop-crm_api_nginx                    /docker-entrypoint.sh ngin ...   Up        0.0.0.0:8888->80/tcp
inshop-crm_api_php                      docker-php-entrypoint php-fpm    Up        9000/tcp            
inshop-crm_client_nginx                 /docker-entrypoint.sh ngin ...   Up        0.0.0.0:8080->80/tcp
inshop-crm_db_1              docker-entrypoint.sh postgres    Up        5432/tcp            
inshop-crm_elasticsearch_1   /usr/local/bin/docker-entr ...   Exit 78                       
inshop-crm_redis_1           docker-entrypoint.sh redis ...   Up        6379/tcp

from inshop-crm-admin.

inshop avatar inshop commented on August 24, 2024

This is a problem with elasticsearch.

Elastic search settings on host machine

sudo sysctl -w vm.max_map_count=262144
echo "vm.max_map_count=262144" | sudo tee -a /etc/sysctl.conf

from inshop-crm-admin.

chephei avatar chephei commented on August 24, 2024

elastic worked now, but my client is experiencing an error:

PoGqJoG

php_1            | [28-Sep-2020 21:04:57] NOTICE: fpm is running, pid 1
php_1            | [28-Sep-2020 21:04:57] NOTICE: ready to handle connections
php_1            | 172.24.0.7 -  28/Sep/2020:21:05:11 +0000 "POST /index.php" 500

my .env

PORT_DATABASE=54321
PORT_API=8888
PORT_CLIENT=8080
PORT_ELASTIC=9222
APP_ENV=dev
APP_SECRET=mypass
TRUSTED_PROXIES=127.0.0.1,127.0.0.2,142.93.144.141
TRUSTED_HOSTS=127.0.0.1,localhost,crm.mydomain.com
CORS_ALLOW_ORIGIN=^https?://localhost(:[0-9]+)?$
DATABASE_DRIVER=pdo_pgsql
DATABASE_HOST=db
DATABASE_PORT=5432
DATABASE_NAME=api
DATABASE_USER=api
DATABASE_PASSWORD=mypass
JWT_PASSPHRASE=mypass
SENTRY_DSN=
COMPOSE_PROJECT_NAME=sigcrm
MAILER_URL=null://localhost
CLIENT_URL=http://localhost:3000
GOOGLE_API_KEY=
GOOGLE_CLIENT_ID=
GOOGLE_CLIENT_SECRET=
AWS_S3_ACCESS_ID=
AWS_S3_ACCESS_SECRET=
AWS_S3_BUCKET_FILE_NAME=file
AWS_S3_BUCKET_IMAGE_NAME=image
AWS_S3_BUCKET_REGION=eu-west-1
REDIS_HOST=redis
REDIS_PORT=6379

docker-compose.yml

version: '3.2'

services:
  client:
    restart: always
    image: inshopgroup/inshop-crm-client
    env_file:
      - ./.env
    ports:
      - ${PORT_CLIENT}:80
    networks:
      - api
      - esnet

  php:
    image: inshopgroup/docker-inshop-crm-api-php-fpm-prod:latest
    depends_on:
      - db
    env_file:
      - ./.env
    volumes:
      - .:/var/www:rw,cached
      - files-data:/var/www/var/files:rw
    networks:
      - api

  nginx:
    image: inshopgroup/docker-inshop-crm-api-nginx-prod:latest
    depends_on:
      - php
    volumes:
      - ./public:/var/www/public:ro
    ports:
      - ${PORT_API}:80
    networks:
      - api

  db:
    image: postgres:11.4-alpine
    environment:
      - POSTGRES_DB=${DATABASE_NAME}
      - POSTGRES_USER=${DATABASE_USER}
      - POSTGRES_PASSWORD=${DATABASE_PASSWORD}
    volumes:
      - db-data:/var/lib/postgresql/data:rw
    ports:
      - ${PORT_DATABASE}:5432
    networks:
      - api

  elasticsearch:
    image: docker.elastic.co/elasticsearch/elasticsearch:6.3.1
    environment:
      - bootstrap.memory_lock=true
      - "ES_JAVA_OPTS=-Xms512m -Xmx512m"
    ulimits:
      memlock:
        soft: -1
        hard: -1
    volumes:
      - es-data:/usr/share/elasticsearch/data
    ports:
      - ${PORT_ELASTIC}:9200
    networks:
      - api
      - esnet

  redis:
    image: redis:latest
    volumes:
      - redis-data:/var/lib/redis
    networks:
      - api

volumes:
  es-data: {}
  db-data: {}
  redis-data: {}
  files-data: {}
  images-data: {}

networks:
    esnet:
    api:

from inshop-crm-admin.

inshop avatar inshop commented on August 24, 2024

Use your JWT_PASSPHRASE password from .env file while generating jwt keys.
Check the first few lines in the setup.sh file:

openssl rsa -pubout -in config/jwt/private.pem -out config/jwt/public.pem
openssl rsa -in config/jwt/private.pem -out config/jwt/private2.pem
mv config/jwt/private.pem config/jwt/private.pem-back
mv config/jwt/private2.pem config/jwt/private.pem

from inshop-crm-admin.

Related Issues (1)

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.