add: docker
This commit is contained in:
		
							
								
								
									
										14
									
								
								Dockerfile
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										14
									
								
								Dockerfile
									
									
									
									
									
										Normal file
									
								
							@ -0,0 +1,14 @@
 | 
			
		||||
FROM python:alpine
 | 
			
		||||
 | 
			
		||||
WORKDIR /app
 | 
			
		||||
 | 
			
		||||
RUN apk update && apk upgrade
 | 
			
		||||
RUN apk add python3 py3-pip
 | 
			
		||||
RUN python3 -m pip config set global.require-virtualenv False
 | 
			
		||||
 | 
			
		||||
COPY requirements.txt .
 | 
			
		||||
RUN pip install -r requirements.txt
 | 
			
		||||
 | 
			
		||||
COPY . .
 | 
			
		||||
 | 
			
		||||
ENTRYPOINT ["python3", "main.py"]
 | 
			
		||||
							
								
								
									
										16
									
								
								docker-compose.yml
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										16
									
								
								docker-compose.yml
									
									
									
									
									
										Normal file
									
								
							@ -0,0 +1,16 @@
 | 
			
		||||
version: '3.8'
 | 
			
		||||
 | 
			
		||||
name: ca42
 | 
			
		||||
 | 
			
		||||
services:
 | 
			
		||||
  flask:
 | 
			
		||||
    build: .
 | 
			
		||||
    image: ca42
 | 
			
		||||
    container_name: flask
 | 
			
		||||
    restart: always
 | 
			
		||||
    volumes:
 | 
			
		||||
      - type: bind
 | 
			
		||||
        source: .
 | 
			
		||||
        target: /app
 | 
			
		||||
    ports:
 | 
			
		||||
      - 5000:5000
 | 
			
		||||
		Reference in New Issue
	
	Block a user