Skip to content

Commit b349f32

Browse files
ismael_serranoisserrano
authored andcommitted
Add support for Ubuntu 18.04 (Bionic)
1 parent 7a4106e commit b349f32

File tree

5 files changed

+27
-3
lines changed

5 files changed

+27
-3
lines changed

Makefile

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ GO_DOCKER_RUN = docker run --rm -v $(shell pwd):/go/src/github.com/nginxinc/ngin
22
GOLANG_CONTAINER = golang:1.10
33
BUILD_IN_CONTAINER = 1
44

5-
all: amazon centos7 ubuntu-trusty ubuntu-xenial amazon2
5+
all: amazon centos7 ubuntu-trusty ubuntu-xenial amazon2 ubuntu-bionic
66

77
test:
88
ifeq ($(BUILD_IN_CONTAINER),1)
@@ -38,6 +38,10 @@ ubuntu-trusty: compile
3838
make -C build/package/builders/ubuntu-trusty/
3939
docker run --rm -v $(shell pwd)/build/package/debian:/debian -v $(shell pwd)/build_output:/build_output ubuntu-trusty-builder
4040

41+
ubuntu-bionic: compile
42+
make -C build/package/builders/ubuntu-bionic/
43+
docker run --rm -v $(shell pwd)/build/package/debian:/debian -v $(shell pwd)/build_output:/build_output ubuntu-bionic-builder
44+
4145
clean:
4246
-rm -r build_output
4347

README.md

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ Below you will find documentation on how to use nginx-asg-sync.
3636

3737
We provide packages for the following operating systems:
3838

39-
* Ubuntu: 14.04 (Trusty), 16.04 (Xenial)
39+
* Ubuntu: 14.04 (Trusty), 16.04 (Xenial), 18.04 (Bionic)
4040
* CentOS/RHEL: 7
4141
* Amazon Linux: 1, 2
4242

@@ -148,7 +148,7 @@ nginx-asg-sync runs as a system service and supports the start/stop/restart comm
148148

149149
For Ubuntu 14.04 and Amazon Linux 1, run: `$ sudo start|stop|restart nginx-asg-sync`
150150

151-
For Ubuntu 16.04, CentOS7/RHEL7 and Amazon Linux 2, run: `$ sudo service nginx-asg-sync start|stop|restart`
151+
For Ubuntu 16.04 and 18.04, CentOS7/RHEL7 and Amazon Linux 2, run: `$ sudo service nginx-asg-sync start|stop|restart`
152152

153153
## Troubleshooting
154154

@@ -167,6 +167,7 @@ where `<os>` is the target OS. The following values are allowed:
167167
* `centos7` for CentOS7/RHEL7
168168
* `ubuntu-trusty` for Ubuntu 14.04
169169
* `ubuntu-xenial` for Ubuntu 16.04
170+
* `ubuntu-bionic` for Ubuntu 18.04
170171

171172
If you run make without any arguments, it will build software packages for all supported OSes.
172173

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
FROM ubuntu:bionic
2+
3+
RUN apt-get update && apt-get install debhelper dh-systemd -y
4+
ADD build.sh /
5+
6+
ENTRYPOINT ["/build.sh"]
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
build:
2+
docker build -t ubuntu-bionic-builder .
Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
#!/bin/bash
2+
3+
export SYSTEMD='--with=systemd'
4+
mkdir -p ~/nginx-asg-sync-0.2/
5+
cp -r /debian ~/nginx-asg-sync-0.2/
6+
cd ~/nginx-asg-sync-0.2/
7+
sed -i 's/%%CODENAME%%/bionic/g' debian/changelog
8+
rm debian/nginx-asg-sync.upstart
9+
dpkg-buildpackage -us -uc
10+
cd ..
11+
mv *.deb /build_output/

0 commit comments

Comments
 (0)