Spaces:
Running
Running
Update README.md
Browse files
README.md
CHANGED
@@ -1,11 +1,58 @@
|
|
1 |
---
|
2 |
title: Bing
|
3 |
-
emoji:
|
4 |
-
colorFrom:
|
5 |
-
colorTo:
|
6 |
sdk: docker
|
7 |
pinned: false
|
8 |
license: mit
|
|
|
9 |
---
|
10 |
|
11 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
---
|
2 |
title: Bing
|
3 |
+
emoji: 🐨
|
4 |
+
colorFrom: green
|
5 |
+
colorTo: blue
|
6 |
sdk: docker
|
7 |
pinned: false
|
8 |
license: mit
|
9 |
+
app_port: 5000
|
10 |
---
|
11 |
|
12 |
+
|
13 |
+
# Flask Redirect App
|
14 |
+
|
15 |
+
This simple Flask application redirects any requests to the root URL to https://dongsiqie.me.
|
16 |
+
|
17 |
+
## Pre-requisites
|
18 |
+
|
19 |
+
Make sure you have Docker installed on your system. You can download it from [Docker's official website](https://docker.com).
|
20 |
+
|
21 |
+
## Build Instructions
|
22 |
+
|
23 |
+
To build the Docker image for this application, run the following command:
|
24 |
+
|
25 |
+
```bash
|
26 |
+
docker build -t flask-redirect-app .
|
27 |
+
```
|
28 |
+
|
29 |
+
This will use the `Dockerfile` in the current directory to build an image named `flask-redirect-app`.
|
30 |
+
|
31 |
+
## Running the Application
|
32 |
+
|
33 |
+
Once the image has been built, you can start a container with:
|
34 |
+
|
35 |
+
```bash
|
36 |
+
docker run -dp 5000:5000 flask-redirect-app
|
37 |
+
```
|
38 |
+
|
39 |
+
The application will be accessible at `http://localhost:5000` and will redirect to https://dongsiqie.me.
|
40 |
+
|
41 |
+
## Stopping the Application
|
42 |
+
|
43 |
+
To stop the running container, first list all running containers with:
|
44 |
+
|
45 |
+
```bash
|
46 |
+
docker ps
|
47 |
+
```
|
48 |
+
|
49 |
+
Find the container running the `flask-redirect-app` and note the CONTAINER ID. Then run:
|
50 |
+
|
51 |
+
```bash
|
52 |
+
docker stop CONTAINER_ID
|
53 |
+
```
|
54 |
+
|
55 |
+
Replace `CONTAINER_ID` with the actual ID of your container.
|
56 |
+
|
57 |
+
|
58 |
+
|