Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
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
1
Merge Requests
1
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
gitlab-ce
Commits
3b6e441c
Commit
3b6e441c
authored
Jan 16, 2019
by
GitLab Bot
Browse files
Options
Browse Files
Download
Plain Diff
Automatic merge of gitlab-org/gitlab-ce master
parents
3f8e5356
eec16ee2
Changes
8
Hide whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
25 additions
and
13 deletions
+25
-13
GITLAB_PAGES_VERSION
GITLAB_PAGES_VERSION
+1
-1
app/models/project.rb
app/models/project.rb
+1
-1
changelogs/unreleased/ac-pages-subgroups.yml
changelogs/unreleased/ac-pages-subgroups.yml
+5
-0
doc/user/group/subgroups/index.md
doc/user/group/subgroups/index.md
+5
-3
doc/user/project/pages/getting_started_part_one.md
doc/user/project/pages/getting_started_part_one.md
+7
-3
doc/user/project/pages/introduction.md
doc/user/project/pages/introduction.md
+3
-2
spec/controllers/projects/pages_controller_spec.rb
spec/controllers/projects/pages_controller_spec.rb
+2
-2
spec/models/project_spec.rb
spec/models/project_spec.rb
+1
-1
No files found.
GITLAB_PAGES_VERSION
View file @
3b6e441c
1.
3.1
1.
4.0
app/models/project.rb
View file @
3b6e441c
...
...
@@ -1531,7 +1531,7 @@ class Project < ActiveRecord::Base
end
def
pages_available?
Gitlab
.
config
.
pages
.
enabled
&&
!
namespace
.
subgroup?
Gitlab
.
config
.
pages
.
enabled
end
def
remove_private_deploy_keys
...
...
changelogs/unreleased/ac-pages-subgroups.yml
0 → 100644
View file @
3b6e441c
---
title
:
Pages for subgroups
merge_request
:
23505
author
:
type
:
added
doc/user/group/subgroups/index.md
View file @
3b6e441c
...
...
@@ -164,9 +164,11 @@ and you can choose the group of people to be notified.
Here's a list of what you can't do with subgroups:
-
[
GitLab Pages
](
../../project/pages/index.md
)
are not currently working for
projects hosted under a subgroup. That means that only projects hosted under
the first parent group will work.
-
[
GitLab Pages
](
../../project/pages/index.md
)
supports projects hosted under
a subgroup, but not subgroup websites.
That means that only the highest-level group supports
[
group websites
](
../../project/pages/introduction.html#user-or-group-pages
)
,
although you can have project websites under a subgroup.
-
It is not possible to share a project with a group that's an ancestor of
the group the project is in. That means you can only share as you walk down
the hierarchy. For example,
`group/subgroup01/project`
**cannot**
be shared
...
...
doc/user/project/pages/getting_started_part_one.md
View file @
3b6e441c
...
...
@@ -85,6 +85,12 @@ and a project within this group is called `blog`. Your project
URL is
`https://gitlab.com/websites/blog/`
. Once you enable
GitLab Pages for this project, the site will live under
`https://websites.gitlab.io/blog/`
.
-
You created a group for your engineering department called
`engineering`
,
a subgroup for all your documentation websites called
`docs`
,
and a project within this subgroup is called
`workflows`
. Your project
URL is
`https://gitlab.com/engineering/docs/workflows/`
. Once you enable
GitLab Pages for this project, the site will live under
`https://engineering.gitlab.io/docs/workflows`
.
#### User and Group Websites
...
...
@@ -97,9 +103,7 @@ will be published under `https://john.gitlab.io`.
Once you enable GitLab Pages for your project,
your website will be published under
`https://websites.gitlab.io`
.
>**Note:**
GitLab Pages
[
does **not** support subgroups
](
../../group/subgroups/index.md#limitations
)
.
You can only create the highest level group website.
> Support for subgroup project's websites was [introduced](https://gitlab.com/gitlab-org/gitlab-ce/issues/30548) in GitLab 11.8.
**General example:**
...
...
doc/user/project/pages/introduction.md
View file @
3b6e441c
...
...
@@ -38,6 +38,7 @@ be served on.
| Group pages |
`groupname.example.io`
|
`http(s)://groupname.example.io`
|
| Project pages owned by a user |
`projectname`
|
`http(s)://username.example.io/projectname`
|
| Project pages owned by a group |
`projectname`
|
`http(s)://groupname.example.io/projectname`
|
| Project pages owned by a subgroup |
`subgroup/projectname`
|
`http(s)://groupname.example.io/subgroup/projectname`
|
> **Warning:**
> There are some known [limitations](#limitations) regarding namespaces served
...
...
@@ -494,8 +495,8 @@ don't redirect HTTP to HTTPS.
[
rfc
]:
https://tools.ietf.org/html/rfc2818#section-3.1
"HTTP Over TLS RFC"
GitLab Pages
[
does **not** support subgroups
](
../../group/subgroups/index.md#limitations
)
.
You can only create the highest
level group website.
GitLab Pages
[
does **not** support
group websites for
subgroups
](
../../group/subgroups/index.md#limitations
)
.
You can only create the highest
-
level group website.
## Redirects in GitLab Pages
...
...
spec/controllers/projects/pages_controller_spec.rb
View file @
3b6e441c
...
...
@@ -28,10 +28,10 @@ describe Projects::PagesController do
let
(
:group
)
{
create
(
:group
,
:nested
)
}
let
(
:project
)
{
create
(
:project
,
namespace:
group
)
}
it
'returns a
404
status code'
do
it
'returns a
200
status code'
do
get
:show
,
params:
request_params
expect
(
response
).
to
have_gitlab_http_status
(
404
)
expect
(
response
).
to
have_gitlab_http_status
(
200
)
end
end
end
...
...
spec/models/project_spec.rb
View file @
3b6e441c
...
...
@@ -3368,7 +3368,7 @@ describe Project do
context
'when the project is in a subgroup'
do
let
(
:group
)
{
create
(
:group
,
:nested
)
}
it
{
is_expected
.
to
be
(
fals
e
)
}
it
{
is_expected
.
to
be
(
tru
e
)
}
end
end
...
...
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