Skip to content

Cloud CLI documentation #2086

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

Merged
merged 21 commits into from
Jun 12, 2024
Merged

Cloud CLI documentation #2086

merged 21 commits into from
Jun 12, 2024

Conversation

meganelacheny
Copy link
Collaborator

@meganelacheny meganelacheny commented Apr 17, 2024

@meganelacheny meganelacheny added flag: merge pending release Pending Strapi Release internal PRs created by the Strapi core team pr: new content PRs for new product features or new documentation sections source: Strapi Cloud PRs/issues targeting the Strapi Cloud documentation labels Apr 17, 2024
@meganelacheny meganelacheny self-assigned this Apr 17, 2024
Copy link

vercel bot commented Apr 17, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
documentation ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jun 12, 2024 9:16am

@meganelacheny meganelacheny marked this pull request as ready for review April 25, 2024 12:58
@meganelacheny meganelacheny requested a review from pwizla as a code owner April 25, 2024 12:58
@meganelacheny meganelacheny requested review from pwizla and removed request for pwizla April 25, 2024 12:58
Copy link
Collaborator

@pwizla pwizla left a comment

Choose a reason for hiding this comment

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

Great job, Mégane, thanks! 🚀 Looks good to me

I only made some wording suggestions to avoid a possible confusion between code stored in a local git repository and code hosted in a remote repository (GitHub, GitLab…).

Copy link
Contributor

@nathan-pichon nathan-pichon left a comment

Choose a reason for hiding this comment

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

Thanks for the doc!

Is it normal that there is no doc related to create-strapi-app command?


Strapi Cloud comes with a Command Line Interface (CLI) which allows you to log in and out, and to deploy a project that is not hosted on a remote git repository. The CLI works with both the `yarn` and `npm` package managers.

The Cloud CLI is designed as a CLI-only experience, meaning that users who wish to use Strapi Cloud to deploy their project with the CLI will have to mostly stick to using the CLI (e.g. if you login with the CLI you must logout with the CLI as well, your project deployed with the CLI can only be redeployed with the CLI etc.).
Copy link
Contributor

Choose a reason for hiding this comment

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

ℹ️ It's only true for the first version of the CLI. We will need to change this line once we release the next iteration 🤞


**Alias:** `strapi cloud:deploy`

Deploy a new project (< 100MB), not already hosted on a remote git repository, in Strapi Cloud.
Copy link
Contributor

Choose a reason for hiding this comment

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

Hosted or not, it doesn't change anything. The user will deploy the local version of his project.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Would it make more sense to you @nathan-pichon if I change the sentence to "Deploy a new local project (< 100MB) in Strapi Cloud."? 🤔

Copy link
Contributor

Choose a reason for hiding this comment

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

I guess, yes 🤔

strapi deploy
```

This command must be used after the `login` one. It deploys a local Strapi project on Strapi Cloud, without having to host it on a remote git repository beforehand. The terminal will display a progress bar until the project is successfully deployed on Strapi Cloud.
Copy link
Contributor

Choose a reason for hiding this comment

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

The progress bar is only for uploading time, not for building time (and not for deploying time).
The deploy command work in 3 phases. First compression and upload of the project (progress bar). Then build time (user will get the logs according to the build phase). Then deploy time (user won't have the logs in CLI) that can be retrieve on Cloud Dashboard.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Alright, I'll remove the part about the progress bar then 🤓

Once the project is first deployed on Strapi Cloud with the CLI, the `deploy` command can be reused to trigger a new deployment of the same project.

:::caution
The `deploy` command can only be used by new users who have never created a Strapi Cloud project, and for which the free trial is still available. Once a project is deployed with the CLI, it isn't possible to deploy another project on the same Strapi Cloud account with the CLI.
Copy link
Contributor

Choose a reason for hiding this comment

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

ℹ️ It's only true for the first version of the CLI. 🤞

<TabItem value="npm" label="NPM">

```bash
npx run strapi login
Copy link
Collaborator

Choose a reason for hiding this comment

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

Suggested change
npx run strapi login
npm run strapi login

<TabItem value="npm" label="NPM">

```bash
npx run strapi deploy
Copy link
Collaborator

Choose a reason for hiding this comment

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

Suggested change
npx run strapi deploy
npm run strapi deploy

Double-checked with Alex for the commands :)

#2119)

* Update the Quick Start Guide to reflect new Cloud CLI behavior

* Update the CLI installation docs

* Add cross-link to QSG to CLI install. guide

* Update docusaurus/docs/dev-docs/quick-start.md

* Update docusaurus/docs/dev-docs/quick-start.md

* Update docusaurus/docs/dev-docs/quick-start.md

* Update docusaurus/docs/dev-docs/quick-start.md

* Update docusaurus/docs/dev-docs/installation/cli.md

Co-authored-by: Ben Irvin <[email protected]>

* Update docusaurus/docs/dev-docs/installation/cli.md

Co-authored-by: Ben Irvin <[email protected]>

* Update docusaurus/docs/dev-docs/quick-start.md

Co-authored-by: Ben Irvin <[email protected]>

* Update docusaurus/docs/dev-docs/quick-start.md

Co-authored-by: Ben Irvin <[email protected]>

* Update docusaurus/docs/dev-docs/installation/cli.md

* Update docusaurus/docs/dev-docs/installation/cli.md

* Update docusaurus/docs/dev-docs/installation/cli.md

* Update docusaurus/docs/dev-docs/installation/cli.md

* Update docusaurus/docs/dev-docs/installation/cli.md

* Update docusaurus/docs/dev-docs/installation/cli.md

* Update docusaurus/docs/dev-docs/installation/cli.md

* Update docusaurus/docs/dev-docs/quick-start.md

* Swap NPM & Yarn tabs order

* Shorten text

---------

Co-authored-by: Ben Irvin <[email protected]>
@pwizla pwizla added this to the 4.24.6 milestone Jun 12, 2024
@pwizla pwizla merged commit b90c8ac into main Jun 12, 2024
3 checks passed
@pwizla pwizla deleted the cloud/cli branch June 12, 2024 12:23
@pwizla pwizla added temp: port to v5 and removed flag: merge pending release Pending Strapi Release labels Jun 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
internal PRs created by the Strapi core team pr: new content PRs for new product features or new documentation sections source: Strapi Cloud PRs/issues targeting the Strapi Cloud documentation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants