Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

refactor: use craft-application's remote-build #5239

Open
wants to merge 9 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
40 changes: 34 additions & 6 deletions docs/explanation/remote-build.rst
Original file line number Diff line number Diff line change
Expand Up @@ -8,19 +8,18 @@ different architectures.
Architectures supported by Launchpad can be found
:ref:`here<supported-architectures>`.

Open vs closed source
---------------------
Public and private projects
---------------------------

By default, prospective snaps must be open source because the build will be
publicly available.
By default, prospective snaps are publicly uploaded to `Launchpad`_.

Developers are reminded of this by confirming that their project will be
publicly available when starting a remote build. This prompt can be
automatically agreed to by passing ``--launchpad-accept-public-upload``.

Closed-source projects can be built using the remote builder. This requires
Private projects can still be built using the remote builder. This requires
the user to create a private `Launchpad project`_ and pass the project with the
``--project <project-name>`` command line argument. An ``ssh`` key must be
``--project <project-name>`` command line argument. An SSH key must be
registered in Launchpad because source code is uploaded using SSH.

Git repository
Expand Down Expand Up @@ -84,6 +83,9 @@ Current

``--build-for``
***************
**Type**: Comma-separated list of strings

**Default**: The architectures specified in your project file or your host architecture
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
**Default**: The architectures specified in your project file or your host architecture
**Default**: The architectures specified in your project file or your host architecture


.. note::
``--build-for`` behaves differently for ``remote-build`` than it does for
Expand All @@ -107,6 +109,32 @@ The second mode of operation is when there isn't a ``platforms`` or
``architectures`` key in the project file. In this scenario, ``--build-for``
defines the architectures to build for.

``--launchpad-accept-public-upload``
************************************

Bypasses the prompt that confirms whether you want to upload data to the public. It's
not necessary to use this flag if you used ``--project`` to specify a private project.

``--project``
*************
**Type**: String

Explicitly specify a project to upload to.

``--launchpad-timeout``
***********************
**Type**: Integer

**Default**: 0
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
**Default**: 0
**Default**: 0


Time, in seconds, to wait for Launchpad to complete a build. A time of 0 seconds will
wait indefinitely.

``--recover``
*************

Attempt to recover previously interrupted builds.

Project platforms and architectures
***********************************

Expand Down
6 changes: 3 additions & 3 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -7,13 +7,13 @@ dependencies = [
"attrs",
"catkin-pkg==1.0.0 ; sys_platform == 'linux'",
"click==8.1.7",
"craft-application==4.4.1", # Pinned due to https://github.com/canonical/snapcraft/issues/5231
"craft-application[remote]~=4.9",
"craft-archives~=2.0",
"craft-cli~=2.15.0",
"craft-grammar>=2.0.1,<3.0.0",
"craft-parts==2.4.1",
"craft-platforms~=0.4",
"craft-providers>=2.2.0,<3.0.0",
"craft-platforms~=0.6",
"craft-providers~=2.1",
"craft-store>=3.0.2,<4.0.0",
"cryptography==43.0.3", # Pinned due to https://github.com/canonical/snapcraft/issues/5217
"gnupg",
Expand Down
Loading
Loading