From c1f26ddb683682a1ddf73f7dd6ca45477dd8a0dd Mon Sep 17 00:00:00 2001 From: JLKwong Date: Fri, 2 Apr 2021 18:43:52 -0700 Subject: [PATCH 1/6] create services gitlab (fixes #2139) --- services/install-gitlab.sh | 7 +++++++ 1 file changed, 7 insertions(+) create mode 100644 services/install-gitlab.sh diff --git a/services/install-gitlab.sh b/services/install-gitlab.sh new file mode 100644 index 0000000000..aa37fab972 --- /dev/null +++ b/services/install-gitlab.sh @@ -0,0 +1,7 @@ +#!/bin/bash + +run_gitlab + +function run_gitlab { + docker run -d --hostname 192.168.86.47 -p 443:443 -p 80:80 -p 2222:22 --name gitlab -v /srv/gitlab/config:/etc/gitlab -v /srv/gitlab/logs:/var/log/gitlab -v /srv/gitlab/data:/var/opt/gitlab --privileged ulm0/gitlab +} From b8b6536d57ee6801131b4cef7f557ac4e7f0c61e Mon Sep 17 00:00:00 2001 From: JLKwong Date: Sat, 3 Apr 2021 20:07:56 -0700 Subject: [PATCH 2/6] add services gitlab (fixes #2139) --- services/install-gitlab.sh | 89 ++++++++++++++++++++++++++++++++++++-- 1 file changed, 86 insertions(+), 3 deletions(-) diff --git a/services/install-gitlab.sh b/services/install-gitlab.sh index aa37fab972..51965273bf 100644 --- a/services/install-gitlab.sh +++ b/services/install-gitlab.sh @@ -1,7 +1,90 @@ #!/bin/bash -run_gitlab - -function run_gitlab { + # runs gitlab on docker docker run -d --hostname 192.168.86.47 -p 443:443 -p 80:80 -p 2222:22 --name gitlab -v /srv/gitlab/config:/etc/gitlab -v /srv/gitlab/logs:/var/log/gitlab -v /srv/gitlab/data:/var/opt/gitlab --privileged ulm0/gitlab + +function install { + # create service directory + mkdir -p /srv/gitlab + + # create yml(s) + {version: '3.3' +services: + gitlab: + ports: + - '443:443' + - '80:80' + - '2222:22' + volumes: + - '/srv/gitlab/config:/etc/gitlab' + - '/srv/gitlab/logs:/var/log/gitlab' + - '/srv/gitlab/data:/var/opt/gitlab' + privileged: true + image: ulm0/gitlab +} > /srv/gitlab/gitlab.yml + + # create .env with default values + + # add autorun +# cat << EOF > /srv/gitlab/autorun +#gitlab_autorun=true + +#if [ "$gitlab_autorun" = true ]; then +# treehouses services gitlab up +#fi +#EOF +} + +# environment var +function uses_env { + echo false +} + +# add supported arch(es) +#function supported_arches { +# echo "armv7l" +# echo "aarch64" +} + +# add port(s) +#function get_ports { +# echo "8082" +#} + +# add size (in MB) +#function get_size { +# echo "350" +#} + +# add description +#function get_description { +# echo "GitLab is a web-based DevOps lifecycle tool that provides a Git-repository manager providing wiki, issue-tracking and continuous integration and deployment pipeline features, using an open-source license" +} + +# add info +function get_info { + echo "https://github.com/treehouses/moodole" + echo + echo "\"Moodle is a learning platform designed to" + echo "provide educators, administrators and learners with a single robust," + echo "secure and integrated system to create personalised learning" + echo "environments.\"" +} + +# add svg icon +function get_icon { + cat < + + + + + + + + + + + +EOF } From d82e1c5a25e0765e8204a1ef6203f96e2c6b7f7f Mon Sep 17 00:00:00 2001 From: JLKwong Date: Mon, 5 Apr 2021 10:55:41 -0700 Subject: [PATCH 3/6] first testable gitlab services (fixes #2139) --- services/install-gitlab.sh | 56 ++++++++++++++++++++++---------------- 1 file changed, 33 insertions(+), 23 deletions(-) diff --git a/services/install-gitlab.sh b/services/install-gitlab.sh index 51965273bf..53574db1f5 100644 --- a/services/install-gitlab.sh +++ b/services/install-gitlab.sh @@ -1,7 +1,7 @@ #!/bin/bash # runs gitlab on docker - docker run -d --hostname 192.168.86.47 -p 443:443 -p 80:80 -p 2222:22 --name gitlab -v /srv/gitlab/config:/etc/gitlab -v /srv/gitlab/logs:/var/log/gitlab -v /srv/gitlab/data:/var/opt/gitlab --privileged ulm0/gitlab +# docker run -d --hostname 192.168.86.47 -p 443:443 -p 80:80 -p 2222:22 --name gitlab -v /srv/gitlab/config:/etc/gitlab -v /srv/gitlab/logs:/var/log/gitlab -v /srv/gitlab/data:/var/opt/gitlab --privileged ulm0/gitlab function install { # create service directory @@ -26,52 +26,62 @@ services: # create .env with default values # add autorun -# cat << EOF > /srv/gitlab/autorun -#gitlab_autorun=true + cat << EOF > /srv/gitlab/autorun +gitlab_autorun=true -#if [ "$gitlab_autorun" = true ]; then -# treehouses services gitlab up -#fi -#EOF +if [ "$gitlab_autorun" = true ]; then + treehouses services gitlab up +fi + + +EOF } # environment var + # NEEDS REVIEW FOR ACCURACY function uses_env { echo false } # add supported arch(es) -#function supported_arches { -# echo "armv7l" -# echo "aarch64" + # NEEDS TO BE CHANGED TO GITLAB +function supported_arches { + echo "armv7l" + echo "aarch64" } # add port(s) -#function get_ports { -# echo "8082" -#} + # NEEDS REVIEW FOR ACCURACY +function get_ports { + echo "443" + echo "80" + echo "2222" +} # add size (in MB) -#function get_size { -# echo "350" -#} + # NEEDS REVIEW FOR ACCURACY +function get_size { + echo "1982" +} # add description -#function get_description { -# echo "GitLab is a web-based DevOps lifecycle tool that provides a Git-repository manager providing wiki, issue-tracking and continuous integration and deployment pipeline features, using an open-source license" +function get_description { + echo "GitLab is a web-based DevOps lifecycle tool that provides a Git-repository manager providing wiki, issue-tracking, continuous integration, and deployment pipeline features; all using an open-source license" } # add info + # NEEDS REVIEW FOR FORMATTING function get_info { - echo "https://github.com/treehouses/moodole" + echo "https://github.com/treehouses/gitlab" echo - echo "\"Moodle is a learning platform designed to" - echo "provide educators, administrators and learners with a single robust," - echo "secure and integrated system to create personalised learning" - echo "environments.\"" + echo "\"GitLab is an open core company which" + echo "develops software for the software development lifecycle used by" + echo "more than 100,000 organizations, 30 million estimated registered users," + echo "and has an active community of more than 3000 contributors.\"" } # add svg icon + # NEEDS TO BE CHANGED TO GITLAB function get_icon { cat < From ffeb4d3575af037edbc7092ddef945aa6009adde Mon Sep 17 00:00:00 2001 From: JLKwong Date: Mon, 5 Apr 2021 11:04:38 -0700 Subject: [PATCH 4/6] first testable gitlab services (fixes #2139) --- services/install-gitlab.sh | 28 +++++++++++++++------------- 1 file changed, 15 insertions(+), 13 deletions(-) diff --git a/services/install-gitlab.sh b/services/install-gitlab.sh index 53574db1f5..fc9a63a3fc 100644 --- a/services/install-gitlab.sh +++ b/services/install-gitlab.sh @@ -8,19 +8,21 @@ function install { mkdir -p /srv/gitlab # create yml(s) - {version: '3.3' -services: - gitlab: - ports: - - '443:443' - - '80:80' - - '2222:22' - volumes: - - '/srv/gitlab/config:/etc/gitlab' - - '/srv/gitlab/logs:/var/log/gitlab' - - '/srv/gitlab/data:/var/opt/gitlab' - privileged: true - image: ulm0/gitlab + # NEEDS REVIEW FOR FORMATTING + { + echo "version: '3.3'" + echo "services:" + echo " gitlab:" + echo " ports:" + echo " - '443:443'" + echo " - '80:80'" + echo " - '2222:22'" + echo " volumes:" + echo " - '/srv/gitlab/config:/etc/gitlab'" + echo " - '/srv/gitlab/logs:/var/log/gitlab'" + echo " - '/srv/gitlab/data:/var/opt/gitlab'" + echo " privileged: true" + echo " image: ulm0/gitlab" } > /srv/gitlab/gitlab.yml # create .env with default values From 081eb759edc91defa401daedf09e7546755f86ef Mon Sep 17 00:00:00 2001 From: JLKwong Date: Mon, 5 Apr 2021 12:52:50 -0700 Subject: [PATCH 5/6] first testable services gitlab (fixes #2139) --- services/install-gitlab.sh | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/services/install-gitlab.sh b/services/install-gitlab.sh index fc9a63a3fc..9d5d7b4537 100644 --- a/services/install-gitlab.sh +++ b/services/install-gitlab.sh @@ -49,7 +49,6 @@ function uses_env { # NEEDS TO BE CHANGED TO GITLAB function supported_arches { echo "armv7l" - echo "aarch64" } # add port(s) @@ -87,7 +86,15 @@ function get_info { function get_icon { cat < - + From 78fe053848735d62853f31316cef66f4000e9203 Mon Sep 17 00:00:00 2001 From: JLKwong Date: Wed, 7 Apr 2021 16:19:58 -0700 Subject: [PATCH 6/6] update svg (fixes #2139) --- services/install-gitlab.sh | 27 ++++++++++----------------- 1 file changed, 10 insertions(+), 17 deletions(-) diff --git a/services/install-gitlab.sh b/services/install-gitlab.sh index 9d5d7b4537..01aa1a52fc 100644 --- a/services/install-gitlab.sh +++ b/services/install-gitlab.sh @@ -86,23 +86,16 @@ function get_info { function get_icon { cat < - - - - - - - - - + + + + + + + + + + EOF