liuyuqi-dellpc 5 years ago
commit
7c6f59e240
6 changed files with 60 additions and 0 deletions
  1. 24 0
      .dockerignore
  2. 16 0
      Dockerfile
  3. 10 0
      docker-compose.debug.yml
  4. 8 0
      docker-compose.yml
  5. 1 0
      requirements.txt
  6. 1 0
      run.sh

+ 24 - 0
.dockerignore

@@ -0,0 +1,24 @@
+**/.classpath
+**/.dockerignore
+**/.env
+**/.git
+**/.gitignore
+**/.project
+**/.settings
+**/.toolstarget
+**/.vs
+**/.vscode
+**/*.*proj.user
+**/*.dbmdl
+**/*.jfm
+**/azds.yaml
+**/bin
+**/charts
+**/docker-compose*
+**/Dockerfile*
+**/node_modules
+**/npm-debug.log
+**/obj
+**/secrets.dev.yaml
+**/values.dev.yaml
+README.md

+ 16 - 0
Dockerfile

@@ -0,0 +1,16 @@
+FROM kfwkfulq.mirror.aliyuncs.com/library/python:3.6
+LABEL Name=docker-competition Version=1.0.1
+RUN mkdir -p ~/.pip
+RUN echo '\n\
+    [global] \n\
+    trusted-host=mirrors.aliyun.com \n\
+    index-url=https://mirrors.aliyun.com/pypi/simple/ \
+    ' > ~/.pip/pip.conf
+
+WORKDIR /
+ADD requirements.txt /
+RUN python3 -m pip install -r requirements.txt
+
+ADD . /
+
+CMD ["glances"]

+ 10 - 0
docker-compose.debug.yml

@@ -0,0 +1,10 @@
+version: '2.1'
+
+services:
+  docker-glances:
+    image: docker-glances
+    build:
+      context: .
+      dockerfile: Dockerfile
+    ports:
+      - 3000:3000

+ 8 - 0
docker-compose.yml

@@ -0,0 +1,8 @@
+version: '2.1'
+
+services:
+  docker-glances:
+    image: docker-glances
+    build: .
+    ports:
+      - 3000:3000

+ 1 - 0
requirements.txt

@@ -0,0 +1 @@
+glances

+ 1 - 0
run.sh

@@ -0,0 +1 @@
+#!/bin/sh