Favicon of Saleor

Saleor

Architect complex, omnichannel shopping experiences using an open-source, headless commerce platform. Leverage robust GraphQL APIs to scale without lock-in.

This open-source, headless ecommerce platform provides engineering teams with the flexibility to construct custom, high-performance shopping experiences. Designed for complex commerce operations, it replaces rigid monolithic systems with a composable architecture that adapts to your specific business requirements. By decoupling the frontend from the backend, development teams can utilize their preferred technology stack while maintaining complete ownership of their data.

Key advantages include:

  • Robust GraphQL API: Query data efficiently and integrate seamlessly with any frontend framework or third-party service.
  • Extensible Dashboard: Manage products, orders, and translations through a powerful interface that supports custom UI extensions.
  • Commerce as Code: Automate configurations and deployments using CI/CD pipelines and version control.
  • Zero Vendor Lock-in: Maintain total control over your technology stack with transparent, open-source code.
  • Omnichannel Scalability: Process orders across web, mobile, and retail channels while handling massive traffic spikes.

Directory Structure

saleor
saleor-db
saleor-media
saleor-redis
.env
docker-compose.yml

docker-compose.yml

services:
  api:
    image: ghcr.io/saleor/saleor:3.19
    ports:
      - 8000:8000
    restart: unless-stopped
    networks:
      - saleor-backend-tier
    stdin_open: true
    tty: true
    depends_on:
      - db
      - redis
      - mailpit
    volumes:
      - ./saleor-media:/app/media
    environment:
      - SECRET_KEY=${SECRET_KEY}
      - DATABASE_URL=${DATABASE_URL}
      - ALLOWED_HOSTS=localhost,127.0.0.1
      - ALLOWED_CLIENT_HOSTS=localhost,127.0.0.1
      - EMAIL_URL=smtp://mailpit:1025
      - CELERY_BROKER_URL=redis://redis:6379/1
      - DEFAULT_CHANNEL_SLUG=default-channel
      - DEFAULT_FROM_EMAIL=noreply@example.com
    command: python manage.py runserver 0.0.0.0:8000

  dashboard:
    image: ghcr.io/saleor/saleor-dashboard:latest
    ports:
      - 9000:80
    restart: unless-stopped
    networks:
      - saleor-backend-tier
    environment:
      - API_URI=http://localhost:8000/graphql/

  db:
    image: postgres:15-alpine
    ports:
      - 5432:5432
    restart: unless-stopped
    networks:
      - saleor-backend-tier
    volumes:
      - ./saleor-db:/var/lib/postgresql/data
    environment:
      - POSTGRES_USER=${POSTGRES_USER}
      - POSTGRES_PASSWORD=${POSTGRES_PASSWORD}
      - POSTGRES_DB=${POSTGRES_DB}

  redis:
    image: redis:7.0-alpine
    restart: unless-stopped
    networks:
      - saleor-backend-tier
    volumes:
      - ./saleor-redis:/data

  worker:
    image: ghcr.io/saleor/saleor:3.19
    command: celery -A saleor --app=saleor.celeryconf:app worker --loglevel=info
    restart: unless-stopped
    networks:
      - saleor-backend-tier
    depends_on:
      - redis
      - mailpit
      - db
    environment:
      - SECRET_KEY=${SECRET_KEY}
      - DATABASE_URL=${DATABASE_URL}
      - EMAIL_URL=smtp://mailpit:1025
      - CELERY_BROKER_URL=redis://redis:6379/1

  mailpit:
    image: axllent/mailpit
    ports:
      - 1025:1025
      - 8025:8025
    restart: unless-stopped
    networks:
      - saleor-backend-tier

networks:
  saleor-backend-tier:
    driver: bridge

.env

POSTGRES_USER=saleor
POSTGRES_PASSWORD=saleor
POSTGRES_DB=saleor
# Format: postgres://USER:PASSWORD@HOST:PORT/DB_NAME
DATABASE_URL=postgres://saleor:saleor@db:5432/saleor
SECRET_KEY=changeme_super_secret_key_for_saleor_local_dev
Categories:

Share:

Ad
Favicon

 

  
 

Similar to Saleor

Favicon

 

  
  
Favicon

 

  
  
Favicon