Commit f9fb579319bef40eedb20597c552580b403bf7c0
1 parent
f50fab54
Exists in
master
and in
79 other branches
Created gitlab-shell spec file
TODO: Fix .gitlab_secret Signed-off-by: Alexandre Barbosa <alexandreab@live.com> Signed-off-by: Lucas Kanashiro <kanashiro.duarte@gmail.com>
Showing
1 changed file
with
79 additions
and
0 deletions
Show diff stats
... | ... | @@ -0,0 +1,79 @@ |
1 | +Name: gitlab-shell | |
2 | +Version: 2.4.0 | |
3 | +Release: 1%{?dist} | |
4 | +Summary: Software Development Platform | |
5 | + | |
6 | +Group: Development/Tools | |
7 | +License: Expat | |
8 | +URL: https://gitlab.com/gitlab-org/gitlab-shell | |
9 | +Source0: %{name}-%{version}.tar.gz | |
10 | +BuildArch: noarch | |
11 | + | |
12 | +# BuildRequires: | |
13 | +Requires: ruby >= 1.9 | |
14 | + | |
15 | +%description | |
16 | +Gitlab-shell | |
17 | + | |
18 | +%prep | |
19 | +%setup -q | |
20 | + | |
21 | +%build | |
22 | +cat > config.yml <<EOF | |
23 | +user: git | |
24 | +gitlab_url: "http://localhost:8080/" | |
25 | + | |
26 | +http_settings: | |
27 | +# user: someone | |
28 | +# password: somepass | |
29 | +# ca_file: /etc/ssl/cert.pem | |
30 | +# ca_path: /etc/pki/tls/certs | |
31 | + self_signed_cert: false | |
32 | + | |
33 | +repos_path: "/var/lib/gitlab/repositories/" | |
34 | +auth_file: "/var/lib/gitlab-shell/.ssh/authorized_keys" | |
35 | + | |
36 | +redis: | |
37 | + bin: /usr/bin/redis-cli | |
38 | + host: 127.0.0.1 | |
39 | + port: 6379 | |
40 | + # pass: redispass # Allows you to specify the password for Redis | |
41 | + #database: 0 | |
42 | + #socket: /var/run/redis/redis.sock # Comment out this line if you want to use TCP | |
43 | + #namespace: resque:gitlab | |
44 | + | |
45 | +log_file: "/var/log/gitlab-shell/gitlab-shell.log" | |
46 | +log_level: INFO | |
47 | +audit_usernames: false | |
48 | +EOF | |
49 | + | |
50 | +%install | |
51 | +mkdir -p %{buildroot}/usr/lib/gitlab-shell | |
52 | +mkdir -p %{buildroot}/etc/gitlab-shell | |
53 | + | |
54 | +mv config.yml %{buildroot}/etc/gitlab-shell | |
55 | +ln -s /etc/gitlab-shell/config.yml %{buildroot}/usr/lib/gitlab-shell/ | |
56 | + | |
57 | +cp -r . %{buildroot}/usr/lib/gitlab-shell | |
58 | + | |
59 | +%post | |
60 | +groupadd git || true | |
61 | +if ! id git; then | |
62 | + adduser --system --home-dir /usr/lib/gitlab --no-create-home --gid git git | |
63 | +fi | |
64 | + | |
65 | +mkdir -p /var/log/gitlab-shell | |
66 | +mkdir -p /var/lib/gitlab-shell/.ssh | |
67 | + | |
68 | +chown -R git:git /var/log/gitlab-shell | |
69 | +chown -R git:git /var/lib/gitlab-shell | |
70 | + | |
71 | +sudo -u git -H /usr/lib/gitlab-shell/bin/install | |
72 | + | |
73 | +%files | |
74 | +/usr/lib/gitlab-shell | |
75 | +/etc/gitlab-shell | |
76 | + | |
77 | + | |
78 | +%changelog | |
79 | + | ... | ... |