Skip to content

Commit 922adb4

Browse files
committed
Updated readme
1 parent 60bca54 commit 922adb4

File tree

2 files changed

+37
-7
lines changed

2 files changed

+37
-7
lines changed

README.md

Lines changed: 31 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ USAGE
2424

2525
![Screen](https://raw.githubusercontent.com/krom/docker-compose-makefile/master/docs/screencast.gif)
2626

27-
**Common (see [sampess](https://github.com/krom/docker-compose-makefile/tree/master/samples))**
27+
**Common (see [samples](https://github.com/krom/docker-compose-makefile/tree/master/samples))**
2828
- **make start** - start all containers
2929
- **make start c=hello** - start container hello
3030
- **make stop** - stop all containers
@@ -39,11 +39,33 @@ USAGE
3939
SAMPLES
4040
-------
4141

42+
Basic command (you can copy and paste it into your Makefile)
43+
44+
```makefile
45+
up: ## Start all or c=<name> containers in foreground
46+
@$(DOCKER_COMPOSE) -f $(DOCKER_COMPOSE_FILE) up -d $(c)
47+
48+
start: ## Start all or c=<name> containers in background
49+
@$(DOCKER_COMPOSE) -f $(DOCKER_COMPOSE_FILE) up -d $(c)
50+
51+
stop: ## Stop all or c=<name> containers
52+
@$(DOCKER_COMPOSE) -f $(DOCKER_COMPOSE_FILE) stop $(c)
53+
54+
status: ## Show status of containers
55+
@$(DOCKER_COMPOSE) -f $(DOCKER_COMPOSE_FILE) ps
56+
57+
restart: ## Restart all or c=<name> containers
58+
@$(DOCKER_COMPOSE) -f $(DOCKER_COMPOSE_FILE) stop $(c)
59+
@$(DOCKER_COMPOSE) -f $(DOCKER_COMPOSE_FILE) up $(c) -d
60+
61+
clean: ## Clean all data
62+
@$(DOCKER_COMPOSE) -f $(DOCKER_COMPOSE_FILE) down
63+
```
4264
You may see samples [here](https://github.com/krom/docker-compose-makefile/tree/master/samples)
4365

4466
CUSTOMIZATION
4567
-------------
46-
You can create _.make.env_ file in directory with Makefile or *current** directory
68+
You can create _.make.env_ file in directory with Makefile or **current** directory
4769

4870
Available variables
4971

@@ -56,12 +78,17 @@ TO-DO
5678
- check dependencies
5779
- update readme
5880

81+
CHANGELOG
82+
---------
83+
84+
See [CHANGELOG](CHANGELOG.md))
85+
5986
LICENSE
6087
-------
6188

62-
MIT
89+
MIT (see [LICENSE](LICENSE))
6390

6491
AUTHOR
6592
------
6693

67-
Roman Kudlay (roman@kudlay.pro)
94+
[Roman Kudlay](http://roman.kudlay.pro) ([roman@kudlay.pro](maailto:roman@kudlay.pro))

samples/Makefile

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,16 +7,19 @@ include $(ROOT_DIR)/.makefile-lib/common.mk
77

88
dependencies: check-dependencies ## Check dependencies
99

10-
start: ## Start all containers
10+
up: ## Start all or c=<name> containers in foreground
1111
@$(DOCKER_COMPOSE) -f $(DOCKER_COMPOSE_FILE) up -d $(c)
1212

13-
stop: ## Stop all containers
13+
start: ## Start all or c=<name> containers in background
14+
@$(DOCKER_COMPOSE) -f $(DOCKER_COMPOSE_FILE) up -d $(c)
15+
16+
stop: ## Stop all or c=<name> containers
1417
@$(DOCKER_COMPOSE) -f $(DOCKER_COMPOSE_FILE) stop $(c)
1518

1619
status: ## Show status of containers
1720
@$(DOCKER_COMPOSE) -f $(DOCKER_COMPOSE_FILE) ps
1821

19-
restart: ## Restart of containers
22+
restart: ## Restart all or c=<name> containers
2023
@$(DOCKER_COMPOSE) -f $(DOCKER_COMPOSE_FILE) stop $(c)
2124
@$(DOCKER_COMPOSE) -f $(DOCKER_COMPOSE_FILE) up $(c) -d
2225

0 commit comments

Comments
 (0)