Skip to content

Commit d9146ae

Browse files
@ShipDandy created this awesome Python sample app!
0 parents  commit d9146ae

File tree

10 files changed

+676
-0
lines changed

10 files changed

+676
-0
lines changed

.gitignore

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
__pycache__/
2+
shippie/
3+
.DS_Store

Dockerfile

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
FROM python:3.7.0-alpine
2+
3+
# Copy all the code to the `app` directory
4+
WORKDIR /usr/src/app
5+
COPY . .
6+
7+
# Install dependencies
8+
RUN pip install -r requirements.txt
9+
10+
# Run the app
11+
ENTRYPOINT ["python", "app.py"]

README.md

Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
ShipEngine Python Sample App
2+
====================================
3+
4+
This is a ShipEnine sample app, written in Python 3. It demonstrates how easy it is to use various parts of the ShipEngine API in Python.
5+
6+
7+
Installation & Usage
8+
-------------------------------------
9+
You can run the sample app directly on your system if you have [Python 3](https://www.python.org/) and [pip](https://pip.pypa.io/en/stable/installing/) installed. Or, if you have [Docker](https://www.docker.com/products/docker-desktop) installed, then you can run the app as a Docker container.
10+
11+
12+
### Local installation
13+
You can run the app on your local system if you have [Python 3](https://www.python.org/) and [pip](https://pip.pypa.io/en/stable/installing/) installed.
14+
15+
16+
**1. Install dependencies**
17+
```
18+
pip install -r requirements.txt
19+
```
20+
21+
22+
**2. Run the app**
23+
```
24+
python app.py
25+
```
26+
27+
28+
### Docker
29+
If you have [Docker](https://www.docker.com/products/docker-desktop) installed, then you can run the app as a Docker container.
30+
31+
**1. Build the image**
32+
```
33+
docker build --tag se_python_sample_app .
34+
```
35+
36+
> **Note:* Don't forget the period (`.`) at the end of this command
37+
38+
39+
**2. Run the container**
40+
```
41+
docker run -it se_python_sample_app
42+
```

0 commit comments

Comments
 (0)