diff --git a/docs/getting-started/assets/sync-with-gitlab/add-gitlab-org.png b/docs/getting-started/assets/sync-with-gitlab/add-gitlab-org.png new file mode 100644 index 00000000..dc4c6748 Binary files /dev/null and b/docs/getting-started/assets/sync-with-gitlab/add-gitlab-org.png differ diff --git a/docs/getting-started/assets/sync-with-gitlab/authorize-gitlab.png b/docs/getting-started/assets/sync-with-gitlab/authorize-gitlab.png new file mode 100644 index 00000000..6d5d75bc Binary files /dev/null and b/docs/getting-started/assets/sync-with-gitlab/authorize-gitlab.png differ diff --git a/docs/getting-started/assets/sync-with-gitlab/commit-and-build.png b/docs/getting-started/assets/sync-with-gitlab/commit-and-build.png new file mode 100644 index 00000000..8d5097c4 Binary files /dev/null and b/docs/getting-started/assets/sync-with-gitlab/commit-and-build.png differ diff --git a/docs/getting-started/assets/sync-with-gitlab/create-gitlab-repo.png b/docs/getting-started/assets/sync-with-gitlab/create-gitlab-repo.png new file mode 100644 index 00000000..99a6318a Binary files /dev/null and b/docs/getting-started/assets/sync-with-gitlab/create-gitlab-repo.png differ diff --git a/docs/getting-started/assets/sync-with-gitlab/merge-request.png b/docs/getting-started/assets/sync-with-gitlab/merge-request.png new file mode 100644 index 00000000..a1c42586 Binary files /dev/null and b/docs/getting-started/assets/sync-with-gitlab/merge-request.png differ diff --git a/docs/getting-started/assets/sync-with-gitlab/select-gitlab-repo.png b/docs/getting-started/assets/sync-with-gitlab/select-gitlab-repo.png new file mode 100644 index 00000000..740eece5 Binary files /dev/null and b/docs/getting-started/assets/sync-with-gitlab/select-gitlab-repo.png differ diff --git a/docs/getting-started/smart-git-sync.md b/docs/getting-started/smart-git-sync.md index 80f89570..58d368a1 100644 --- a/docs/getting-started/smart-git-sync.md +++ b/docs/getting-started/smart-git-sync.md @@ -26,7 +26,7 @@ The primary advantage of using Smart Git Sync is its ability to simplify the pro When you perform a new build on your Amplication project, Smart Git Sync automatically triggers the creation of a commit on the `amplication` branch. :::note -Amplication supports [GitHub](/sync-with-github), [Bitbucket](/sync-with-bitbucket), [AWS CodeCommit](/sync-with-aws-codecommit), and GitLab as git providers. +Amplication supports [GitHub](/sync-with-github), [Bitbucket](/sync-with-bitbucket), [AWS CodeCommit](/sync-with-aws-codecommit), and [GitLab](/sync-with-gitlab) as git providers. ::: This commit encompasses all the files that were added, removed, or changed since the last build. @@ -97,5 +97,6 @@ Smart Git Sync is a powerful feature that simplifies the integration between Amp Learn how to sync your service with your preferred git provider: - [Sync With GitHub](/sync-with-github) (Free, Enterprise) +- [Sync With GitLab](/sync-with-gitlab) (Enterprise) - [Sync With Bitbucket](/sync-with-bitbucket) (Enterprise) - [Sync With AWS CodeCommit](/sync-with-aws-codecommit) (Enterprise) \ No newline at end of file diff --git a/docs/getting-started/sync-with-gitlab.md b/docs/getting-started/sync-with-gitlab.md new file mode 100644 index 00000000..83fff87e --- /dev/null +++ b/docs/getting-started/sync-with-gitlab.md @@ -0,0 +1,96 @@ +--- +id: sync-with-gitlab +title: Sync with GitLab +sidebar_label: Sync with GitLab +slug: /sync-with-gitlab +toc_max_heading_level: 2 +--- + +# Sync with GitLab + +Amplication provides seamless integration with GitLab repositories, enabling automated code synchronization for your services. This integration allows you to maintain full control of your generated code with GitLab's version control features. + +## Add GitLab Organization + +Follow these steps to add your GitLab organization: + +1. Navigate to the [Service Catalog](/service-catalog) +2. Select the **Git Settings** tab +3. Click **Change Repository** if a repository is already connected +4. Open the **Select Git Organization** dropdown +5. Choose **Add Organization** +6. Select GitLab from the provider list + +![Add GitLab Org](./assets/sync-with-gitlab/add-gitlab-org.png) + +## Authorize GitLab Access + +When you select GitLab, you'll be redirected to GitLab's authorization page. Here you'll grant Amplication the necessary permissions to interact with your repositories. + +![Authorize GitLab](./assets/sync-with-gitlab/authorize-gitlab.png) + +## Configure Repository + +After authorization, you'll have two options for repository setup: + +### Option 1: Select Existing Repository + +Choose from your available GitLab repositories in the repository selection modal. + +![Select GitLab Repo](./assets/sync-with-gitlab/select-gitlab-repo.png) + +### Option 2: Create New Repository + +Click the "Create repository" button to set up a new GitLab repository. + +![Create GitLab Repo](./assets/sync-with-gitlab/create-gitlab-repo.png) + +## Service-Specific Repository Settings + +Amplication provides two levels of Git configuration: + +- **Project-level Git Settings**: Located in the Service Catalog's Git Settings tab, this controls the default repository settings for all services in your project +- **Service-level Git Settings**: Found within each individual service's settings, this allows you to override the project-level configuration for specific services when needed + +When you override the project settings for a service, that service will maintain its own independent Git configuration separate from the project defaults. + +To configure Git settings for a specific service: + +1. Access your service from the Service Catalog +2. Navigate to the service's Git Settings page +3. Toggle **Override project settings** +4. Follow the repository setup steps to configure a service-specific repository + +## Create Merge Requests + +To push your changes to GitLab: + +1. Make your desired changes in Amplication +2. Access the pending changes sidebar in your service catalog +3. Click "Generate the code" to initiate the build process + +![GitLab Merge Request](./assets/sync-with-gitlab/merge-request.png) + +## View Commits and Builds + +To track your changes: + +1. Go to your Service Catalog +2. Click on the Commits tab +3. View all your builds and their corresponding merge requests + +:::important +Do not delete the `amplication` branch. This branch is essential for Amplication's synchronization process. +::: + +![Create GitLab Repo](./assets/sync-with-gitlab/commit-and-build.png) + +## Next Steps + +Learn more about Amplication's Git integration features: + +- Branch management strategies +- Merge request workflows +- Conflict resolution + +Visit our [Smart Git Sync](/smart-git-sync) documentation for detailed information. \ No newline at end of file diff --git a/sidebars.js b/sidebars.js index 45a8cc3a..1c3eec48 100644 --- a/sidebars.js +++ b/sidebars.js @@ -77,6 +77,7 @@ const sidebars = { items: [ "getting-started/smart-git-sync", "getting-started/sync-with-github", + "getting-started/sync-with-gitlab", "getting-started/sync-with-bitbucket", "getting-started/sync-with-aws-codecommit", // "getting-started/sync-with-git-differences-between-plans",