From Fedora Project Wiki
(clarify cla group)
m (better to change to `mkdir -p` as to prevent accidental overwrite of folder)
 
(25 intermediate revisions by 20 users not shown)
Line 1: Line 1:
{{autolang|base=yes}}
{{autolang|base=yes}}


= fedorapeople.org =
== fedorapeople.org ==


This page covers the details on how to obtain and use your personal
This page covers the details on how to obtain and use your personal
space on [http://fedorapeople.org fedorapeople.org] , which is a site where Fedora
space on [https://fedorapeople.org fedorapeople.org], a site where Fedora
contributors can upload files for sharing out with the world. It is
contributors can upload files to share with the world. It is
perfect for uploading specfiles, srpms, patches, personal repository etc, etc.
perfect for uploading specfiles, SRPMs, patches, or personal Git repositories.


== Forbidden contents ==
== Forbidden contents ==


* Do NOT distribute anything on fedorapeople.org that Fedora itself cannot distribute for legal reasons. Nothing on the [[ForbiddenItems]] list or otherwise non distributable by Fedora.
* Do NOT distribute anything on [https://fedorapeople.org fedorapeople.org] that Fedora itself cannot distribute for legal reasons. Nothing on the [[ForbiddenItems]] list or otherwise non distributable by Fedora.
* Do NOT upload your private .ssh keys. While Fedora Infrastructure Team works hard on keeping the servers secure, break ins will happen and private keys uploaded can be downloaded and brute-forced easily these days. Private .ssh keys if found during an audit will be deleted.
* Do NOT upload your private ssh keys. While the Fedora Infrastructure Team works hard on keeping the servers secure, break-ins will happen and private keys uploaded can be downloaded and brute-forced easily. Private .ssh keys found during an audit will be deleted.


== Accessing Your fedorapeople.org Space ==
== Accessing your fedorapeople.org space ==


# You need an active [https://admin.fedoraproject.org/accounts/ Fedora account]
# You need an active [https://accounts.fedoraproject.org/ Fedora account]
# You must be part of atleast one group (other than the CLA group) in Fedora account system. If you have not done anything with your account besides set it up and sign the CLA then you can request sufficient access to use fedorapeople space by visiting [http://fedorahosted.org/packager-sponsors the sponsors trac instance] and filing a ticket in the "Initial package hosting request" component.
# You must be part of at least one group (other than the CLA group) in the [https://accounts.fedoraproject.org/ Fedora account system]. Often annotated as CLA+1


# You need to generate a ssh key (ssh-keygen -t rsa).
# You need to generate a ssh key (<code>ssh-keygen -t rsa</code>).
# Upload that ssh key into your Fedora account. To upload, [https://admin.fedoraproject.org/accounts/user/edit visit this link] and select your key file using the ''Public RSA SSH key'' field. Normally your key is stored in your home directory under ''.ssh/id_rsa.pub''. The ssh key gets activated an hour after you upload it.
# Upload the ssh key into your Fedora account. To upload, [https://accounts.fedoraproject.org/ visit this link] and select your key file using the ''Public RSA SSH key'' field. Oftentimes, your public key can be found in your home directory under <code>.ssh/id_rsa.pub</code>. The ssh key will become activated within 20minutes after it is uploaded.
# To connect, use the ssh key you uploaded into your Fedora account:<pre>ssh -i ~/.ssh/id_rsa <your_username>@fedorapeople.org</pre>
# To be able to verify an identity of fedorapeople.org SSH server, append these [https://admin.fedoraproject.org/ssh_known_hosts Fedora project SSH certificates] to your <code>~/.ssh/known_hosts</code> local file, or make sure your DNS resolver supports DNSSEC and <code>VerifyHostKeyDNS=yes</code> is set in your <code>~/.ssh/config</code> SSH client configuration file. 
# To connect, use the ssh key you uploaded into your Fedora account:


This step can also be done via [https://admin.fedoraproject.org/accounts/ Fedora account.]
<pre>ssh -i ~/.ssh/id_rsa <your_username>@fedorapeople.org</pre>


# While logged in, click on "My Account" on the side bar.
{{admon/important | Updating your SSH public key | If you want to update your SSH public key in [https://fedorapeople.org fedorapeople.org], do NOT manually edit your <code>.ssh/authorized_keys</code> file.  Go through [https://accounts.fedoraproject.org/ the usual FAS account edit page] and wait for it to be updated, or you will be locked out of your account.}}
# Select "edit" link next to "Account Details."
# Type the following in the "Public RSA SSH Key:" field:<pre>~/.ssh/id_rsa.pub</pre>
# Click the "Save!" button.
# Verify your success. You will see "ssh-rsa" followed by alpha numeric string in "Public SSH Key:" field of your Account Details.


== Common Answers ==
# You will need to make a public_html directory for your files: <code>mkdir ~/public_html</code>
# You will need to set permissions so the webserver can read them: <code>chmod 0755 ~/public_html</code> (This sets your home directory and public_html directories readable by the webserver)
# You may wish to make a 'index.html' file in public_html
 
== Common answers ==


* Each Fedora contributor has 2000000 KiB (approximately 1954 MiB) of quota-controlled space.
* Each Fedora contributor has 2000000 KiB (approximately 1954 MiB) of quota-controlled space.
* If you run out of space you should: clean up stuff you don't need. If you cannot clean up anything then you should contact fedora infrastructure to raise your quota.
* If you run out of space, you should clean up files you don't need. If you cannot clean anything up, you should contact Fedora Infrastructure team to raise your quota.
* To make a publicly viewable space, create a <code>public_html</code> directory.
* You need to change the permissions for your home directory to at least <code>711</code> to make it viewable.
* Fedora people is NOT to be used for development or creating repositories on. Repositories will need to be created elsewhere and uploaded via scp or rsync.
 
* DO NOT try to use sudo to install packages you "need." Unless you are in the Infrastructure group, and have gotten approval from sysadmin-main, extra packages are not to be installed on fedorapeople.
<pre>chmod 711 $HOME</pre>
* Upload files using scp, sftp, or rsync.
 
{{admon/tip | Using Nautilus | If you use GNOME, visit [[Infrastructure/fedorapeople.org/Connecting_with_Nautilus | this page]] for an easy way to connect to your fedorapeople.org space.}}
* To make a publicly viewable space, create a <code>public_html</code> directory and set its permissions to <code>755</code>. Your home <code>~/</code> directory must be exectuable for the webserver to see your <code>public_html</code> folder.
* Fedora people is NOT to be used for development or repository creation. Repositories will need to be created elsewhere and uploaded via <code>scp</code> or <code>rsync</code>.
* DO NOT try to use sudo to install packages you "need". Unless you are in the Infrastructure group and have gotten approval from sysadmin-main, extra packages are not to be installed on [https://fedorapeople.org fedorapeople.org].
* Upload files using <code>scp</code>, <code>sftp</code>, or <code>rsync</code>.
{{admon/tip | Using Nautilus | If you use GNOME, visit [[Infrastructure/fedorapeople.org/Connecting_with_Nautilus | this page]] for an easy way to connect to your [https://fedorapeople.org fedorapeople.org] space.}}


{{admon/tip | Using Dolphin or Konqueror | If you use KDE, type <code>sftp://your_username@fedorapeople.org</code> in your file manager address bar for an easy way to connect to your fedorapeople.org space.}}
{{admon/tip | Using Dolphin or Konqueror | If you use KDE, type <code>sftp://your_username@fedorapeople.org</code> in your file manager address bar for an easy way to connect to your [https://fedorapeople.org fedorapeople.org] space.}}


{{admon/tip | Using Thunar | If you use XFCE, type <code>ctrl+l</code> to bring up the Open Location Dialogue and then enter <code>sftp://your_username@fedorapeople.org/home/fedora/your_username</code> in Location field for an easy way to connect to your fedorapeople.org space. PCManFM also works}}
{{admon/tip | Using Thunar | If you use XFCE, press {{key press|CTRL + L}} to bring up the ''Open Location'' dialogue and then enter <code>sftp://your_username@fedorapeople.org/home/fedora/your_username</code> in ''Location'' field for an easy way to connect to your [https://fedorapeople.org fedorapeople.org] space. PCManFM also works}}


To copy files from the command line, you can use scp
To copy files from the command line, you can use <code>scp</code>


<pre>
<pre>
Line 51: Line 56:




* Once uploaded into the users public_html directory the files are available via http at: http://your_username.fedorapeople.org/.
* Once files are uploaded into the user's <code>public_html</code> directory, the files will become available at: https://your_username.fedorapeople.org/.
* Give other users access to read/write/etc files by using extended acls. Read man pages for setfacl and getfacl for adding them to your dirs/files. This gives the user "your_usename" read and write access to <code>file</code>:
* Give other users access to read/write/etc files by using extended ACLs. Read man pages for <code>setfacl</code> and <code>getfacl</code> for adding them to your dirs/files. This gives the user <code>your_username</code> read and write access to <code>file</code>:


<pre>setfacl -m u:your_username:rw file</pre>
<pre>setfacl -m u:your_username:rw file</pre>


== fedora people git hosting support ==
== fedorapeople.org git hosting support ==


fedorapeople.org now has support for hosting git repositories including accessing them via the git:// protocol for anonymous downloads as well as providing the cgit web interface.  
[https://fedorapeople.org fedorapeople.org] now has support for hosting git repositories. This includes access via the <code>git://</code> protocol for anonymous downloads as well as providing the cgit web interface.


Here is a quick rundown of how to get started using git on fedorapeople.org.  It assumes that you are already somewhat familiar with git.  You might want to take a look at the [[Git quick reference]].
Here is a quick rundown of how to get started with git on [https://fedorapeople.org fedorapeople.org].  It assumes that you are already somewhat familiar with git.  You might want to take a look at the [[Git quick reference]].


=== Create a <code>~/public_git</code> directory on fedorapeople.org ===
=== Create a ~/public_git directory on fedorapeople.org ===


<pre>ssh your_username@fedorapeople.org "mkdir ~/public_git; /sbin/restorecon -Rv ~/public_git"</pre>
<pre>ssh your_username@fedorapeople.org "mkdir -p ~/public_git; /sbin/restorecon -Rv ~/public_git"</pre>


=== Creating a new git repository in <code>~/public_git</code> ===
=== Creating a new git repository in ~/public_git ===


As an example, here is one method to create an empty repository ''on your local system'' and upload it:
As an example, here is one method to create an empty repository on your local system and upload it:


<pre>
<pre>
Line 75: Line 80:
</pre>
</pre>


This creates a ''bare'' repository (i.e. a repository that has no working directory).  It contains just the files that are part of the <code>.git</code> directory of a ''non-bare'' git repository (the kind most users are accustomed to seeing).
This creates a bare repository (i.e. a repository that has no working directory).  It contains just the files that are part of the <code>.git</code> directory of a non-bare git repository (the kind most users are accustomed to seeing).


{{admon/important|Repository name must end with .git|cgit will not list repos that do not end in <code>.git</code>.|}}
{{admon/important|Repository name must end with ".git"|cgit will not list repos that do not end with ".git".|}}


Additionally if you wish your repository to show up in the cgit web interface, you must:  
Additionally if you wish your repository to show up in the cgit web interface, you must run the following command for any repositories you wish to appear there by default:  


<pre>
<pre>
Line 85: Line 90:
</pre>
</pre>


For any repositories you wish to appear there by default.
=== Uploading an existing repository to ~/public_git ===


=== Uploading an existing repository to <code>~/public_git</code> ===
If you have an existing repository you want to use on [https://fedorapeople.org fedorapeople.org], you can do so easily:
 
If you have an existing repository you want to use on fedorapeople, you can do so easily:


<pre>
<pre>
Line 108: Line 111:
</pre>
</pre>


This creates a mirror of your local repository.  All of the branches and tags in the local repository will be pushed to the fedorapeople repository.
This creates a mirror of your local repository.  All of the branches and tags in the local repository will be pushed to the [https://fedorapeople.org fedorapeople.org] repository.


If you only want to push selected branches, amend the <code>git push</code> example.  For example, to push only your local master branch:
If you only want to push selected branches, amend the <code>git push</code> example.  For example, to push only your local master branch:
Line 115: Line 118:




{{admon/tip|Allowing others to push|You can allow other fedorapeople.org users to push to your repository using extended acls (see <code>setfacl(1)</code> for details).  However, if you have many others working on your project, using [http://fedorahosted.org Fedora Hosted] is strongly preferred.}}
{{admon/tip|Allowing others to push|You can allow other [https://fedorapeople.org fedorapeople.org] users to push to your repository using extended ACLs (see <code>setfacl(1)</code> man page for details).  However, if you have many others working on your project, using [https://pagure.io/ Pagure] is strongly preferred.}}
 


=== Cloning your repository ===
=== Cloning your repository ===
Line 125: Line 127:




It is also possible to clone your project via the http:// protocol.  In order for this to work, you must arrange to have <code>git-update-server-info</code> run whenever you update your repository.  Typically, this is done with a post-update hook script.  However, the user home directories on fedorapeople.org are mounted with the noexec option, which prevents the script from running.  Instead, you may create a symbolic link to <code>git-update-server-info</code> in the hooks directory of your repository:
It is also possible to clone your project via the <code>http://</code> protocol.  In order for this to work, you must arrange to have <code>git-update-server-info</code> run whenever you update your repository.  Typically, this is done with a post-update hook script.  However, the user home directories on [https://fedorapeople.org fedorapeople.org] are mounted with the noexec option, which prevents the script from running.  Instead, you may create a symbolic link to <code>git-update-server-info</code> in the hooks directory of your repository:


<pre>
<pre>
Line 135: Line 137:




You also need to create a link from ~/public_html/git to ~/public_git:
You also need to create a link from <code>~/public_html/git</code> to <code>~/public_git</code>:


<pre>
<pre>
Line 143: Line 145:




You can clone your repository over http:// with a command similar to:
You can clone your repository over <code>http://</code> with a command similar to:


<pre>git clone http://your_username.fedorapeople.org/git/repo.git/</pre>
<pre>git clone http://your_username.fedorapeople.org/git/repo.git/</pre>




{{admon/tip|git:// versus http://|Only clone via http:// if you are behind a firewall that prevents git:// from working.  The git:// protocol is faster and more efficient than the http:// protocol for git usage.}}
{{admon/tip|<code>git://</code> versus <code>http://</code>|Only clone via <code>http://</code> if you are behind a firewall that prevents <code>git://</code> from working.  The <code>git://</code> protocol is faster and more efficient than the <code>http://</code> protocol for git usage.}}


=== Browsing your project via cgit ===
=== Browsing your project via cgit ===


You can see your project listed in [http://fedorapeople.org/cgit cgit] once the project list updates.  This happens hourly.   
You can see your project listed in [https://fedorapeople.org/cgit cgit] once the project list updates.  This happens hourly.   




Line 161: Line 163:
If you want to give access to your repository to other users you can do this with ACLs.
If you want to give access to your repository to other users you can do this with ACLs.


  setfacl -R -m u:<user>:rwX <repo.git>
<pre>
  find <repo.git> -type d | xargs setfacl -R -m d:u:<user>:rwX
setfacl -R -m u:<user>:rwX <repo.git>
find <repo.git> -type d | xargs setfacl -R -m d:u:<user>:rwX
</pre>


=== Enable per-repo upload-archive ===
If you want to allow your repository to be accessible via <code>git archive --remote</code>, you will need to set set the following in your repository's config file:
<pre>
[daemon] 
uploadarch = true
</pre>


=== Enable per-repo upload-archive ===
== Policies ==


If you want to allow your repository to be accessible via <code>git archive --remote </code>, you will need to set set the following in your repostiory's config file:
=== Viruses ===


  [daemon]  
[https://fedorapeople.org fedorapeople.org] servers are regularly scanned for viruses, including people's home directories, because of the nature of providing download of user-uploaded files on a Fedora domain name.
  uploadarch = true
As soon as a virus is reported by the scanners, they will be scanned again by another scanner to make sure they're actual viruses (and not just an overly active scanner).
If the second opinion also reports the file as being a virus, the file will be moved to a non-public facing directory, and the owner will be notified.
If the user has not yet responded after a week, the file will be deleted.


---
[[Category:Infrastructure]]
[[Category:Infrastructure]]
[[Category:CommOps wiki to docs migration campaign 2021/2022]]

Latest revision as of 14:35, 13 November 2024

fedorapeople.org

This page covers the details on how to obtain and use your personal space on fedorapeople.org, a site where Fedora contributors can upload files to share with the world. It is perfect for uploading specfiles, SRPMs, patches, or personal Git repositories.

Forbidden contents

  • Do NOT distribute anything on fedorapeople.org that Fedora itself cannot distribute for legal reasons. Nothing on the ForbiddenItems list or otherwise non distributable by Fedora.
  • Do NOT upload your private ssh keys. While the Fedora Infrastructure Team works hard on keeping the servers secure, break-ins will happen and private keys uploaded can be downloaded and brute-forced easily. Private .ssh keys found during an audit will be deleted.

Accessing your fedorapeople.org space

  1. You need an active Fedora account
  2. You must be part of at least one group (other than the CLA group) in the Fedora account system. Often annotated as CLA+1
  1. You need to generate a ssh key (ssh-keygen -t rsa).
  2. Upload the ssh key into your Fedora account. To upload, visit this link and select your key file using the Public RSA SSH key field. Oftentimes, your public key can be found in your home directory under .ssh/id_rsa.pub. The ssh key will become activated within 20minutes after it is uploaded.
  3. To be able to verify an identity of fedorapeople.org SSH server, append these Fedora project SSH certificates to your ~/.ssh/known_hosts local file, or make sure your DNS resolver supports DNSSEC and VerifyHostKeyDNS=yes is set in your ~/.ssh/config SSH client configuration file.
  4. To connect, use the ssh key you uploaded into your Fedora account:
ssh -i ~/.ssh/id_rsa <your_username>@fedorapeople.org
Updating your SSH public key
If you want to update your SSH public key in fedorapeople.org, do NOT manually edit your .ssh/authorized_keys file. Go through the usual FAS account edit page and wait for it to be updated, or you will be locked out of your account.
  1. You will need to make a public_html directory for your files: mkdir ~/public_html
  2. You will need to set permissions so the webserver can read them: chmod 0755 ~/public_html (This sets your home directory and public_html directories readable by the webserver)
  3. You may wish to make a 'index.html' file in public_html

Common answers

  • Each Fedora contributor has 2000000 KiB (approximately 1954 MiB) of quota-controlled space.
  • If you run out of space, you should clean up files you don't need. If you cannot clean anything up, you should contact Fedora Infrastructure team to raise your quota.
  • You need to change the permissions for your home directory to at least 711 to make it viewable.
chmod 711 $HOME
  • To make a publicly viewable space, create a public_html directory and set its permissions to 755. Your home ~/ directory must be exectuable for the webserver to see your public_html folder.
  • Fedora people is NOT to be used for development or repository creation. Repositories will need to be created elsewhere and uploaded via scp or rsync.
  • DO NOT try to use sudo to install packages you "need". Unless you are in the Infrastructure group and have gotten approval from sysadmin-main, extra packages are not to be installed on fedorapeople.org.
  • Upload files using scp, sftp, or rsync.
Using Nautilus
If you use GNOME, visit this page for an easy way to connect to your fedorapeople.org space.
Using Dolphin or Konqueror
If you use KDE, type sftp://your_username@fedorapeople.org in your file manager address bar for an easy way to connect to your fedorapeople.org space.
Using Thunar
If you use XFCE, press CTRL + L to bring up the Open Location dialogue and then enter sftp://your_username@fedorapeople.org/home/fedora/your_username in Location field for an easy way to connect to your fedorapeople.org space. PCManFM also works

To copy files from the command line, you can use scp

scp /path/to/file your_username@fedorapeople.org:/home/fedora/your_username/public_html


  • Once files are uploaded into the user's public_html directory, the files will become available at: https://your_username.fedorapeople.org/.
  • Give other users access to read/write/etc files by using extended ACLs. Read man pages for setfacl and getfacl for adding them to your dirs/files. This gives the user your_username read and write access to file:
setfacl -m u:your_username:rw file

fedorapeople.org git hosting support

fedorapeople.org now has support for hosting git repositories. This includes access via the git:// protocol for anonymous downloads as well as providing the cgit web interface.

Here is a quick rundown of how to get started with git on fedorapeople.org. It assumes that you are already somewhat familiar with git. You might want to take a look at the Git quick reference.

Create a ~/public_git directory on fedorapeople.org

ssh your_username@fedorapeople.org "mkdir -p ~/public_git; /sbin/restorecon -Rv ~/public_git"

Creating a new git repository in ~/public_git

As an example, here is one method to create an empty repository on your local system and upload it:

git init --bare repo.git
scp -r repo.git/ your_username@fedorapeople.org:~/public_git/

This creates a bare repository (i.e. a repository that has no working directory). It contains just the files that are part of the .git directory of a non-bare git repository (the kind most users are accustomed to seeing).

Repository name must end with ".git"
cgit will not list repos that do not end with ".git".

Additionally if you wish your repository to show up in the cgit web interface, you must run the following command for any repositories you wish to appear there by default:

touch ~/public_git/yourgitrepo.git/git-daemon-export-ok

Uploading an existing repository to ~/public_git

If you have an existing repository you want to use on fedorapeople.org, you can do so easily:

git clone --bare /path/to/local/repo repo.git
scp -r repo.git/ your_username@fedorapeople.org:public_git/

The caveats from the previous section apply here as well.

Pushing to your repository

To push changes from a local repository:

cd /path/to/local/repo
git remote add fedorapeople your_username@fedorapeople.org:public_git/repo.git
git push --mirror fedorapeople

This creates a mirror of your local repository. All of the branches and tags in the local repository will be pushed to the fedorapeople.org repository.

If you only want to push selected branches, amend the git push example. For example, to push only your local master branch:

git push fedorapeople master


Allowing others to push
You can allow other fedorapeople.org users to push to your repository using extended ACLs (see setfacl(1) man page for details). However, if you have many others working on your project, using Pagure is strongly preferred.

Cloning your repository

To clone your repository, use a command similar to:

git clone git://fedorapeople.org/~your_username/repo.git


It is also possible to clone your project via the http:// protocol. In order for this to work, you must arrange to have git-update-server-info run whenever you update your repository. Typically, this is done with a post-update hook script. However, the user home directories on fedorapeople.org are mounted with the noexec option, which prevents the script from running. Instead, you may create a symbolic link to git-update-server-info in the hooks directory of your repository:

ssh your_username@fedorapeople.org
cd ~/public_git/repo.git/hooks
ln -svbf $(git --exec-path)/git-update-server-info post-update
git update-server-info


You also need to create a link from ~/public_html/git to ~/public_git:

cd ~/public_html
ln -svbf ../public_git git


You can clone your repository over http:// with a command similar to:

git clone http://your_username.fedorapeople.org/git/repo.git/


git:// versus http://
Only clone via http:// if you are behind a firewall that prevents git:// from working. The git:// protocol is faster and more efficient than the http:// protocol for git usage.

Browsing your project via cgit

You can see your project listed in cgit once the project list updates. This happens hourly.


Repository description
You can set the description for the repository that is displayed in cgit by editing the description file in your repository.

Shared repository

If you want to give access to your repository to other users you can do this with ACLs.

setfacl -R -m u:<user>:rwX <repo.git>
find <repo.git> -type d | xargs setfacl -R -m d:u:<user>:rwX

Enable per-repo upload-archive

If you want to allow your repository to be accessible via git archive --remote, you will need to set set the following in your repository's config file:

[daemon]   
uploadarch = true

Policies

Viruses

fedorapeople.org servers are regularly scanned for viruses, including people's home directories, because of the nature of providing download of user-uploaded files on a Fedora domain name. As soon as a virus is reported by the scanners, they will be scanned again by another scanner to make sure they're actual viruses (and not just an overly active scanner). If the second opinion also reports the file as being a virus, the file will be moved to a non-public facing directory, and the owner will be notified. If the user has not yet responded after a week, the file will be deleted.

---