diff --git a/documentation/content/en/books/handbook/mirrors/_index.adoc b/documentation/content/en/books/handbook/mirrors/_index.adoc index e15d256b0d..518daf5493 100644 --- a/documentation/content/en/books/handbook/mirrors/_index.adoc +++ b/documentation/content/en/books/handbook/mirrors/_index.adoc @@ -1,910 +1,910 @@ --- title: Appendix A. Obtaining FreeBSD part: Part V. Appendices prev: books/handbook/partv next: books/handbook/bibliography description: "How to get FreeBSD: CD and DVD sets, FTP sites and how to install and use Git" --- [appendix] [[mirrors]] = Obtaining FreeBSD :doctype: book :icons: font :sectnums: :sectnumlevels: 6 :source-highlighter: rouge :experimental: :skip-front-matter: :xrefstyle: basic :relfileprefix: ../ :outfilesuffix: :sectnumoffset: A include::shared/mirrors.adoc[] include::shared/authors.adoc[] include::shared/releases.adoc[] include::shared/en/mailing-lists.adoc[] include::shared/en/teams.adoc[] include::shared/en/urls.adoc[] [[mirrors-cdrom]] == CD and DVD Sets FreeBSD CD and DVD sets are available from several online retailers: * FreeBSD Mall, Inc. + 2420 Sand Creek Rd C-1 #347 + Brentwood, CA + 94513 + USA + Phone: +1 925 240-6652 + Fax: +1 925 674-0821 + Email: + WWW: https://www.freebsdmall.com * Getlinux + 78 Rue de la Croix Rochopt + Épinay-sous-Sénart + 91860 + France + Email: + WWW: http://www.getlinux.fr/ * Dr. Hinner EDV + Kochelseestr. 11 + D-81371 München + Germany + Phone: (0177) 428 419 0 + Email: + WWW: http://www.hinner.de/linux/freebsd.html [[mirrors-ftp]] == FTP Sites The official sources for FreeBSD are available via anonymous FTP from a worldwide set of mirror sites. The site link:ftp://ftp.FreeBSD.org/pub/FreeBSD/[ftp://ftp.FreeBSD.org/pub/FreeBSD/] is available via HTTP and FTP. It is made up of many machines operated by the project cluster administrators and behind GeoDNS to direct users to the closest available mirror. Additionally, FreeBSD is available via anonymous FTP from the following mirror sites. When obtaining FreeBSD via anonymous FTP, please try to use a nearby site. The mirror sites listed as "Primary Mirror Sites" typically have the entire FreeBSD archive (all the currently available versions for each of the architectures) but faster download speeds are probably available from a site that is in your country or region. The regional sites carry the most recent versions for the most popular architecture(s) but might not carry the entire FreeBSD archive. All sites provide access via anonymous FTP but some sites also provide access via other methods. The access methods available for each site are provided in parentheses after the hostname. <>, <>, <>, <>, <>, <>, <>, <>, <>, <>, <>, <>, <>, <>, <>, <>, <>, <>, <>, <>, <>, <>, <>, <>, <>, <>, <>, <>, <>, <>, <>, <>, <>, <>. (as of UTC) [[central]] *{central}* {central-ftp} (ftp / ftpv6 / {central-http} / {central-httpv6}) [[primary]] *{mirrors-primary}* In case of problems, please contact the hostmaster `<{mirrors-primary-email}>` for this domain. * {mirrors-primary-ftp1} (ftp) * {mirrors-primary-ftp2} (ftp) * {mirrors-primary-ftp3} (ftp) * {mirrors-primary-ftp4} (ftp / ftpv6 / {mirrors-primary-ftp4-http} / {mirrors-primary-ftp4-httpv6}) * {mirrors-primary-ftp5} (ftp) * {mirrors-primary-ftp6} (ftp) * {mirrors-primary-ftp7} (ftp) * {mirrors-primary-ftp10} (ftp / ftpv6 / {mirrors-primary-ftp10-http} / {mirrors-primary-ftp10-httpv6}) * {mirrors-primary-ftp11} (ftp) * {mirrors-primary-ftp13} (ftp) * {mirrors-primary-ftp14} (ftp / {mirrors-primary-ftp14-http}) [[armenia]] *{mirrors-armenia}* In case of problems, please contact the hostmaster `<{mirrors-armenia-email}>` for this domain. * {mirrors-armenia-ftp} (ftp / {mirrors-armenia-ftp-http} / rsync) [[australia]] *{mirrors-australia}* In case of problems, please contact the hostmaster `<{mirrors-australia-email}>` for this domain. * {mirrors-australia-ftp} (ftp) * {mirrors-australia-ftp2} (ftp) * {mirrors-australia-ftp3} (ftp) [[austria]] *{mirrors-austria}* In case of problems, please contact the hostmaster `<{mirrors-austria-email}>` for this domain. * {mirrors-austria-ftp} (ftp / ftpv6 / {mirrors-austria-ftp-http} / {mirrors-austria-ftp-httpv6}) [[brazil]] *{mirrors-brazil}* In case of problems, please contact the hostmaster `<{mirrors-brazil-email}>` for this domain. * {mirrors-brazil-ftp2} (ftp / {mirrors-brazil-ftp2-http}) * {mirrors-brazil-ftp3} (ftp / rsync) * {mirrors-brazil-ftp4} (ftp) [[czech-republic]] *{mirrors-czech}* In case of problems, please contact the hostmaster `<{mirrors-czech-email}>` for this domain. * {mirrors-czech-ftp} (ftp / {mirrors-czech-ftpv6} / {mirrors-czech-ftp-http} / {mirrors-czech-ftp-httpv6} / rsync / rsyncv6) * {mirrors-czech-ftp2} (ftp / {mirrors-czech-ftp2-http}) [[denmark]] *{mirrors-denmark}* In case of problems, please contact the hostmaster `<{mirrors-denmark-email}>` for this domain. * {mirrors-denmark-ftp} (ftp / ftpv6 / {mirrors-denmark-ftp-http} / {mirrors-denmark-ftp-httpv6}) [[estonia]] *{mirrors-estonia}* In case of problems, please contact the hostmaster `<{mirrors-estonia-email}>` for this domain. * {mirrors-estonia-ftp} (ftp) [[finland]] *{mirrors-finland}* In case of problems, please contact the hostmaster `<{mirrors-finland-email}>` for this domain. * {mirrors-finland-ftp} (ftp) [[france]] *{mirrors-france}* In case of problems, please contact the hostmaster `<{mirrors-france-email}>` for this domain. * {mirrors-france-ftp} (ftp) * {mirrors-france-ftp1} (ftp / {mirrors-france-ftp1-http} / rsync) * {mirrors-france-ftp3} (ftp) * {mirrors-france-ftp5} (ftp) * {mirrors-france-ftp6} (ftp / rsync) * {mirrors-france-ftp7} (ftp) * {mirrors-france-ftp8} (ftp) [[germany]] *{mirrors-germany}* In case of problems, please contact the hostmaster `<{mirrors-germany-email}>` for this domain. * ftp://ftp.de.FreeBSD.org/pub/FreeBSD/ (ftp) * ftp://ftp1.de.FreeBSD.org/freebsd/ (ftp / http://www1.de.FreeBSD.org/freebsd/ / rsync://rsync3.de.FreeBSD.org/freebsd/) * ftp://ftp2.de.FreeBSD.org/pub/FreeBSD/ (ftp / http://ftp2.de.FreeBSD.org/pub/FreeBSD/ / rsync) * ftp://ftp4.de.FreeBSD.org/FreeBSD/ (ftp / http://ftp4.de.FreeBSD.org/pub/FreeBSD/) * ftp://ftp5.de.FreeBSD.org/pub/FreeBSD/ (ftp) * ftp://ftp7.de.FreeBSD.org/pub/FreeBSD/ (ftp / http://ftp7.de.FreeBSD.org/pub/FreeBSD/) * ftp://ftp8.de.FreeBSD.org/pub/FreeBSD/ (ftp) [[greece]] *{mirrors-greece}* In case of problems, please contact the hostmaster `<{mirrors-greece-email}>` for this domain. * {mirrors-greece-ftp} (ftp) * {mirrors-greece-ftp2} (ftp) [[hong-kong]] *{mirrors-hongkong}* {mirrors-hongkong-ftp} (ftp) [[ireland]] *{mirrors-ireland}* In case of problems, please contact the hostmaster `<{mirrors-ireland-email}>` for this domain. * {mirrors-ireland-ftp} (ftp / rsync) [[japan]] *{mirrors-japan}* In case of problems, please contact the hostmaster `<{mirrors-japan-email}>` for this domain. * {mirrors-japan-ftp} (ftp) * {mirrors-japan-ftp2} (ftp) * {mirrors-japan-ftp3} (ftp) * {mirrors-japan-ftp4} (ftp) * {mirrors-japan-ftp5} (ftp) * {mirrors-japan-ftp6} (ftp) * {mirrors-japan-ftp7} (ftp) * {mirrors-japan-ftp8} (ftp) * {mirrors-japan-ftp9} (ftp) [[korea]] *{mirrors-korea}* In case of problems, please contact the hostmaster `<{mirrors-korea-email}>` for this domain. * {mirrors-korea-ftp} (ftp / rsync) * {mirrors-korea-ftp2} (ftp / {mirrors-korea-ftp2-http}) [[latvia]] *{mirrors-latvia}* In case of problems, please contact the hostmaster `<{mirrors-latvia-email}>` for this domain. * {mirrors-latvia-ftp} (ftp / {mirrors-latvia-ftp-http}) [[lithuania]] *{mirrors-lithuania}* In case of problems, please contact the hostmaster `<{mirrors-lithuania-email}>` for this domain. * {mirrors-lithuania-ftp} (ftp / {mirrors-lithuania-ftp-http}) [[netherlands]] *{mirrors-netherlands}* In case of problems, please contact the hostmaster `<{mirrors-netherlands-email}>` for this domain. * {mirrors-netherlands-ftp} (ftp / {mirrors-netherlands-ftp-http} / rsync) * {mirrors-netherlands-ftp2} (ftp) [[new-zealand]] *{mirrors-new-zealand}* * {mirrors-new-zealand-ftp} (ftp / {mirrors-new-zealand-ftp-http}) [[norway]] *{mirrors-norway}* In case of problems, please contact the hostmaster `<{mirrors-norway-email}>` for this domain. * {mirrors-norway-ftp} (ftp / rsync) [[poland]] *{mirrors-poland}* In case of problems, please contact the hostmaster `<{mirrors-poland-email}>` for this domain. * {mirrors-poland-ftp} (ftp) * ftp2.pl.FreeBSD.org [[russia]] *{mirrors-russia}* In case of problems, please contact the hostmaster `<{mirrors-russia-email}>` for this domain. * {mirrors-russia-ftp} (ftp / {mirrors-russia-ftp-http} / rsync) * {mirrors-russia-ftp2} (ftp / {mirrors-russia-ftp2-http} / rsync) * {mirrors-russia-ftp4} (ftp) * {mirrors-russia-ftp5} (ftp / {mirrors-russia-ftp5-http} / rsync) * {mirrors-russia-ftp6} (ftp) [[saudi-arabia]] *{mirrors-saudi-arabia}* In case of problems, please contact the hostmaster `<{mirrors-saudi-arabia-email}>` for this domain. * {mirrors-saudi-arabia-ftp} (ftp) [[slovenia]] *{mirrors-slovenia}* In case of problems, please contact the hostmaster `<{mirrors-slovenia-email}>` for this domain. * {mirrors-slovenia-ftp} (ftp) [[south-africa]] *{mirrors-south-africa}* In case of problems, please contact the hostmaster `<{mirrors-south-africa-email}>` for this domain. * {mirrors-south-africa-ftp} (ftp) * {mirrors-south-africa-ftp2} (ftp) * {mirrors-south-africa-ftp4} (ftp) [[spain]] *{mirrors-spain}* In case of problems, please contact the hostmaster `<{mirrors-spain-email}>` for this domain. * {mirrors-spain-ftp} (ftp / {mirrors-spain-ftp-http}) * {mirrors-spain-ftp3} (ftp) [[sweden]] *{mirrors-sweden}* In case of problems, please contact the hostmaster `<{mirrors-sweden-email}>` for this domain. * {mirrors-sweden-ftp} (ftp) * {mirrors-sweden-ftp2} (ftp / {mirrors-sweden-ftp2-rsync}) * {mirrors-sweden-ftp3} (ftp) * {mirrors-sweden-ftp4} (ftp / {mirrors-sweden-ftp4v6} / {mirrors-sweden-ftp4-http} / {mirrors-sweden-ftp4-httpv6} / {mirrors-sweden-ftp4-rsync} / {mirrors-sweden-ftp4-rsyncv6}) * {mirrors-sweden-ftp6} (ftp / {mirrors-sweden-ftp6-http}) [[switzerland]] *{mirrors-switzerland}* In case of problems, please contact the hostmaster `<{mirrors-switzerland-email}>` for this domain. * {mirrors-switzerland-ftp} (ftp / {mirrors-switzerland-ftp-http}) [[taiwan]] *{mirrors-taiwan}* In case of problems, please contact the hostmaster `<{mirrors-taiwan-email}>` for this domain. * {mirrors-taiwan-ftp} (ftp / {mirrors-taiwan-ftpv6} / rsync / rsyncv6) * {mirrors-taiwan-ftp2} (ftp / {mirrors-taiwan-ftp2v6} / {mirrors-taiwan-ftp2-http} / {mirrors-taiwan-ftp2-httpv6} / rsync / rsyncv6) * {mirrors-taiwan-ftp4} (ftp) * {mirrors-taiwan-ftp5} (ftp) * {mirrors-taiwan-ftp6} (ftp / {mirrors-taiwan-ftp6v6} / rsync) * {mirrors-taiwan-ftp7} (ftp) * {mirrors-taiwan-ftp8} (ftp) * {mirrors-taiwan-ftp11} (ftp / {mirrors-taiwan-ftp11-http}) * {mirrors-taiwan-ftp12} (ftp) * {mirrors-taiwan-ftp13} (ftp) * {mirrors-taiwan-ftp14} (ftp) * {mirrors-taiwan-ftp15} (ftp) [[ukraine]] *{mirrors-ukraine}* * {mirrors-ukraine-ftp} (ftp / {mirrors-ukraine-ftp-http}) * {mirrors-ukraine-ftp6} (ftp / {mirrors-ukraine-ftp6-http} / {mirrors-ukraine-ftp6-rsync}) * {mirrors-ukraine-ftp7} (ftp) [[uk]] *{mirrors-uk}* In case of problems, please contact the hostmaster `<{mirrors-uk-email}>` for this domain. * {mirrors-uk-ftp} (ftp) * {mirrors-uk-ftp2} (ftp / {mirrors-uk-ftp2-rsync}) * {mirrors-uk-ftp3} (ftp) * {mirrors-uk-ftp4} (ftp) * {mirrors-uk-ftp5} (ftp) [[usa]] *{mirrors-us}* In case of problems, please contact the hostmaster `<{mirrors-us-email}>` for this domain. * {mirrors-us-ftp} (ftp) * {mirrors-us-ftp2} (ftp) * {mirrors-us-ftp3} (ftp) * {mirrors-us-ftp4} (ftp / ftpv6 / {mirrors-us-ftp4-http} / {mirrors-us-ftp4-httpv6}) * {mirrors-us-ftp5} (ftp) * {mirrors-us-ftp6} (ftp) * {mirrors-us-ftp8} (ftp) * {mirrors-us-ftp10} (ftp) * {mirrors-us-ftp11} (ftp) * {mirrors-us-ftp13} (ftp / {mirrors-us-ftp13-http} / rsync) * {mirrors-us-ftp14} (ftp / {mirrors-us-ftp14-http}) * {mirrors-us-ftp15} (ftp) [[git]] == Using Git [[git-intro]] === Introduction As of December 2020, FreeBSD uses git as the primary version control system for storing all of FreeBSD's base source code and documentation. As of April 2021, FreeBSD uses git as the only version control system for storing all of FreeBSD's Ports Collection. [NOTE] ==== Git is generally a developer tool. Users may prefer to use `freebsd-update` (crossref:cutting-edge[updating-upgrading-freebsdupdate,“FreeBSD Update”]) to update the FreeBSD base system, and `portsnap` (crossref:ports[ports-using,“Using the Ports Collection”]) to update the FreeBSD Ports Collection. ==== This section demonstrates how to install Git on a FreeBSD system and use it to create a local copy of a FreeBSD repository. Additional information on the use of Git is included. [[git-ssl-certificates]] === Root SSL Certificates FreeBSD systems older than 12._x_ do not have proper root certificates. Installing package:security/ca_root_nss[] on these systems allows Git to verify the identity of HTTPS repository servers. The root SSL certificates can be installed from a port: [source,shell] .... # cd /usr/ports/security/ca_root_nss # make install clean .... or as a package: [source,shell] .... # pkg install ca_root_nss .... [[git-install]] === Installation Git can be installed as a package: [source,shell] .... # pkg install git .... Git can also be installed from the Ports Collection: [source,shell] .... # cd /usr/ports/devel/git # make install clean .... [[git-usage]] === Running Git To fetch a clean copy of the sources into a local directory, use `git`. This directory of files is called the _working tree_. [WARNING] ==== Move or delete an existing destination directory before using `git clone` for the first time. Cloning over an existing non-git directory will fail. ==== Git uses URLs to designate a repository, taking the form of _protocol://hostname/path_. The first component of the path is the FreeBSD repository to access. There are three different repositories, `src` for the FreeBSD systerm source code, `doc` for documentation, and `ports` for the FreeBSD Ports Collection. For example, the URL `https://git.FreeBSD.org/src.git` specifies the main branch of the src repository, using the `https` protocol. [[git-url-table]] .FreeBSD Git Repository URL Table [options="header,foooter"] |======================================================= |Item | Git URL | Web-based repository browser src | `https://cgit.freebsd.org/src` | Read-only src repo via HTTPS | `https://git.freebsd.org/src.git` | Read-only src repo via anon-ssh | `ssh://anongit@git.freebsd.org/src.git` | Read/write src repo for committers | `ssh://git@gitrepo.freebsd.org/src.git` (*) | Web-based repository browser doc | `https://cgit.freebsd.org/doc` | Read-only doc repo via HTTPS | `https://git.freebsd.org/doc.git` | Read-only doc repo via anon-ssh | `ssh://anongit@git.freebsd.org/doc.git` | Read/write doc repo for committers | `ssh://git@gitrepo.freebsd.org/doc.git` (*) | Web-based repository browser ports | `https://cgit.freebsd.org/ports` | Read-only ports repo via HTTPS | `https://git.freebsd.org/ports.git` | Read-only ports repo via anon-ssh | `ssh://anongit@git.freebsd.org/ports.git` | Read/write ports repo for committers | `ssh://git@gitrepo.freebsd.org/ports.git` (*) |======================================================= - (*) `git` is a special user on the repository server which will map your registered ssh key in FreeBSD.org to your identity, no need to change it. [WARNING] ==== Sometime after the switch to git is complete, `gitrepo.freebsd.org` will change to simply `repo.freebsd.org`. ==== To get started, clone a copy of the FreeBSD repository: [source,shell] .... # git clone -o freebsd [ -b branch ] https://git.FreeBSD.org/repo.git wcdir .... where: * _repo_ is one of the Project repositories: `src`, `ports`, or `doc`. * _branch_ depends on the repository used. `ports` and `doc` are mostly updated in the `main` branch, while `src` maintains the latest version of -CURRENT under `main` and the respective latest versions of the -STABLE branches under `stable/12` (12._x_) and `stable/13` (13._x_). * _wcdir_ is the target directory where the contents of the specified branch should be placed. This is usually [.filename]#/usr/ports# for `ports`, [.filename]#/usr/src# for `src`, and [.filename]#/usr/doc# for `doc`. * _freebsd_ is the name of the origin to use. By convention in the FreeBSD documentation, the origin is assumed to be `freebsd`. This example checks out the `main` branch of the system sources from the FreeBSD repository using the HTTPS protocol, placing the local working copy in [.filename]#/usr/src#. If [.filename]#/usr/src# is already present but was not created by `git`, remember to rename or delete it before the checkout. Git will refuse to do anything otherwise. [source,shell] .... # git clone -o freebsd https://git.FreeBSD.org/src.git /usr/src .... Because the initial checkout must download the full branch of the remote repository, it can take a while. Please be patient. After the initial checkout, the local working copy can be updated by running: [source,shell] .... # cd wcdir # git pull --rebase .... To update [.filename]#/usr/src# created in the example above, use: [source,shell] .... # cd /usr/src # git pull --rebase .... The update is much quicker than a checkout, only transferring files that have changed. There are also external mirrors maintained by project members available, please refer to the <> section. === SSH related information * `ssh://${user}@${url}/${repo}.git` can be written as `${user}@${url}:${repo}.git`, i.e., following two URLs are both valid for passing to `git`: -- ** `ssh://anongit@git.freebsd.org/${repo}.git` ** `anongit@git.freebsd.org:${repo}.git` As well as the read-write repo: ** `ssh://git@(git)repo.freebsd.org/${repo}.git` ** `git@(git)repo.freebsd.org:${repo}.git` -- * gitrepo.FreeBSD.org host key fingerprints: ** ECDSA key fingerprint is `SHA256:seWO5D27ySURcx4bknTNKlC1mgai0whP443PAKEvvZA` ** ED25519 key fingerprint is `SHA256:lNR6i4BEOaaUhmDHBA1WJsO7H3KtvjE2r5q4sOxtIWo` ** RSA key fingerprint is `SHA256:f453CUEFXEJAXlKeEHV+ajJfeEfx9MdKQUD7lIscnQI` * git.FreeBSD.org host key fingerprints: ** ECDSA key fingerprint is `SHA256:/UlirUAsGiitupxmtsn7f9b7zCWd0vCs4Yo/tpVWP9w` ** ED25519 key fingerprint is `SHA256:y1ljKrKMD3lDObRUG3xJ9gXwEIuqnh306tSyFd1tuZE` ** RSA key fingerprint is `SHA256:jBe6FQGoH4HjvrIVM23dcnLZk9kmpdezR/CvQzm7rJM` These are also published as SSHFP records in DNS. === Web-based repository browser The FreeBSD project currently uses cgit as the web-based repository browser: https://cgit.freebsd.org/. The URLs of indivirual repositories are listed in <>. === For Users Using `git clone` and `git pull` from the official distributed mirrors is recommended. The GeoDNS should direct you to the nearest mirror to you. === For Developers This section describes the read-write access for committers to push the commits from developers or contributors. For read-only access, please refer to the users section above. ==== Daily use * Clone the repository: + [source,shell] .... % git clone -o freebsd --config remote.freebsd.fetch='+refs/notes/*:refs/notes/*' https://git.freebsd.org/${repo}.git .... + Then you should have the official mirrors as your remote: + [source,shell] .... % git remote -v freebsd https://git.freebsd.org/${repo}.git (fetch) freebsd https://git.freebsd.org/${repo}.git (push) .... * Configure the FreeBSD committer data: + The commit hook in repo.freebsd.org checks the "Commit" field matches the committer's information in FreeBSD.org. The easiest way to get the suggested config is by executing `/usr/local/bin/gen-gitconfig.sh` script on freefall: + [source,shell] .... % gen-gitconfig.sh [...] % git config user.name (your name in gecos) % git config user.email (your login)@FreeBSD.org .... * Set the push URL: + [source,shell] .... % git remote set-url --push freebsd git@gitrepo.freebsd.org:${repo}.git .... + Then you should have separated fetch and push URLs as the most efficient setup: + [source,shell] .... % git remote -v freebsd https://git.freebsd.org/${repo}.git (fetch) freebsd git@gitrepo.freebsd.org:${repo}.git (push) .... + Again, note that `gitrepo.freebsd.org` will be canonicalized to `repo.freebsd.org` in the future. * Install commit message template hook: + [source,shell] .... % fetch https://cgit.freebsd.org/src/plain/tools/tools/git/hooks/prepare-commit-msg -o .git/hooks % chmod 755 .git/hooks/prepare-commit-msg .... ==== "admin" branch The `access` and `mentors` files are stored in an orphan branch, `internal/admin`, in each repository. Following example is how to check out the `internal/admin` branch to a local branch named `admin`: [source,shell] .... % git config --add remote.freebsd.fetch '+refs/internal/*:refs/internal/*' % git fetch % git checkout -b admin internal/admin .... Alternatively, you can add a worktree for the `admin` branch: [source,shell] .... git worktree add -b admin ../${repo}-admin internal/admin .... For browsing `internal/admin` branch on web: https://cgit.freebsd.org/${repo}/log/?h=internal/admin For pushing, either specify the full refspec: [source,shell] .... git push freebsd HEAD:refs/internal/admin .... Or set `push.default` to `upstream` which will make `git push` to push the current branch back to its upstream by default, which is more suitable for our workflow: [source,shell] .... git config push.default upstream .... [WARNING] ==== These internal details may change often. ==== [[external-mirrors]] === External mirrors Those mirrors are not hosted in FreeBSD.org but still maintained by the project members. Users and developers are welcome to pull or browse repositories on those mirrors. The project workflow with those mirrors are still under discussion. ==== Codeberg - doc: https://codeberg.org/FreeBSD/freebsd-doc - ports: https://codeberg.org/FreeBSD/freebsd-ports - src: https://codeberg.org/FreeBSD/freebsd-src ==== GitHub - doc: https://github.com/freebsd/freebsd-doc - ports: https://github.com/freebsd/freebsd-ports - src: https://github.com/freebsd/freebsd-src ==== GitLab - doc: https://gitlab.com/FreeBSD/freebsd-doc - ports: https://gitlab.com/FreeBSD/freebsd-ports - src: https://gitlab.com/FreeBSD/freebsd-src === Mailing lists General usage and questions about git in the FreeBSD project: [freebsd-git](https://lists.freebsd.org/mailman/listinfo/freebsd-git) Commit messages will be sent to the following mailing lists: - https://lists.freebsd.org/mailman/listinfo/dev-commits-doc-all[dev-commits-doc-all]: All changes to the doc repository - https://lists.freebsd.org/mailman/listinfo/dev-commits-ports-all[dev-commits-ports-all]: All changes to the ports repository - https://lists.freebsd.org/mailman/listinfo/dev-commits-ports-main[dev-commits-ports-main]: All changes to the "main" branch of the ports repository - https://lists.freebsd.org/mailman/listinfo/dev-commits-ports-branches[dev-commits-ports-branches]: All changes to the quarterly branches of the ports repository - https://lists.freebsd.org/mailman/listinfo/dev-commits-src-all[dev-commits-src-all]: All changes to the src repository - https://lists.freebsd.org/mailman/listinfo/dev-commits-src-main[dev-commits-src-main]: All changes to the "main" branch of the src repository (the FreeBSD-CURRENT branch) - https://lists.freebsd.org/mailman/listinfo/dev-commits-src-branches[dev-commits-src-branches]: All changes to all stable branches of the src repository For more information, please refer to the "Commit message lists" section of C.2. "Mailing Lists" in handbook: https://www.freebsd.org/doc/en/books/handbook/eresources-mail.html [[svn]] == Using Subversion [[svn-intro]] === Introduction As of December 2020, FreeBSD uses git as the primary version control system for storing all of FreeBSD's source code and documentation. Changes from the git repo on the `stable/11`, `stable/12` and related releng branches are exported to the subversion repository. This export will continue through the life of these branches. From July 2012 to March 2021, FreeBSD used Subversion as the only version control system for storing all of FreeBSD's Ports Collection. As of April 2021, FreeBSD uses git as the only version control system for storing all of FreeBSD's Ports Collection. [NOTE] ==== Subversion is generally a developer tool. Users may prefer to use `freebsd-update` (crossref:cutting-edge[updating-upgrading-freebsdupdate,“FreeBSD Update”]) to update the FreeBSD base system, and `portsnap` (crossref:ports[ports-using,“Using the Ports Collection”]) to update the FreeBSD Ports Collection. After March 2021, subversion use is only for legacy branches (`stable/11` and `stable/12`). ==== This section demonstrates how to install Subversion on a FreeBSD system and use it to create a local copy of a FreeBSD repository. Additional information on the use of Subversion is included. [[svn-ssl-certificates]] === Root SSL Certificates FreeBSD systems older than 12._x_ do not have proper root certificates. Those certificates allow Subversion to verify the identity of HTTPS repository servers. Installation instructions are described in <>. [[svn-svnlite]] === Svnlite A lightweight version of Subversion is already installed on FreeBSD as `svnlite`. The port or package version of Subversion is only needed if the Python or Perl API is needed, or if a later version of Subversion is desired. The only difference from normal Subversion use is that the command name is `svnlite`. [[svn-install]] === Installation If `svnlite` is unavailable or the full version of Subversion is needed, then it must be installed. Subversion can be installed from the Ports Collection: [source,shell] .... # cd /usr/ports/devel/subversion # make install clean .... Subversion can also be installed as a package: [source,shell] .... # pkg install subversion .... [[svn-usage]] === Running Subversion To fetch a clean copy of the sources into a local directory, use `svn`. The files in this directory are called a _local working copy_. [WARNING] ==== Move or delete an existing destination directory before using `checkout` for the first time. Checkout over an existing non-`svn` directory can cause conflicts between the existing files and those brought in from the repository. ==== Subversion uses URLs to designate a repository, taking the form of _protocol://hostname/path_. The first component of the path is the FreeBSD repository to access. There are three different repositories, `base` for the FreeBSD base system source code, `ports` for the Ports Collection, and `doc` for documentation. For example, the URL `https://svn.FreeBSD.org/base/head/` specifies the main branch of the ports repository, using the `https` protocol. A checkout from a given repository is performed with a command like this: [source,shell] .... # svn checkout https://svn.FreeBSD.org/repository/branch lwcdir .... where: * _repository_ is one of the Project repositories: `base`, `ports`, or `doc`. -* _branch_ depends on the repository used. `ports` and `doc` are mostly updated in the `head` branch, while `base` maintains the latest version of -CURRENT under `head` and the respective latest versions of the -STABLE branches under `stable/9` (9._x_) and `stable/10` (10._x_). +* _branch_ depends on the repository used. `ports` and `doc` are mostly updated in the `head` branch, while `base` maintains the latest version of -CURRENT under `head` and the respective latest versions of the -STABLE branches under `stable/11` (11._x_) and `stable/12` (12._x_). * _lwcdir_ is the target directory where the contents of the specified branch should be placed. This is usually [.filename]#/usr/ports# for `ports`, [.filename]#/usr/src# for `base`, and [.filename]#/usr/doc# for `doc`. This example checks out the Source Tree from the FreeBSD repository using the HTTPS protocol, placing the local working copy in [.filename]#/usr/src#. If [.filename]#/usr/src# is already present but was not created by `svn`, remember to rename or delete it before the checkout. [source,shell] .... # svn checkout https://svn.FreeBSD.org/base/head /usr/src .... Because the initial checkout must download the full branch of the remote repository, it can take a while. Please be patient. After the initial checkout, the local working copy can be updated by running: [source,shell] .... # svn update lwcdir .... To update [.filename]#/usr/src# created in the example above, use: [source,shell] .... # svn update /usr/src .... The update is much quicker than a checkout, only transferring files that have changed. An alternate way of updating the local working copy after checkout is provided by the [.filename]#Makefile# in the [.filename]#/usr/ports#, [.filename]#/usr/src#, and [.filename]#/usr/doc# directories. Set `SVN_UPDATE` and use the `update` target. For example, to update [.filename]#/usr/src#: [source,shell] .... # cd /usr/src # make update SVN_UPDATE=yes .... [[svn-mirrors]] === Subversion Mirror Sites The FreeBSD Subversion repository is: [.programlisting] .... svn.FreeBSD.org .... This is a publicly accessible mirror network that uses GeoDNS to select an appropriate back end server. To view the FreeBSD Subversion repositories through a browser, use https://svnweb.FreeBSD.org/[https://svnweb.FreeBSD.org/]. HTTPS is the preferred protocol, but the [.filename]#security/ca_root_nss# package will need to be installed in order to automatically validate certificates. === For More Information For other information about using Subversion, please see the "Subversion Book", titled http://svnbook.red-bean.com/[Version Control with Subversion], or the http://subversion.apache.org/docs/[Subversion Documentation]. [[mirrors-rsync]] == Using rsync These sites make FreeBSD available through the rsync protocol. The rsync utility transfers only the differences between two sets of files. This is useful for mirror sites of the FreeBSD FTP server. The rsync suite is available for many operating systems, on FreeBSD, see the package:net/rsync[] port or use the package. Czech Republic:: rsync://ftp.cz.FreeBSD.org/ + Available collections: ** ftp: A partial mirror of the FreeBSD FTP server. ** FreeBSD: A full mirror of the FreeBSD FTP server. Netherlands:: rsync://ftp.nl.FreeBSD.org/ + Available collections: ** FreeBSD: A full mirror of the FreeBSD FTP server. Russia:: rsync://ftp.mtu.ru/ + Available collections: ** FreeBSD: A full mirror of the FreeBSD FTP server. ** FreeBSD-Archive: The mirror of FreeBSD Archive FTP server. Sweden:: rsync://ftp4.se.freebsd.org/ + Available collections: ** FreeBSD: A full mirror of the FreeBSD FTP server. Taiwan:: rsync://ftp.tw.FreeBSD.org/ + rsync://ftp2.tw.FreeBSD.org/ + rsync://ftp6.tw.FreeBSD.org/ + Available collections: ** FreeBSD: A full mirror of the FreeBSD FTP server. United Kingdom:: rsync://rsync.mirrorservice.org/ + Available collections: ** ftp.freebsd.org: A full mirror of the FreeBSD FTP server. United States of America:: rsync://ftp-master.FreeBSD.org/ + This server may only be used by FreeBSD primary mirror sites. + Available collections: + -- ** FreeBSD: The master archive of the FreeBSD FTP server. ** acl: The FreeBSD master ACL list. -- + rsync://ftp13.FreeBSD.org/ + Available collections: ** FreeBSD: A full mirror of the FreeBSD FTP server.