salsa.debian.org state of affairs
-
0:06 - 0:09Ok, welcome back to the second session
of the day. -
0:10 - 0:13It's going to be Alexander Wirt talking
about salsa.debian.org. -
0:14 - 0:19[Applause]
-
0:19 - 0:21Thank you, good morning.
-
0:22 - 0:26I usually don't give talks in english,
so please be nice to me. -
0:27 - 0:29However, I'm here.
-
0:30 - 0:33I want to talk today about our journey
from Alioth -
0:34 - 0:36which is still running, but not for long
anymore, -
0:37 - 0:39to our new service, salsa.
-
0:40 - 0:43I want to get a little bit into the history
of old things -
0:43 - 0:47and what we have already achieved,
what we still need to achieve -
0:47 - 0:50and what are our plans for the future.
-
0:54 - 0:57Let's start with the basic things,
who am I. -
0:59 - 1:03I am the guy who rejects the mails
on lists.debian.org, -
1:03 - 1:05I am a listmaster.
-
1:08 - 1:11I am the guy that rejects your backports.
-
1:11 - 1:13I am the backports ftp master.
-
1:15 - 1:18And I am the guy that will destroy
alioth.debian.org. -
1:18 - 1:21For the last ten years
-
1:21 - 1:23[Applause]
-
1:23 - 1:26I was an admin by accident of
alioth.debian.org. -
1:26 - 1:29This is another story I will tell you
in a few minutes. -
1:31 - 1:36Beside from that, I work as an OpenSource
consultant at credativ, -
1:37 - 1:41which is a small company in Germany
which is specialized in OpenSource, -
1:41 - 1:44we only do OpenSource consulting
in Germany. -
1:44 - 1:51We do what today is called DevOps,
we do every kind of consulting. -
1:51 - 1:55If you do something with OpenSource,
we are probably the ones you can talk with. -
1:58 - 2:01I am a father of two wonderful girls,
-
2:01 - 2:03they're not here unfortunately,
-
2:03 - 2:05but otherwise I wouldn't be able
to work. -
2:07 - 2:13And in my little bit spare time, I do
role playing games and Tabletop games. -
2:17 - 2:20In theory there should be a picture now.
-
2:22 - 2:25There's a picture missing,
I don't know why, -
2:26 - 2:27which should tell "We need you".
-
2:28 - 2:32A little bit of advertisement, if you
want to do OpenSource work in Germany, -
2:32 - 2:33paid,
-
2:34 - 2:37and you need a job, please talk to me.
-
2:37 - 2:42We are always looking for good people,
especially in C development, -
2:42 - 2:47kernel development, but also of course
consulting. -
2:48 - 2:50So please talk to me.
-
2:51 - 2:52Some steps in history.
-
2:54 - 2:58Some years ago, ???
2008, 2009, -
2:59 - 3:01I told the #alioth channel
-
3:01 - 3:05"Hey, if you need help, I can help with
system administration, -
3:05 - 3:09not the GForge stuff which is running
above, -
3:09 - 3:11but if you need help, tell me."
-
3:12 - 3:13[Audience] Big mistake
-
3:13 - 3:14Yeah.
-
3:14 - 3:19One or two years went by,
and step by step -
3:19 - 3:22all remaining alioth admins left.
-
3:23 - 3:24We were alone in the channel.
-
3:25 - 3:27And around that time, I detected
-
3:27 - 3:31"Hey, I have sudo permissions
and I'm admin" -
3:32 - 3:34Somebody made me an admin.
-
3:35 - 3:41So, I had to decide that I will be
the person that is the future alioth admin -
3:41 - 3:43and I stepped in.
-
3:44 - 3:47So it was the beginning of our alioth
journey. -
3:49 - 3:53Then, in DebConf15, we had a long
'Birds of a Feather' -
3:54 - 3:58where we talked about several security
problems in collab-maint, -
4:00 - 4:03some of you are maybe not aware of it,
-
4:03 - 4:09but since we use git at filesystem level
on alioth, -
4:09 - 4:13we are introducing a number of interesting
security problems -
4:13 - 4:19like if someone writes a hook, that hook
gets executed every time someone pushes. -
4:20 - 4:22So you have basically shell access.
-
4:23 - 4:25And of course you execute it as
your own uid. -
4:26 - 4:32So, if some DM (Debian Maintainer) or even
not DM, nearly the whole world -
4:32 - 4:34has write access to collab-maint,
-
4:34 - 4:36drops some hooks in,
-
4:38 - 4:43it can make you execute code on Alioth
at your uid, which is a problem. -
4:44 - 4:51We did some things to solve that problem,
but the main problem remained. -
4:52 - 4:57So, along that time, we decided that we
would need a successor for git.debian.org. -
4:58 - 5:03At that point, we are talking about gitolite
-
5:03 - 5:06which we evaluated at that time.
-
5:07 - 5:11However, as it sometimes happens.
-
5:11 - 5:14Two years went into the land and
nothing real happened, -
5:15 - 5:16we just played with it.
-
5:17 - 5:23Then, May 2017, a thread comes up,
"Moving away from fusionforge". -
5:25 - 5:31What nobody was really aware of, is that
alioth is on a Wheezy machine -
5:31 - 5:34and Wheezy is running out of security
support end of the month. -
5:34 - 5:36So time was running up.
-
5:39 - 5:44The thread was long as usual on
debian-devel and -
5:44 - 5:49we decided to do a few steps, like
evaluating things -
5:50 - 5:59and in June 2017, I did a survey about
our new alioth services. -
6:01 - 6:06It was clear at that point that I wouldn't
be able to maintain all the things -
6:06 - 6:08alioth had in the future
-
6:09 - 6:14so we decided to just bring over
the important things. -
6:15 - 6:18What is important? For everyone,
everything else is important -
6:18 - 6:23so I decided to do a survey which was
pretty successful -
6:23 - 6:25with a few hundreds submissions.
-
6:26 - 6:28Then, in…
-
6:44 - 6:50Then we evaluated… "we" as probably "me",
-
6:51 - 6:58evaluated a few solutions, named pagure,
which is the git solution Fedora is using, -
6:58 - 7:02which is a Python thing based on gitolite,
-
7:03 - 7:12gitlab, which is the biggest Github
competitor -
7:15 - 7:21gogs/gitea, which is some golang-based
small git service. -
7:23 - 7:29pagure turned out to be not stable enough
for our needs -
7:29 - 7:37and we would have to do to much coding
inside pagure to use it in our infrastructure -
7:37 - 7:42because pagure is very strongly binded
with the Fedora infrastructure, -
7:42 - 7:47specially its user authentication and
user management stuff. -
7:48 - 7:52Gitlab had an other problem called
"opencore" and -
7:52 - 7:56"contributor license agreement"
which means -
7:56 - 8:01I and others were not very happy with
contributing code to Gitlab -
8:01 - 8:06which is something that will always
happen if you maintain such a service. -
8:08 - 8:12And gogs and gitea is nice but it's small
-
8:12 - 8:18It will not be able to manage 10,000s
of repositories. -
8:23 - 8:28Next step happened in August 2017 when
we had a sprint here in Hamburg -
8:28 - 8:32at the hackerlab CCC on the other side
of the building, -
8:34 - 8:35where we talked about it.
-
8:36 - 8:41After long discussions, we decided to go
with Gitlab -
8:41 - 8:49because Gitlab, at that point, was
the best solution that was already ready. -
8:50 - 8:53We didn't have to adapt too much, we don't
need to patch it -
8:55 - 8:59which turned out it isn't true, but it's
an other problem -
9:01 - 9:06It had features like continuous integration
ready, -
9:06 - 9:12it had features like code review ready,
wiki pretty good working -
9:13 - 9:18and ??? very scalable
in all directions -
9:19 - 9:24Every component is scalable which is
good for us. -
9:30 - 9:35This is a TODO point, I wanted to add
an image about the restaurant -
9:35 - 9:38where we decided on the name "salsa".
-
9:38 - 9:43Somebody of you may ask yourself where
the name is coming from. -
9:43 - 9:46There's a small mexican restaurant
a few hundred meters from here -
9:47 - 9:52where you can get great burritos and
they have a painting at the back -
9:52 - 9:55with the term "salsa" written
-
9:55 - 10:01and we were deciding on a name which
just not describes the type of service on it -
10:01 - 10:03so we wanted…
-
10:05 - 10:12Yes, it's also a sauce. So salsa had sauce.
-
10:13 - 10:19I wanted to call it Klaus, but we decided
against it so somebody came up -
10:19 - 10:24in the restaurant with the name "salsa"
and so it's called salsa. -
10:28 - 10:31In the meanwhile, we talked a lot with
the Gitlab people -
10:31 - 10:35which were very kind and helped us
with our problems. -
10:36 - 10:42We also talked with them about the CLA
problem and after some discussions, -
10:42 - 10:47the lawyer of SPI was also involved,
-
10:47 - 10:51we made them to remove the CLA
and replace it with something better. -
10:53 - 10:58Contributing patches to Gitlab is now
much easier and better -
10:58 - 11:00which is something we are very proud of
-
11:00 - 11:05[Applause]
-
11:07 - 11:13And between November and the 25th of
December, we implemented salsa two times -
11:14 - 11:17First time on godard.debian.net where we had
root but -
11:18 - 11:25after more discussions we decided having
this maintained at a (debian).org box -
11:26 - 11:30would be better, which made us
??? ansible stuff -
11:30 - 11:36and develop a ??? to be able to install
gitlab as a non-privileged user -
11:37 - 11:38but we did that.
-
11:40 - 11:46In Christmas, he was able to release
salsa into public beta. -
11:50 - 11:56Things went well, which allowed, at the
end of January, salsa to leave the beta -
11:56 - 12:01Since then it's official, our official
git successor. -
12:05 - 12:07What will happen in the future?
-
12:08 - 12:09Oh no, this is already past.
-
12:11 - 12:16On May, we disabled user and project
creation on alioth. -
12:22 - 12:28Still in May, we disabled the not so much
used version control systems, -
12:28 - 12:30bazaar, mercurial and darcs
-
12:34 - 12:37On Thursday (May 17th 2018), I disabled
projects web sites. -
12:39 - 12:41And this is future, at the end the month,
-
12:41 - 12:46all other remaining version control systems
on alioth will get disabled. -
12:46 - 12:51So if you have anything running on alioth,
still running on alioth, -
12:51 - 12:55cron jobs are also disabled so
you don't have cron jobs enabled anymore -
12:56 - 13:00Be it whatever you think of, remove it.
-
13:02 - 13:081st of June, alioth will be off, you won't
be able to get any data anymore -
13:08 - 13:10from alioth.
-
13:10 - 13:16You can get the ??? via DSA to get
subsequent backups, that's up to you -
13:16 - 13:19but I don't recommend it and they won't
like it. -
13:24 - 13:25Yeah
-
13:28 - 13:30In June, alioth will come to an end.
-
13:31 - 13:38It served us well for 10, 15 years, but
its time is over. -
13:42 - 13:44Some numbers.
Where are we now? -
13:46 - 13:51Yesterday (May 18th 2018), we had
23,700 repositories on gitlab, -
13:53 - 14:043200 users, 400 groups, which sums up
around 90GB on disk, which is nice. -
14:05 - 14:11For a service running for more or less
6 months, it's a pretty nice number. -
14:17 - 14:19What are our future plans.
-
14:21 - 14:27??? Docker registry, by now
you can use external registries -
14:27 - 14:28which is working
-
14:28 - 14:31You can the gitlab registry for
Docker images -
14:31 - 14:34but it will be nicer to have our own
registry. -
14:35 - 14:39That is pretty high on my todo list, after
alioth is gone. -
14:42 - 14:47We want more runners, so you are able to
sponsor runners, if you have machines or -
14:47 - 14:53some money you want to spend on runners,
please tell us. -
14:53 - 14:59What are runners? Runners are the things
that are used by Gitlab CI to build code -
15:00 - 15:02or test code, or do things.
-
15:04 - 15:10You can use it to build your packages,
you can use it to autopkgtest your packages -
15:10 - 15:15you can use it to build websites or
whatever you like. -
15:16 - 15:22It's pretty useful and I think using CI more
will be a big step forward for Debian. -
15:25 - 15:28We should really get more into it.
-
15:29 - 15:35There are already some projects like
the reproducible builds, the debci guys -
15:35 - 15:37that are working on such stuff
-
15:37 - 15:43and now we have the infrastructure that
every DD, every developer or package maintainer -
15:43 - 15:44can use it.
-
15:49 - 15:50There's also an other feature called
-
15:50 - 15:55"devops" which is based on kubernetes
which allows you to even -
15:55 - 15:59deploy and test things properly.
-
15:59 - 16:03So if you have package which implements
a web service, you can even run -
16:03 - 16:07??? kubernetes part which runs
a web server, -
16:07 - 16:11you can test it, you can even record it,
do QA test and so on -
16:11 - 16:16all based on this devops feature which
would also be a nice thing. -
16:17 - 16:20By now, we don't have a kubernetes instance
we can use for it, -
16:20 - 16:25so if you have a spare kubernetes instance
you want to offer Debian, -
16:25 - 16:26please talk to us.
-
16:29 - 16:35And integration with sso.debian.org,
which is another side project of mine -
16:35 - 16:38and some of ??? students, sitting there.
-
16:40 - 16:44We want to build a successor for
the command sso.debian.org -
16:44 - 16:48which has a problem that it doesn't have
a user backend, -
16:48 - 16:50the user backend is alioth,
you see the problem -
16:53 - 16:55But it just the case for our guest users.
-
16:56 - 17:00The official Debian Developers come from
the ldap which will still work, -
17:00 - 17:07but we have a problem with guest users,
so we currently don't have a way to -
17:07 - 17:14source for managing those guest users,
especially give additional groups like -
17:14 - 17:16"Hey, the user's a DM"
-
17:17 - 17:22I would love to give all DMs access to
the Debian group, write access, -
17:22 - 17:25but I can't currently because I'm not able
to identify them -
17:26 - 17:30which is something we want to solve with
the new sso.debian.org feature. -
17:31 - 17:37sso.debian.org should also develop a new
authentication protocol like OAuth2, -
17:37 - 17:43which we will use for salsa but new
web services can also rely on, -
17:44 - 17:51??? a way from this certificate stuff
which is somewhat nice -
17:51 - 17:55but it's not that good integrated in most
browsers anymore -
17:55 - 17:58and it doesn't work that well.
-
18:01 - 18:06We hope to have, we already have
a prototype, and we hope to have it live -
18:06 - 18:08until the end of the summer.
-
18:11 - 18:13What we left behind.
-
18:15 - 18:17We don't have shells anymore.
-
18:18 - 18:22So you won't be able to run any cron jobs
or other stuff on salsa and -
18:22 - 18:30please don't ask, we won't give anyone
a shell on salsa.debian.org or godard -
18:30 - 18:32which is the host hosting it.
-
18:34 - 18:37We have APIs, several of them,
I will show them -
18:38 - 18:44Please use them, we won't run any
cron jobs or custom stuff on gitlab, -
18:44 - 18:50it was a nightmare on alioth to maintain
and to administrate -
18:50 - 18:54and I will never, never want to get
into this again. -
18:56 - 19:03What we also don't have are custom domains
which is a feature gitlab has, but -
19:03 - 19:08DSA decided against it, so you will have
to live with -
19:08 - 19:17projectname.pages.debian.net until
someone decides for that feature. -
19:18 - 19:27We also left behind old version…
not so much used anymore version control systems -
19:27 - 19:31like darcs, bazaar, subversion which isn't
a problem, -
19:32 - 19:38but we also don't have cvs anymore,
which may be a surprise for someone -
19:38 - 19:44but Debian is still a heavy user of cvs,
especially for our web site -
19:44 - 19:45and translations.
-
19:47 - 19:53But maybe they will now migrate faster
away from cvs. -
19:53 - 19:57They are working on it, I know,
they're working on it for 10 years -
19:58 - 20:04but things are getting faster and
they're making progress -
20:04 - 20:06in migrating away from cvs.
-
20:08 - 20:13Yeah, ???, that's right,
we also left mercurial, -
20:15 - 20:17or whatever people have in their
home directory. -
20:20 - 20:24Yeah we also had rcs on alioth, there
were rcs repos, yes. -
20:28 - 20:29What we got instead.
-
20:33 - 20:36We got a bunch of new features
we didn't have before. -
20:38 - 20:45So, this is such… maybe a start of new
ways of working in Debian, -
20:45 - 20:48we got a bunch of collaboration features.
-
20:48 - 20:53In the past, collaboration often meant
finding the right mailing list, -
20:53 - 20:55sending a patch and hoping.
-
20:57 - 21:03Now we can use merge requests, which
allow people to easily fork and -
21:03 - 21:09modify packages or repositories, and after
they are done, they can just hit a button -
21:09 - 21:16or whatever and create a nice merge
request which is already heavily used -
21:16 - 21:21by some projects like apt or dak or my own
redirector. -
21:22 - 21:27That allows ???, the admins
of those repositories/projects -
21:27 - 21:34to review code easily, they can add
comments, they can discuss with -
21:34 - 21:37those people out of the mailing list.
-
21:38 - 21:44If people update a bunch and they
commited, those merge requests -
21:44 - 21:51get updated which is a workflow we are
also using very heavily in our company -
21:51 - 21:54which is pretty nice in my eyes.
-
21:57 - 22:00This also allows contribution to packages
from outside people -
22:01 - 22:05It lowers the barrier for people to
collaborate with Debian, -
22:05 - 22:07which is in my eyes a good feature,
-
22:07 - 22:14something I always liked on Github and
I'm happy we are having it too now. -
22:19 - 22:24Gitlab has a nice feature of good, well
designed web frontend, -
22:24 - 22:27some things could be better, but it's
always the case, -
22:27 - 22:33but in most cases Gitlab is still
blazingly fast -
22:33 - 22:37except if you've hit some of the bugs
in the API -
22:37 - 22:39but that's an other problem.
-
22:42 - 22:43And you can work with it.
-
22:44 - 22:46If you don't like the web frontend,
use the API, -
22:46 - 22:49nearly everything the web frontend
supports is exposed via the API -
22:52 - 22:55And there are also a bunch of
command line clients -
22:56 - 23:02which can integrate into git to allow
things like merge requests, -
23:02 - 23:06allow you to process merge requests
from the command line -
23:06 - 23:08if you don't like web frontends.
-
23:13 - 23:21You can also open merge requests
by e-mail if you still like it -
23:22 - 23:25you can just hit the right buttons,
you'll get a mail address -
23:26 - 23:27that you can use.
-
23:27 - 23:30And if you send a patch to that mail address
you will create a merge request, -
23:31 - 23:33some of the not so known features.
-
23:42 - 23:43Issues.
-
23:44 - 23:46You can track todo items or bugs.
-
23:48 - 23:51Please, this is not intended for Debian
packages, -
23:51 - 23:54so please don't replace the BTS
-
23:54 - 23:57but using it as an issue tracker or todo
lists is great. -
23:58 - 23:59We are using it all the time.
-
24:00 - 24:05We're also having some upstream projects
on salsa, like sane or ??? -
24:06 - 24:07which is ???
-
24:08 - 24:10So, they're using issues, that's fine too.
-
24:10 - 24:13Issues are disabled by default for
a project, -
24:13 - 24:17but every project has ??? to just
enable it and to use it. -
24:17 - 24:20You have boards where you can organize
your work, -
24:20 - 24:27you can add sprints, you can add
milestones and other things, -
24:27 - 24:31all the basic stuff you need to have
an issue tracker is included. -
24:33 - 24:39And we also enabled reply by mail so
you don't have to use the web frontend, -
24:40 - 24:45you can just use your mail client
to reply your answers into Gitlab. -
24:48 - 24:51You can also close issues by merge requests.
-
24:52 - 24:57So, similar to our BTS, Gitlab has
this "closes" feature. -
25:00 - 25:06It's all the same. So "Close", "Closes"…
and so on, it's all the same -
25:07 - 25:09and we close here your issues.
-
25:11 - 25:14You can even close issues in other
projects, -
25:14 - 25:20so if you have projects related together
and you fix something in another project -
25:20 - 25:22you can even close it with that syntax.
-
25:26 - 25:30You can also create issues by mail,
which is basically the same -
25:30 - 25:33as for merge requests,
-
25:33 - 25:39you have that "email new issue" button
where you get a custom mail address you can use -
25:39 - 25:41and then you can use that mail address
for the future -
25:41 - 25:47to submit bugs if you don't want to use
the issue tracker. -
26:01 - 26:03What we also got are webhooks.
-
26:04 - 26:09Custom hooks are not anymore possible
because you don't have access to -
26:09 - 26:11the repositories directly
-
26:11 - 26:13but what you can use are webhooks.
-
26:14 - 26:17Webhooks are common standard in the
web world, -
26:18 - 26:22you can use them to react to events
in your repository, -
26:22 - 26:27events may be things like someone created
an issue, someone created a pull request, -
26:27 - 26:32someone pushed something, someone took
something, things like that. -
26:34 - 26:38And you can use those events to create
IRC notifications, -
26:38 - 26:43we have two IRC bots available for you
to use, which is KGB -
26:43 - 26:45and my own irker instance.
-
26:46 - 26:49You can automatically close or tag
bugs -
26:49 - 26:53If you look into our documentation,
wiki.debian.org, -
26:53 - 26:58you find a small paragraph about it
where you can just, -
26:58 - 27:03as we did before, if you close a bug
and you enable the tag pending, -
27:03 - 27:10tag pending webhook, your bug will
be tagged automatically as pending -
27:10 - 27:16like before if you used the ???
hooks on alioth. -
27:16 - 27:21And you can also trigger external CI QA
systems, like Jenkins or SonarQube -
27:21 - 27:24or whatever you like to test you code.
-
27:27 - 27:31In the future, we will also use it
for collab, for the collaboration stuff -
27:31 - 27:38from tincho, where we will just forward
every push happened on the whole salsa system -
27:38 - 27:45so you don't have to configure that
manually, it will happen automatically -
27:45 - 27:52So if you contribute something to Debian,
it will come up on collab.debian.net -
28:02 - 28:05If you want to provide webhooks but you
don't want to run your own web server, -
28:06 - 28:09you can come to us, which means you have
to code Ruby. -
28:10 - 28:14We have our own webhook server implementation
for salsa.debian.org, -
28:14 - 28:20which is currently also running on salsa,
but that must be the case in the future. -
28:20 - 28:26So, if you want to run a webhook, provide us
a patch for our webhook implementation -
28:26 - 28:31which is pluggable, so write a plugin which
listens to your webhooks, -
28:31 - 28:37provide a patch, a merge request and we'll
happily add it to our webhook implementation -
28:37 - 28:40so it can be used for everybody.
-
28:42 - 28:43Documentation is in the wiki.
-
28:48 - 28:51Currently provided hooks are, as already
mentioned, tagpending -
28:52 - 28:58which allows you to tag bug as pending if
you mention them in you changelog -
28:58 - 29:06and some projects directly working with
commits are using the close webhook -
29:06 - 29:09which allows you to directly close
a bug with a commit -
29:10 - 29:15which is used by some web servers and
other stuff directly used in Debian. -
29:20 - 29:23One of the most powerful features we got
is Gitlab CI. -
29:24 - 29:27Gitlab CI is a system that allows
a continuous integration, -
29:27 - 29:30continuous development on salsa
-
29:31 - 29:37and that allows you to build, test and
eventually deploy software and packages -
29:37 - 29:39from within Gitlab.
-
29:40 - 29:43You can nearly do whatever you want
in this CI stuff, -
29:44 - 29:51you can compile ???, run linter,
run autopkgtest, -
29:52 - 29:54whatever you can imagine you can do.
-
29:55 - 29:59We have two runners provided.
-
30:00 - 30:05One of it is running as an ???
on Google cloud, -
30:06 - 30:09the other one is hardware sponsored
by a sponsor -
30:10 - 30:16and for every CI run, we launch a docker
container in it, -
30:16 - 30:21You can even provide an image you want
to use as this one -
30:21 - 30:24and then you can do whatever you want
with it. -
30:25 - 30:28But please don't do bitmining or
something like that, -
30:31 - 30:34be kind to them, we all have to use them
and we have only two of them, -
30:34 - 30:38so please, if you want to do something
bigger, talk to us -
30:39 - 30:41like the KDE people already did.
-
30:44 - 30:45How to use it?
-
30:46 - 30:48Using Gitlab CI is surprisingly easy.
-
30:49 - 30:55There is this gitlab-ci.yml file which is
usually in the root of your repository -
30:56 - 31:01but you can add configuration to your
repository, for example to -
31:01 - 31:04add it to your /debian repository
which works better for -
31:04 - 31:07??? packages
-
31:08 - 31:13or whatever you have, if you don't want to
clutter the upstream directories -
31:13 - 31:15of your gitlab-ci file.
-
31:17 - 31:27[Question about potential conflicts with
gitlab-ci files from upstream] -
31:29 - 31:32We already have a bug opened on the
Gitlab issue tracker -
31:32 - 31:37that allows us to change the default name
of the gitlab-ci file because -
31:37 - 31:42currently, if you import an external
repository, which has a gitlab-ci file -
31:42 - 31:43which can happen,
-
31:43 - 31:48if we happily run on our infrastructure
and for example, -
31:48 - 31:52it's ansible or some other project
which has it -
31:52 - 31:56for every upstream commit, salsa will
happily run our runners -
31:56 - 31:59and build the pipeline.
-
32:02 - 32:04After you edit your file, that's it.
-
32:06 - 32:11From then on, you can watch every commit
happening on your pipeline. -
32:12 - 32:16This is a simple gitlab-ci file, gitlab-ci
files are yaml-based, -
32:16 - 32:22documentation is in the Gitlab repository,
the documentation repository and -
32:28 - 32:33as you can see, it's pretty easy, you have
a pre-step, which allows you to do things -
32:33 - 32:37like installing dependencies which is
what's happening here. -
32:38 - 32:46Since Gitlab CI is running a detached
head, if you want to ??? -
32:46 - 32:48use git buildpackage, we will have to
checkout master -
32:49 - 32:50for it to properly work,
-
32:51 - 32:54then you can do a git pull, git buildpackage
and, after that, -
32:54 - 32:57you have build your package.
-
32:58 - 32:59That's basically all.
-
33:00 - 33:01You can also use artifacts.
-
33:01 - 33:11Artifacts allow you to… keep a build
artifact for downloading, so -
33:11 - 33:18if you want someone to use a package,
you can just add an artifact stanza here -
33:18 - 33:21and that allows you to later download
your deb files. -
33:21 - 33:27Now that doesn't allow you to create
a repository ??? -
33:27 - 33:29but it's an other problem.
-
33:31 - 33:36If it's too much, you can also use this
thing we published yesterday. -
33:37 - 33:44This is a prepared docker container which
is prepared for git buildpackage and -
33:44 - 33:47all you have to do is to execute this.
-
33:49 - 33:50After that, you have Gitlab CI.
-
33:51 - 33:55[Applause]
-
33:55 - 33:59I don't know who provided it, but it popped
up in the wiki yesterday -
33:59 - 34:00or something like that.
-
34:05 - 34:07We also have Gitlab pages.
-
34:07 - 34:13Gitlab pages are like Github pages and
allow you to host web sites, -
34:13 - 34:16static web sites from within Gitlab.
-
34:18 - 34:24Internally they also use Gitlab CI, so
you provide a Gitlab CI job -
34:24 - 34:30that just deploys your website, so
it's nothing to do -
34:30 - 34:32and here's our build artifact feature.
-
34:33 - 34:39All we do here is just add those public
files in the public directory to our pages -
34:39 - 34:43and we only do this on the master branch
-
34:43 - 34:45and basically that's it.
-
34:46 - 34:51The magic is happening here, it's the
"pages" step and -
34:51 - 34:57if you correctly configure pages in your
repository configuration, -
34:57 - 34:59you have a Gitlab page after that.
-
35:03 - 35:06You can also do more fancy things like
a Hugo web site, -
35:06 - 35:11just depend on a docker image which has
hugo installed -
35:11 - 35:20and then execute a script which builds
Hugo, add some artifacts -
35:20 - 35:22and after that you have a Hugo website.
-
35:22 - 35:27You can also use it for blogs, you can
use it in personal repositories, -
35:27 - 35:30then for example for your own web site
or blogs. -
35:30 - 35:35Of course, it's not intended to serve
big web sites -
35:35 - 35:42but providing blogs for planet.debian.org
is perfectly fine, for example -
35:42 - 35:49or web site of ??? project or
whatever is Debian-related. -
35:52 - 35:56This brings me to an other topic
not mentioned in my slides -
35:57 - 36:00some people asked us what is fine to host
on salsa. -
36:02 - 36:07As long as it's open source, as long as
it's intended to be Debian-related -
36:07 - 36:11or open source related or can be included
in Debian, -
36:11 - 36:14it's perfectly fine to host it on salsa.
-
36:15 - 36:18So we invite every upstream which is
looking for a home, -
36:18 - 36:22like the SANE guys, to host them
on salsa. -
36:28 - 36:32What we got with the latest major version
is a web editor -
36:34 - 36:36which is pretty new,
-
36:37 - 36:40probably buggy, but it works.
-
36:41 - 36:43So, if you don't want to clone
a repository -
36:45 - 36:50or you have just to have simple changes,
you can add your file in the web editor, -
36:50 - 36:52you get a web editor with syntax
highlighting, -
36:52 - 36:56you get even a markdown preview if you
just do documentation, -
36:57 - 37:00so that's great for every one just doing
documentation -
37:00 - 37:03that doesn't want to ??? with git
-
37:04 - 37:09or the code inside, you can even
preview it, -
37:10 - 37:12then you can write a commit message,
-
37:16 - 37:18and that's it.
-
37:48 - 37:52What we also have is two-factor
authentication, which is a security feature -
37:52 - 37:55that allows you to add a second factor
to your Gitlab login. -
37:56 - 38:04I can only recommend to use it, that's
well integrated and adds a lot of security. -
38:09 - 38:12It works with Yubikeys or any U2F-compatible
key -
38:13 - 38:17and also with software solutions that
implement TOTP, -
38:17 - 38:22time-based one time passwords.
-
38:23 - 38:29So every TOTP-compatible generator also
works, for example the Google authenticator -
38:29 - 38:32but there are also others which are
open source, that all works. -
38:33 - 38:35Adding it is easy.
-
38:39 - 38:42???
-
38:47 - 38:47It's easy.
-
38:48 - 38:51What you can't see now is me getting
my smartphone out, -
38:52 - 38:55scanning the bar code, generating a PIN
code, -
38:56 - 39:00and in 2 seconds I will enter the PIN code
-
39:08 - 39:11What you see here are recovery codes,
-
39:11 - 39:13I will mention them in a few minutes.
-
39:14 - 39:19You can use them to recover your account
if you lost your one-time password generator -
39:21 - 39:23So, if I log in now,
-
39:28 - 39:32I have to use my smartphone to generate
an authentication code, add it, -
39:33 - 39:35and now I'm in, that's it.
-
39:35 - 39:37So it's pretty easy.
-
39:38 - 39:44Some people say "Oh, what if I lost
my token, that is such much work." -
39:46 - 39:47No, it's easy.
-
39:47 - 39:50If you want to recover your token,
I do that all the time, -
39:50 - 39:56you can just use SSH and do
"ssh git@salsa.debian.org" -
39:57 - 40:01and the command "2fa_recovery_codes"
which will generate you -
40:01 - 40:03a number of new recovery codes,
-
40:04 - 40:06and you can use it to log in.
-
40:07 - 40:12So if I don't have my authentication
token with, I just use this every time. -
40:15 - 40:16It works.
-
40:16 - 40:19And SSH also has an other token.
Huh? -
40:19 - 40:20[Q] It's cheating.
-
40:20 - 40:23[A] No, it works, it's a second factor,
so it's fine. -
40:29 - 40:32So, the API.
-
40:32 - 40:33I have to get faster.
-
40:38 - 40:40Gitlab exposes a powerful JSON REST API,
-
40:41 - 40:44that allows you to query and to manipulate
nearly all aspects of Gitlab. -
40:45 - 40:50If I say "all", I really mean all, nearly
everything you can do with the web frontend -
40:50 - 40:51is covered by the API.
-
40:52 - 40:56The API has an extensive documentation
in that link. -
40:57 - 41:02Ensure that you use the CE, for
"Community Edition", in the docs, -
41:02 - 41:07otherwise you will see features that
aren't available in our edition. -
41:09 - 41:11You can use it for everything.
-
41:12 - 41:17Small hint, you often see the term
"namespace ID". -
41:18 - 41:22In nearly all cases, you can replace
the namespace ID with the path -
41:22 - 41:27of the project, of the thing, mostly
projects, -
41:27 - 41:32but if your project includes slashes,
which is nearly always the case, -
41:32 - 41:41you have to replace a slash with "%2F"
and you can use it as the namespace ID -
41:41 - 41:47so you don't have to look up every time
your IDs, you can just use names. -
41:51 - 41:53Some examples.
-
41:53 - 41:54Get data about your user.
-
41:54 - 41:56If you want to know ???
in your user, -
41:56 - 41:58you can just ask the API.
-
41:59 - 42:03For every use of things that need
authentication, -
42:03 - 42:05you need to generate a private token,
which is easy, -
42:06 - 42:10just go to your profile and there's
a link to access tokens -
42:10 - 42:12and generate one for your usecase.
-
42:13 - 42:15You can also add expiration dates.
-
42:17 - 42:21Even if I use curl here, I can only
recommend to use a proper library. -
42:22 - 42:25Don't use curl, please do me a favor and
don't use curl. -
42:26 - 42:31There's a bunch of ???
flying around ??? curl -
42:32 - 42:35then they hit the first time pagination
or something like that, -
42:35 - 42:37and they start wondering why
it doesn't work. -
42:40 - 42:43There are Python libraries, Ruby libraries,
Perl libraries for Gitlab, -
42:43 - 42:46so we have everything in place that
you need. -
42:47 - 42:50What you can do too, create a repo
in your namespace. -
42:50 - 42:53If you do it that way, the repo will be
private. -
42:53 - 42:56Of course, there are parameters to create
a public repo, -
42:56 - 42:59but that means you have to read
the documentation. -
43:06 - 43:10List open merge requests of a project,
also easy, -
43:10 - 43:14just go to Projects, which is a namespace
for project-related stuff, -
43:15 - 43:18add your project, in my case it's
"AliothRewriter", -
43:19 - 43:22it's a merge request, ???
specific state -
43:22 - 43:28and you get a nice formatted JSON
to get nice JSON you can format -
43:30 - 43:31to list all your merge request.
-
43:32 - 43:33So, I have to get to an end.
-
43:34 - 43:36How to get support.
-
43:37 - 43:41If you have any problems with alioth,
you can of course talk to me or to ganneff -
43:43 - 43:47The channel is still #alioth, and will
probably stay for some time. -
43:50 - 43:55You find us on IRC, you can ???
e-mail, salsa-admin@debian.org. -
43:56 - 43:59We also have an issue tracker, so if you
have a problem, open an issue -
44:00 - 44:04but please don't open upstream gitlab
stuff in our issue tracker. -
44:04 - 44:06If you have a problem with salsa, fine,
create a ticket. -
44:07 - 44:10If you have some problem with how Gitlab
is doing things, -
44:10 - 44:14or have found a bug in Gitlab, please
do us a favor and open those bugs -
44:14 - 44:18in the Gitlab issue tracker because it's
the same thing we would have to do, -
44:19 - 44:21and we won't ??? your bugs.
-
44:24 - 44:27How we do it. If you're interested in
how we did those stuff, -
44:28 - 44:32we are all doing it unprivileged in git
on godard.debian.org, -
44:32 - 44:35and everything we do is automated
via ansible -
44:36 - 44:41and you find it in our ansible repository
in the salsa group on salsa.debian.org. -
44:44 - 44:45Who are we?
-
44:49 - 44:51Salsa currently has 3 administrators:
-
44:51 - 44:57Bastian Blank (waldi), Jörg Jaspert (ganneff)
here, and me. -
45:03 - 45:05My picture is gone.
-
45:06 - 45:09What you would see here is a "thanks"
picture. -
45:09 - 45:14Thank you for your attention, and we have
maybe 1 or 2 minutes left for questions. -
45:15 - 45:23[Applause]
-
45:27 - 45:31[Q] I have a quick question about SSO
going down. -
45:31 - 45:34Is SSO going down with alioth? On the first
of June? -
45:34 - 45:35[A] No, but…
-
45:36 - 45:39As mentioned in the announcement,
I usually do wide annoucements -
45:39 - 45:40and I hope people read it.
-
45:41 - 45:48I will back up authentication database
of alioth to ???.debian.org, -
45:48 - 45:50which is the host running SSO
-
45:51 - 45:57and I will maintain those users by hand
until we have the new SSO backend ready. -
45:58 - 46:02[Q] So, if there's people going to
the registers of debconf, which are not -
46:02 - 46:07Debian Developpers, in Taiwan, can they
still register after the first of June, or not? -
46:08 - 46:10[A] They can, they can't SSO anymore
for registration, -
46:10 - 46:14but they did implement a second
authentication, but… -
46:15 - 46:21It's been 3 years since debconf doesn't
need SSO. -
46:23 - 46:25Any further questions on salsa?
-
46:30 - 46:33[Q] I have a little question about salsa
at all. -
46:34 - 46:40There is some howtos, how to create
an account on salsa, -
46:40 - 46:46how to manipulate that account, create
repositories for example. -
46:47 - 47:00I mean, just for people who never came
to it, just use it. ??? documentation. -
47:01 - 47:04[A] Except for user registration, there's
nothing specific on salsa.debian.org, -
47:04 - 47:10so you can just use the gitlab documentation
which has videos, webcasts, -
47:10 - 47:12tutorials and so on.
-
47:12 - 47:16Just use it, it's good documentation,
nearly everything is covered by it -
47:17 - 47:19and if you still have questions after that,
ask us. -
47:20 - 47:23If you have Debian-specific stuff, look
at the wiki. -
47:24 - 47:30wiki.debian.org/salsa/doc has nearly
everything, I hope, most things covered. -
47:31 - 47:34If not, tell us, and in the end it's a wiki
-
47:35 - 47:38so if you find something or think it's
interesting for other people, -
47:38 - 47:40please, please add it to the wiki.
-
47:44 - 47:46Any other questions?
-
47:49 - 47:50Ok, everything's answered.
-
47:51 - 47:52Thanks a lot again.
-
47:52 - 47:57[Applause]
- Title:
- salsa.debian.org state of affairs
- Description:
-
Talk given by Alexander Wirt at Minidebconf Hamburg 18
https://meetings-archive.debian.net/pub/debian-meetings/2018/miniconf-hamburg/2018-05-19/salsa.debian.org_state.webm - Video Language:
- English
- Team:
Debconf
- Project:
- 2018_mini-debconf-hamburg
- Duration:
- 48:02
![]() |
tvincent edited English subtitles for salsa.debian.org state of affairs | |
![]() |
tvincent edited English subtitles for salsa.debian.org state of affairs | |
![]() |
tvincent edited English subtitles for salsa.debian.org state of affairs | |
![]() |
tvincent edited English subtitles for salsa.debian.org state of affairs | |
![]() |
tvincent edited English subtitles for salsa.debian.org state of affairs | |
![]() |
tvincent edited English subtitles for salsa.debian.org state of affairs | |
![]() |
tvincent edited English subtitles for salsa.debian.org state of affairs | |
![]() |
tvincent edited English subtitles for salsa.debian.org state of affairs |