Skip to content

Commit

Permalink
Reset back to when it worked
Browse files Browse the repository at this point in the history
  • Loading branch information
amityweb committed May 1, 2024
2 parents 7777301 + fa9ea3a commit 25ecbc9
Show file tree
Hide file tree
Showing 3,396 changed files with 394,650 additions and 112,236 deletions.
The diff you're trying to view is too large. We only load the first 3000 changed files.
28 changes: 28 additions & 0 deletions .devcontainer/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
FROM mcr.microsoft.com/devcontainers/python:3.9

ENV PYTHONUNBUFFERED 1

RUN apt-get update \
&& apt-get install -y \
libcairo2 \
libgdk-pixbuf2.0-0 \
liblcms2-2 \
libopenjp2-7 \
libpango-1.0-0 \
libpangocairo-1.0-0 \
libssl3 \
libtiff6 \
libwebp7 \
libxml2 \
libpq5 \
shared-mime-info \
mime-support

RUN echo 'image/webp webp' >> /etc/mime.types
RUN echo 'image/avif avif' >> /etc/mime.types

WORKDIR /app
RUN pip install poetry==1.7.0
RUN poetry config virtualenvs.create false
COPY poetry.lock pyproject.toml /app/
RUN poetry install --no-root
7 changes: 7 additions & 0 deletions .devcontainer/backend.env
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
DATABASE_URL=postgres://saleor:saleor@db/saleor
DASHBOARD_URL=http://localhost:9000/
DEFAULT_FROM_EMAIL=[email protected]
CELERY_BROKER_URL=redis://redis:6379/1
SECRET_KEY=changeme
# Mailpit
EMAIL_URL=smtp://mailpit:1025
4 changes: 4 additions & 0 deletions .devcontainer/common.env
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
DEFAULT_CHANNEL_SLUG=default-channel
# Note: recommended value is False for production usage,
# refer to documentation for more details.
HTTP_IP_FILTER_ALLOW_LOOPBACK_IPS=True
35 changes: 35 additions & 0 deletions .devcontainer/devcontainer.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
{
"name": "Saleor",
"dockerComposeFile": "docker-compose.yml",
"service": "saleor",
"workspaceFolder": "/app",
"forwardPorts": [
8000,
"dashboard:9000",
"mailpit:8025"
],
"portsAttributes": {
"8000": {
"label": "Saleor Core"
},
"dashboard:9000": {
"label": "Saleor Dashboard"
},
"mailpit:8025": {
"label": "Mailpit UI"
}
},
"postCreateCommand": "python manage.py migrate",
"customizations": {
"vscode": {
"extensions": [
"Cameron.vscode-pytest",
"charliermarsh.ruff",
"editorconfig.editorconfig",
"ms-python.python",
"ms-python.vscode-pylance",
"streetsidesoftware.code-spell-checker"
]
}
}
}
51 changes: 51 additions & 0 deletions .devcontainer/docker-compose.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
version: "3.4"

services:
saleor:
image: saleor
build:
context: ..
dockerfile: .devcontainer/Dockerfile
command: sleep infinity
env_file:
- common.env
- backend.env
depends_on:
- db
- redis
volumes:
- ..:/app

dashboard:
image: ghcr.io/saleor/saleor-dashboard:3.15.2
restart: unless-stopped
ports:
- 9000:80

db:
image: library/postgres:13-alpine
restart: unless-stopped
volumes:
- saleor-db:/var/lib/postgresql/data
environment:
- POSTGRES_USER=saleor
- POSTGRES_PASSWORD=saleor

redis:
image: library/redis:7.0-alpine
restart: unless-stopped
volumes:
- saleor-redis:/data

mailpit:
image: axllent/mailpit
ports:
- "1025" # SMTP Server
- "8025" # Mailpit UI
restart: unless-stopped

volumes:
saleor-db:
driver: local
saleor-redis:
driver: local
20 changes: 1 addition & 19 deletions .editorconfig
Original file line number Diff line number Diff line change
Expand Up @@ -8,27 +8,9 @@ insert_final_newline = true
trim_trailing_whitespace = true

