Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
slapos
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Kirill Smelkov
slapos
Commits
71565a2c
Commit
71565a2c
authored
Oct 26, 2015
by
Kirill Smelkov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
X Nginx instance dirs layout settled
parent
bae28dd8
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
39 additions
and
18 deletions
+39
-18
software/gitlab/instance-gitlab.cfg.in
software/gitlab/instance-gitlab.cfg.in
+32
-15
software/gitlab/instance.cfg.in
software/gitlab/instance.cfg.in
+2
-1
software/gitlab/software.cfg
software/gitlab/software.cfg
+4
-1
software/gitlab/template/nginx.conf.in
software/gitlab/template/nginx.conf.in
+1
-1
No files found.
software/gitlab/instance-gitlab.cfg.in
View file @
71565a2c
...
...
@@ -67,6 +67,7 @@ recipe = slapos.cookbook:publish
url = ${gitlab-backend:url}
# TODO reintegrate postgresql/redis into this instance
#################################
# need: PostgreSQL instance #
#################################
...
...
@@ -95,7 +96,6 @@ software-url = {{ urlparse.urljoin(software_release_url, '../redis-server/softwa
return = redis_ip redis_port
# TODO need: Nginx instance
#############################
...
...
@@ -110,6 +110,7 @@ bin = ${:home}/bin
etc = ${:home}/etc
var = ${:home}/var
log = ${:var}/log
run = ${:var}/run
srv = ${:home}/srv
# slapos startup/service/promies scripts live here:
startup = ${:etc}/run
...
...
@@ -123,6 +124,8 @@ promise = ${:etc}/promise
recipe = slapos.cookbook:mkdirectory
etc = ${directory:etc}/gitlab
log = ${directory:log}/gitlab
# XXX questionable from now on?
var = ${directory:var}/gitlab
tmp = ${:var}/tmp
uploads = ${:var}/uploads
...
...
@@ -140,12 +143,16 @@ etc = ${directory:etc}/gitlab-shell
# 2. configuration files
[
gitlab-
etc-template]
[etc-template]
recipe = slapos.recipe.template:jinja2
extensions = jinja2.ext.do
rendered= ${gitlab:etc}/${:_buildout_section_name_}
mode = 0640
[gitlab-etc-template]
<= etc-template
rendered= ${gitlab:etc}/${:_buildout_section_name_}
[database.yml]
<= gitlab-etc-template
template= {{ database_yml_in }}
...
...
@@ -160,14 +167,12 @@ context =
section gitlab_backend gitlab-backend
section instance_parameter instance-parameter
[resque.yml]
<= gitlab-etc-template
template= {{ resque_yml_in }}
context =
section redis request-redis
[smtp_settings.rb]
<= gitlab-etc-template
template= {{ smtp_settings_rb_in }}
...
...
@@ -180,19 +185,23 @@ template = {{ rack_attack_rb_in }}
context =
section instance_parameter instance-parameter
# XXX move to own directory?
[nginx-etc-template]
<= etc-template
rendered= ${nginx:etc}/${:_buildout_section_name_}
[nginx.conf]
<=
gitlab
-etc-template
<=
nginx
-etc-template
template= {{ nginx_conf_in }}
context =
section instance_parameter instance-parameter
section gitlab_backend gitlab-backend
section directory directory
raw mime_types {{ mime_types }}
# raw nginx_gitlab_http_conf ${nginx-gitlab-http.conf:rendered}
[nginx-gitlab-http.conf]
<=
gitlab
-etc-template
<=
nginx
-etc-template
template= {{ nginx_gitlab_http_conf_in }}
context = ...
...
...
@@ -309,17 +318,25 @@ command =
# sidekiq
# nginx: etc/ log/ ...
[xnginx]
######################
# Nginx frontend #
######################
# srv/nginx/ prefix + etc/ log/ ...
[nginx]
recipe = slapos.cookbook:mkdirectory
srv = ${directory:srv}/nginx
etc = ${directory:etc}/nginx
log = ${directory:log}/nginx
# TODO more?
[nginx-symlinks]
# (nginx wants <prefix>/logs to be there from start - else it issues alarm to the log)
recipe = cns.recipe.symlink
symlink = ${nginx:log} = ${nginx:srv}/logs
# nginx frontend
[service-nginx]
recipe = slapos.cookbook:wrapper
wrapper-path = ${directory:service}/nginx
#command-line = {{ nginx }} -p ...
-c ${nginx.conf:rendered}
command-line = {{ nginx }} -p ${directory:home} -c ${nginx.conf:rendered
}
command-line = {{ nginx_bin }} -p ${nginx:srv}
-c ${nginx.conf:rendered}
depend = ${nginx-symlinks:symlink
}
software/gitlab/instance.cfg.in
View file @
71565a2c
# GitLab "switch-softwaretype" instance
# TODO write why we still use switch-softwaretype, if we only have 1 -gitlab softwaretype
[buildout]
parts = switch-softwaretype
...
...
@@ -31,7 +32,7 @@ context =
raw gitlab_repository_location ${gitlab-repository:location}
raw bundler_4gitlab ${bundler-4gitlab:bundle}
raw git ${git:location}/bin/git
raw nginx
${nginx-output:nginx}
raw nginx
_bin
${nginx-output:nginx}
raw mime_types ${nginx-output:mime}
raw gitlab_parameters_cfg ${gitlab-parameters.cfg:target}
...
...
software/gitlab/software.cfg
View file @
71565a2c
...
...
@@ -157,7 +157,9 @@ make-targets= cd ${:path} &&
# eggs for instance.cfg
[eggs]
recipe = zc.recipe.egg
eggs = plone.recipe.command
eggs =
plone.recipe.command
cns.recipe.symlink
[instance.cfg]
...
...
@@ -228,3 +230,4 @@ url = ${:_profile_base_location_}/template/${:_buildout_section_name_}
rubygemsrecipe = 0.2.2
plone.recipe.command = 1.1
slapos.recipe.template = 2.8
cns.recipe.symlink = 0.2.3
software/gitlab/template/nginx.conf.in
View file @
71565a2c
...
...
@@ -13,7 +13,7 @@
worker_processes {{ cfg('nginx_worker_processes') }};
error_log stderr;
pid nginx.pid;
pid
{{ directory.run }}/
nginx.pid;
daemon off;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment