github.com/tmlbl/deis@v1.0.2/Makefile (about)

     1  #
     2  # Deis Makefile
     3  #
     4  
     5  include includes.mk
     6  
     7  COMPONENTS=builder cache controller database logger logspout publisher registry router store
     8  START_ORDER=publisher store logger logspout database cache registry controller builder router
     9  CLIENTS=client deisctl
    10  
    11  all: build run
    12  
    13  dev-registry: check-docker
    14  	@docker inspect registry >/dev/null && docker start registry || docker run -d -p 5000:5000 --name registry registry:0.8.1
    15  	@echo
    16  	@echo "To use local boot2docker registry for Deis development:"
    17  	@echo "    export DEV_REGISTRY=`boot2docker ip 2>/dev/null`:5000"
    18  
    19  discovery-url:
    20  	sed -e "s,# discovery:,discovery:," -e "s,discovery: https://discovery.etcd.io/.*,discovery: $$(curl -s -w '\n' https://discovery.etcd.io/new)," contrib/coreos/user-data.example > contrib/coreos/user-data
    21  
    22  build: check-docker
    23  	@$(foreach C, $(COMPONENTS), $(MAKE) -C $(C) build &&) echo done
    24  	@$(foreach C, $(CLIENTS), $(MAKE) -C $(C) build &&) echo done
    25  
    26  clean:
    27  	@$(foreach C, $(COMPONENTS), $(MAKE) -C $(C) clean &&) echo done
    28  	@$(foreach C, $(CLIENTS), $(MAKE) -C $(C) clean &&) echo done
    29  
    30  full-clean:
    31  	@$(foreach C, $(COMPONENTS), $(MAKE) -C $(C) full-clean &&) echo done
    32  
    33  install:
    34  	@$(foreach C, $(START_ORDER), $(MAKE) -C $(C) install &&) echo done
    35  
    36  uninstall:
    37  	@$(foreach C, $(COMPONENTS), $(MAKE) -C $(C) uninstall &&) echo done
    38  
    39  start:
    40  	@$(foreach C, $(START_ORDER), $(MAKE) -C $(C) start &&) echo done
    41  
    42  stop:
    43  	@$(foreach C, $(COMPONENTS), $(MAKE) -C $(C) stop &&) echo done
    44  
    45  restart: stop start
    46  
    47  run: install start
    48  
    49  dev-release:
    50  	@$(foreach C, $(COMPONENTS), $(MAKE) -C $(C) dev-release &&) echo done
    51  
    52  push:
    53  	@$(foreach C, $(COMPONENTS), $(MAKE) -C $(C) push &&) echo done
    54  
    55  set-image:
    56  	@$(foreach C, $(COMPONENTS), $(MAKE) -C $(C) set-image &&) echo done
    57  
    58  release: check-registry
    59  	@$(foreach C, $(COMPONENTS), $(MAKE) -C $(C) release &&) echo done
    60  	@$(foreach C, $(CLIENTS), $(MAKE) -C $(C) release &&) echo done
    61  
    62  deploy: build dev-release restart
    63  
    64  test: test-components push test-integration
    65  
    66  test-components:
    67  	@$(foreach C, $(COMPONENTS), $(MAKE) -C $(C) test &&) echo done
    68  
    69  test-integration:
    70  	$(MAKE) -C tests/ test-full
    71  
    72  test-smoke:
    73  	$(MAKE) -C tests/ test-smoke