Initial add from Dockers repo
This commit is contained in:
22
Makefile
Normal file
22
Makefile
Normal file
@@ -0,0 +1,22 @@
|
||||
docker_tag = panubo/vsftpd
|
||||
|
||||
UNAME_S := $(shell uname -s)
|
||||
ifeq ($(UNAME_S),Linux)
|
||||
APP_HOST := localhost
|
||||
endif
|
||||
ifeq ($(UNAME_S),Darwin)
|
||||
APP_HOST := $(shell docker-machine ip default)
|
||||
endif
|
||||
|
||||
build:
|
||||
docker build -t $(docker_tag) .
|
||||
|
||||
bash:
|
||||
docker run --rm -it $(docker_tag) bash
|
||||
|
||||
run:
|
||||
$(eval ID := $(shell docker run -d ${docker_tag}))
|
||||
$(eval IP := $(shell docker inspect --format '{{ .NetworkSettings.IPAddress }}' ${ID}))
|
||||
@echo "Running ${ID} @ ftp://${IP}"
|
||||
@docker attach ${ID}
|
||||
@docker kill ${ID}
|
||||
Reference in New Issue
Block a user