[*.py]
profile = black
indent_size = 4
continuation_indent_size = 8
combine_as_imports = true
max_line_length = 88
multi_line_output = 4
quote_type = single

[*.js]
indent_size = 2

[*.jsx]
indent_size = 2

[*.scss]
indent_size = 2

[*.ts]
indent_size = 2

[*.tsx]
indent_size = 2

[*.yml]
indent_size = 2
Expand Down
2 changes: 2 additions & 0 deletions .github/CODEOWNERS
Validating CODEOWNERS rules …
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
.github/workflows/* @saleor/sre
/saleor/plugins/openid_connect/ @saleor/cloud-backend
46 changes: 0 additions & 46 deletions .github/CODE_OF_CONDUCT.md

This file was deleted.

82 changes: 82 additions & 0 deletions .github/DISCUSSION_TEMPLATE/RFC.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,82 @@
title: "RFC"
labels: ["RFC"]
body:
- type: textarea
id: problem
attributes:
label: Problem
description: Describe what you are trying to achive. You can include proposed solution.
validations:
required: true
- type: textarea
id: assumptions
attributes:
label: 1. General Assumptions
description: Describe general assumptions for the proposed changes
placeholder: |
1.
2.
3.
...
validations:
required: true
- type: textarea
id: api-changes
attributes:
label: 2. API changes
description: Describe what will change in API.
value: |
### Mutations
```graphql
```
### Types
```graphql
```
validations:
required: false
- type: textarea
id: db-changes
attributes:
label: 3. Database changes
description: Describe new models or changes in existing models.
validations:
required: false
- type: textarea
id: uml-diagrams
attributes:
label: 4. UML diagrams
description: Add UML diagrams that outline the logic behind the changes
placeholder: |
```mermaid
```
validations:
required: false
- type: textarea
id: to-do-list
attributes:
label: 5. To Do list
description: Everything from developer perspective
placeholder: |
```
### Tasks
- [ ] Add a draft title or issue reference here
```
validations:
required: false
- type: textarea
id: to-test
attributes:
label: 6. To Test
description: Put here additional info of what it would be good to check along with new changes.
placeholder: |
e.g.:
- Check feature with tax systems
- Test with overrode prices
validations:
required: false
80 changes: 70 additions & 10 deletions .github/ISSUE_TEMPLATE/feature_request.md
Original file line number Diff line number Diff line change
@@ -1,20 +1,80 @@
---
name: Feature request
about: Suggest an idea for this project
title: ''
title: ""
labels: Feature request
assignees: ''
assignees: ""
---

## Problem

<!-- Describe what you are trying to achive. You can include proposed solution. -->

---

### What I'm trying to achieve
## 1. General Assumptions

<!-- -->

### Acceptance Criteria

<!-- Conditions that a feature must satisfy to be approved by QA
- Functional use case:
- Permissions: As USER/APP with permision `XYZ' I should be able to 'action"
- Webhooks: Webhook `name` event should be sent for every updated `instance name`
- Support for old versions: After updating, it is possible to retrieve data created in older (3.1, 3.5, 3.7) Saleor versions.
- Error handling: Should be handled according to 'policy_name'
- Other use-cases: ID or externalReference can be used to identify object
- Non-functional use case
- X objects can be updated in one mutation
-->

- [ ]
- [ ]

## 2. API changes

### Mutations

```graphql

```

### Types

```graphql

```

## 3. Database changes

<!-- New models or changes in existing models -->

## 4. UML diagrams

<!-- You can render UML diagrams using [Mermaid](https://mermaidjs.github.io/). -->

```mermaid
```

## 5. To Do list

<!-- Everything from developer perspective -->

```[tasklist]
### Tasks
- [ ] Add a draft title or issue reference here
```

### Describe a proposed solution
...
## 6. To Test

### Other solutions I've tried and won't work
<!--
Put here additional info of what it would be good to check along with new changes.
e.g.:
- Check feature with tax systems
- Test with overrode prices
-->

### Screenshots or mockups
<!-- Please provide any illustrations that could help others understand the problem or the proposed solution. -->
- [ ]
- [ ]
Loading

0 comments on commit 25ecbc9

Please sign in to comment.