# If you encounter any errors, publish them to: https://github.com/bennjii/open-stock/issues # # Please include: # - How you encountered the error # - The effect of the error # - Any associated media, i.e. screenshots or videos (If nessesary) version: '3.1' x-common-variables: &karrio-variables REDIS_HOST: redis REDIS_PORT: 6379 DATABASE_HOST: db DATABASE_NAME: db DATABASE_PORT: 5432 DATABASE_ENGINE: postgresql DATABASE_USERNAME: postgres DATABASE_PASSWORD: postgres POSTGRES_DB: db POSTGRES_USER: postgres POSTGRES_PASSWORD: postgres DEBUG_MODE: True SECRET_KEY: eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJlbWFpbCI6ImNvbnRhY3RAYmVubmppaS5kZXYiLCJwYXNzd29yZCI6IjEyMzQ1In0.gk_ecZxOEGu8k64PD6J25u7eUvI5Qm5Bg4giGTXGfII JWT_SECRET: eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJlbWFpbCI6ImNvbnRhY3RAYmVubmppaS5kZXYiLCJwYXNzd29yZCI6IjEyMzQ1In0.gk_ecZxOEGu8k64PD6J25u7eUvI5Qm5Bg4giGTXGfII services: # Optional Tool: Allows you to inspect the database when accessing locally. adminer: image: adminer restart: always ports: - "8080:8080" # -- OpenStock Data Storage os-db: image: mysql command: --default-authentication-plugin=mysql_native_password restart: always environment: # Customise the following for your own purposes. # It is not reccomended to use the default login information. # Note: In a deployed environment, do NOT make the port 3306 public. MYSQL_ROOT_PASSWORD: root MYSQL_DATABASE: stock MYSQL_USER: user MYSQL_PASSWORD: user ports: - "3306:3306" volumes: - datavolume:/var/lib/mysql # -- Kario -- # api: # container_name: karrio.api # image: karrio.docker.scarf.sh/karrio/server:2023.5 # restart: unless-stopped # ports: # - 5002:5002 # depends_on: # - db # - redis # environment: # <<: *karrio-variables # KARRIO_HTTP_PORT: 5002 # dashboard: # container_name: karrio.dashboard # image: karrio.docker.scarf.sh/karrio/dashboard:2023.5 # ports: # - 3000:3003/tcp # depends_on: # - api # environment: # <<: *karrio-variables # DASHBOARD_URL: http://localhost:3003 # KARRIO_PUBLIC_URL: http://localhost:5002 # maildev: # container_name: karrio.mail # image: maildev/maildev # restart: on-failure # ports: # - "1080:1080" # - "1025:1025" # db: # container_name: karrio.db # image: postgres # restart: unless-stopped # ports: # - 5432:5432 # environment: # <<: *karrio-variables # PGDATA: /var/lib/postgresql/data/karrio # volumes: # - postgres-data:/var/lib/postgresql/data # redis: # container_name: karrio.redis # image: redis # ports: # - 6379:6379 # restart: unless-stopped # volumes: # - redis-data:/data # --- OpenStock & OpenPOS open-stock: # Note: If you are running ARM, you are in luck! We support the linux/arm64 platform. # Please use the :latest-arm build variant for arm builds. image: bennjii/open-stock:latest # ghcr.io/bennjii/open-stock:latest-arm platform: "linux/arm64" restart: always ports: - "8000:8000" links: - "os-db:database" environment: - DATABASE_URL=mysql://root:root@database/stock # Set the following to whichever URL you host open-pos. This is passed into the CORS policy. # Accessing open-stock from any other origin will result in an error message. - ACCESS_ORIGIN=http://localhost:3001 # Change this to your own value, the current value is used only as an example key. - ROCKET_SECRET_KEY=e5c63abf90fb076d7037a32d8dc2951c4b402e7357ca84b0da8e03595f84b30f # Change this to 1 to enable demo. - DEMO=1 # Set your prefered debug log levels. - RUST_BACKTRACE=1 - RUST_LOG=debug - ROCKET_ADDRESS=0.0.0.0 # You may customise the port for open-stock to run on, note; this port must be handled correctly. - ROCKET_PORT=8000 - RELEASE_TYPE=dev volumes: datavolume: postgres-data: redis-data: