From 351476d1c02e3ba73597abfb799d6056702d6050 Mon Sep 17 00:00:00 2001 From: s3lva-kumar <98340923+s3lva-kumar@users.noreply.github.com> Date: Mon, 11 Apr 2022 16:39:40 +0530 Subject: [PATCH 1/4] Add ansible role to deploy Uguu --- .gitmodules | 3 +++ ansible/ansible-role-uguu | 1 + ansible/site.yml | 28 ++++++++++++++++++++++++++++ 3 files changed, 32 insertions(+) create mode 160000 ansible/ansible-role-uguu create mode 100644 ansible/site.yml diff --git a/.gitmodules b/.gitmodules index e69de29..18af08d 100644 --- a/.gitmodules +++ b/.gitmodules @@ -0,0 +1,3 @@ +[submodule "ansible/ansible-role-uguu"] + path = ansible/ansible-role-uguu + url = https://github.com/s3lva-kumar/ansible-role-uguu diff --git a/ansible/ansible-role-uguu b/ansible/ansible-role-uguu new file mode 160000 index 0000000..dcde9ac --- /dev/null +++ b/ansible/ansible-role-uguu @@ -0,0 +1 @@ +Subproject commit dcde9ac909f7f4ea249b52351c1c49443eac3ae3 diff --git a/ansible/site.yml b/ansible/site.yml new file mode 100644 index 0000000..0161869 --- /dev/null +++ b/ansible/site.yml @@ -0,0 +1,28 @@ +- name: "install uguu" + hosts: all + become: yes + role: + - ansible-role-uguu + + vars: + generateRobotstxt: "" + generateSitemap: "" + max_upload_size: "" + production: "" + siteName: "" + siteUrl: "" + abuseContact: "" + infoContact: "" + ServerCountryLocation: "" + SiteMetaInfo: "" + paypalUrl: "" + bitcoinAddress: "" + flattrUrl: "" + LOG_IP: "" + DB_USER: "" + DB_PASS: "" + ANTI_DUPE: "" + FILES_RETRIES: "" + SSL: "" + NAME_LENGTH: "" + URL: "" \ No newline at end of file From fa3a6fd74d64b33b9ef2075c7e81e480fa1f488d Mon Sep 17 00:00:00 2001 From: s3lva-kumar <98340923+s3lva-kumar@users.noreply.github.com> Date: Tue, 12 Apr 2022 13:16:09 +0530 Subject: [PATCH 2/4] Add make target to exec ansible role --- Makefile | 7 +++++++ ansible/site.yml | 22 ++-------------------- 2 files changed, 9 insertions(+), 20 deletions(-) diff --git a/Makefile b/Makefile index 391362c..a20f8b5 100644 --- a/Makefile +++ b/Makefile @@ -7,6 +7,7 @@ NPM="npm" DESTDIR="./dist" PKG_VERSION := $( $(GREP) -Po '(?<="version": ")[^"]*' ) TMPDIR := $(shell mktemp -d) +HOSTS_FILE = $(HOSTS_FILE) # default modules MODULES="php" @@ -62,6 +63,12 @@ endif install: installdirs cp -rv $(CURDIR)/build/* $(DESTDIR)/ +submodule-update: + git submodule update + +deploy: + ansible-playbook -i $(HOSTS_FILE) ansible/site.yml + dist: DESTDIR=$(TMPDIR)/uguu-$(PKGVERSION) export DESTDIR diff --git a/ansible/site.yml b/ansible/site.yml index 0161869..9738112 100644 --- a/ansible/site.yml +++ b/ansible/site.yml @@ -1,28 +1,10 @@ - name: "install uguu" hosts: all become: yes - role: + roles: - ansible-role-uguu vars: - generateRobotstxt: "" - generateSitemap: "" - max_upload_size: "" - production: "" - siteName: "" - siteUrl: "" - abuseContact: "" - infoContact: "" - ServerCountryLocation: "" - SiteMetaInfo: "" paypalUrl: "" bitcoinAddress: "" - flattrUrl: "" - LOG_IP: "" - DB_USER: "" - DB_PASS: "" - ANTI_DUPE: "" - FILES_RETRIES: "" - SSL: "" - NAME_LENGTH: "" - URL: "" \ No newline at end of file + flattrUrl: "" \ No newline at end of file From 61f8e307e62a6ab57a0c9ad8941f50abf67ecb17 Mon Sep 17 00:00:00 2001 From: s3lva-kumar <98340923+s3lva-kumar@users.noreply.github.com> Date: Thu, 22 Sep 2022 13:50:30 +0530 Subject: [PATCH 3/4] git submodule updated --- ansible/ansible-role-uguu | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ansible/ansible-role-uguu b/ansible/ansible-role-uguu index dcde9ac..b3b9580 160000 --- a/ansible/ansible-role-uguu +++ b/ansible/ansible-role-uguu @@ -1 +1 @@ -Subproject commit dcde9ac909f7f4ea249b52351c1c49443eac3ae3 +Subproject commit b3b95801d3664d8a143126c0ff6551533f48394e From 7691fbebd7f11f2caac54baf69e8f4a65f5f1965 Mon Sep 17 00:00:00 2001 From: Selvakumar <98340923+s3lva-kumar@users.noreply.github.com> Date: Thu, 22 Sep 2022 14:27:03 +0530 Subject: [PATCH 4/4] Update Makefile --- Makefile | 1 + 1 file changed, 1 insertion(+) diff --git a/Makefile b/Makefile index a20f8b5..93e3b2a 100644 --- a/Makefile +++ b/Makefile @@ -64,6 +64,7 @@ install: installdirs cp -rv $(CURDIR)/build/* $(DESTDIR)/ submodule-update: + cd ansible/ansible-role-uguu git submodule update deploy: