snapctl 1.0.3__py3-none-any.whl → 1.1.0__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of snapctl might be problematic. Click here for more details.

@@ -3,7 +3,7 @@ Constants used by snapctl
3
3
  """
4
4
  COMPANY_NAME = 'Snapser'
5
5
  VERSION_PREFIX = ''
6
- VERSION = '1.0.3'
6
+ VERSION = '1.1.0'
7
7
  CONFIG_FILE_MAC = '~/.snapser/config'
8
8
  CONFIG_FILE_WIN = '%homepath%\\.snapser\\config'
9
9
 
@@ -25,7 +25,9 @@ HTTP_CONFLICT = 409
25
25
 
26
26
  # HTTP Error codes
27
27
  HTTP_ERROR_GAME_LIMIT_REACHED = 520
28
+ HTTP_ERROR_GAME_NOT_FOUND = 521
28
29
  HTTP_ERROR_DUPLICATE_GAME_NAME = 523
30
+ HTTP_ERROR_CLUSTER_UPDATE_IN_PROGRESS = 535
29
31
  HTTP_ERROR_RESOURCE_NOT_FOUND = 541
30
32
  HTTP_ERROR_SERVICE_VERSION_EXISTS = 542
31
33
  HTTP_ERROR_SERVICE_IN_USE = 543
@@ -38,12 +40,22 @@ SNAPCTL_SUCCESS = 0
38
40
  SNAPCTL_ERROR = 1
39
41
  SNAPCTL_INPUT_ERROR = 2
40
42
  SNAPCTL_RESOURCE_NOT_FOUND = 3
43
+ SNAPCTL_INTERNAL_SERVER_ERROR = 4
41
44
 
42
- # Configuration Errors - 10 - 19
45
+ # Configuration Errors - 10 - 12
43
46
  SNAPCTL_CONFIGURATION_INCORRECT = 10
44
47
  SNAPCTL_CONFIGURATION_ERROR = 11
45
48
  SNAPCTL_DEPENDENCY_MISSING = 12
46
49
 
50
+ # Snaps Errors - 13 - 15
51
+ SNAPCTL_SNAPS_GENERIC_ERROR = 13
52
+ SNAPCTL_SNAPS_ENUMERATE_ERROR = 14
53
+
54
+ # Snapend Manifest Errors - 16 - 19
55
+ SNAPCTL_SNAPEND_MANIFEST_CREATE_ERROR = 16
56
+ SNAPCTL_SNAPEND_MANIFEST_UPDATE_ERROR = 17
57
+ SNAPCTL_SNAPEND_MANIFEST_UPGRADE_ERROR = 18
58
+
47
59
  # BYOGS Errors - 20 - 29
48
60
  SNAPCTL_BYOGS_GENERIC_ERROR = 20
49
61
  SNAPCTL_BYOGS_DEPENDENCY_MISSING = 21
@@ -108,6 +120,10 @@ SNAPCTL_SNAPEND_UPDATE_SERVER_ERROR = 73
108
120
  SNAPCTL_SNAPEND_UPDATE_TIMEOUT_ERROR = 74
109
121
  SNAPCTL_SNAPEND_STATE_ERROR = 75
110
122
  SNAPCTL_SNAPEND_APPLY_MANIFEST_MISMATCH_ERROR = 76
123
+ SNAPCTL_SNAPEND_CREATE_ERROR = 77
124
+ SNAPCTL_SNAPEND_CREATE_SERVER_ERROR = 78
125
+ SNAPCTL_SNAPEND_CREATE_TIMEOUT_ERROR = 79
126
+
111
127
 
112
128
  # Generate Errors - 80 - 85
113
129
  SNAPCTL_GENERATE_GENERIC_ERROR = 80
@@ -1,5 +1,4 @@
1
1
  ## Release 1.0.3
2
2
  ##### Sept 22, 2025
3
3
 
4
- ### Breaking Change
5
- 1. BYOSnap and BYOGs publishes will be stopped once you hit the limit of 500 images. You can still publish more images by deleting older images from the Snapser Web app.
4
+ 1. Byosnap and byogs upload now forces a single platform image instead of multiple images with an image index.
@@ -0,0 +1,5 @@
1
+ ## Release 1.0.4
2
+ ##### Sept 25, 2025
3
+
4
+ ## Bug Fixes
5
+ 1. BYOWS was outputting an incorrect environment variable names for snaps with hyphens in their IDs. This has been fixed to replace hyphens with underscores in the environment variable names.
@@ -0,0 +1,20 @@
1
+ ## Release 1.1.0
2
+ ##### Oct 13, 2025
3
+
4
+ ### Deprecation Notice
5
+ 1. The `Snapend` command now accepts `--application-id` for consistency with the web app. The `--game-id` parameter is still supported but will be removed in future releases.
6
+ 2. The `Game` command has been renamed to `Application`. The old command is still supported but will be removed in future releases. Please use `snapctl application` instead of `snapctl game`.
7
+
8
+ ### New Features
9
+ #### Snapend command
10
+ - Added a new `snapend create` command to create a new Snapend instance using a manifest file.
11
+
12
+ #### Snaps command
13
+ - Added a new `snaps enumerate` command to get a list of all available snaps for your organization, including all the metadata and dependencies.
14
+
15
+ #### Snapend Manifest commands
16
+ - We have added a new command `snapend-manifest` that enables you to create CI/CD pipelines for your Snapend manifests. The command supports the following subcommands:
17
+ - `create`: Allows you to create a brand new manifest file by telling the command which snaps you want to include.
18
+ - `update`: Tells the snapctl to update your manifest file with a set of snaps and features. These are synced with the manifest file you pass.
19
+ - `upgrade`: Tells snapctl to upgrade all the snaps in the manifest or selected snaps to their latest versions.
20
+
snapctl/main.py CHANGED
@@ -8,12 +8,15 @@ from typing import Union
8
8
  import typer
9
9
  import pyfiglet
10
10
 
11
+ from snapctl.commands.application import Application
11
12
  from snapctl.commands.byosnap import ByoSnap
12
13
  from snapctl.commands.byogs import ByoGs
13
14
  from snapctl.commands.game import Game
14
15
  from snapctl.commands.generate import Generate
15
16
  from snapctl.commands.snapend import Snapend
16
17
  from snapctl.commands.byows import Byows
18
+ from snapctl.commands.snaps import Snaps
19
+ from snapctl.commands.snapend_manifest import SnapendManifest
17
20
  from snapctl.commands.release_notes import ReleaseNotes
18
21
  from snapctl.config.constants import COMPANY_NAME, API_KEY, URL_KEY, CONFIG_FILE_MAC, \
19
22
  CONFIG_FILE_WIN, DEFAULT_PROFILE, VERSION, SNAPCTL_SUCCESS, CONFIG_PATH_KEY, \
@@ -21,7 +24,7 @@ from snapctl.config.constants import COMPANY_NAME, API_KEY, URL_KEY, CONFIG_FILE
21
24
  from snapctl.config.endpoints import END_POINTS, GATEWAY_END_POINTS
22
25
  from snapctl.config.hashes import PROTOS_TYPES, SERVICE_IDS, \
23
26
  SNAPEND_MANIFEST_TYPES, SDK_TYPES
24
- from snapctl.utils.echo import error, success, info
27
+ from snapctl.utils.echo import error, success, info, warning
25
28
  from snapctl.utils.helper import validate_api_key
26
29
  from snapctl.utils.telemetry import telemetry
27
30
 
@@ -504,8 +507,10 @@ def game(
504
507
  ),
505
508
  ) -> None:
506
509
  """
507
- Game commands
510
+ Game commands - DEPRECATED: Use Application commands instead
508
511
  """
512
+ warning(
513
+ "Game commands have been deprecated. Please use Application commands instead.")
509
514
  validate_command_context(ctx)
510
515
  game_obj: Game = Game(
511
516
  subcommand=subcommand,
@@ -518,6 +523,42 @@ def game(
518
523
  raise typer.Exit(code=SNAPCTL_SUCCESS)
519
524
 
520
525
 
526
+ @app.command()
527
+ @telemetry("application", subcommand_arg="subcommand")
528
+ def application(
529
+ ctx: typer.Context,
530
+ # Required fields
531
+ subcommand: str = typer.Argument(
532
+ ..., help="Application Subcommands: " + ", ".join(Application.SUBCOMMANDS) + "."
533
+ ),
534
+ # name
535
+ name: str = typer.Option(
536
+ None, "--name",
537
+ help=("(req: create) Name of your application: ")
538
+ ),
539
+ # overrides
540
+ api_key: Union[str, None] = typer.Option(
541
+ None, "--api-key", help="API Key override.", callback=api_key_context_callback
542
+ ),
543
+ profile: Union[str, None] = typer.Option(
544
+ None, "--profile", help="Profile from the Snapser config to use.", callback=profile_context_callback
545
+ ),
546
+ ) -> None:
547
+ """
548
+ Application commands
549
+ """
550
+ validate_command_context(ctx)
551
+ application_obj: Application = Application(
552
+ subcommand=subcommand,
553
+ base_url=ctx.obj['base_url'],
554
+ api_key=ctx.obj['api_key'],
555
+ name=name
556
+ )
557
+ getattr(application_obj, subcommand.replace('-', '_'))()
558
+ success(f"Application {subcommand} complete")
559
+ raise typer.Exit(code=SNAPCTL_SUCCESS)
560
+
561
+
521
562
  @app.command()
522
563
  @telemetry("generate", subcommand_arg="subcommand")
523
564
  def generate(
@@ -581,12 +622,16 @@ def snapend(
581
622
  # enumerate
582
623
  game_id: str = typer.Option(
583
624
  None, "--game-id",
584
- help="(req: enumerate, clone) Game Id"
625
+ help="(DEPRECATED: Use --application-id instead) Game Id"
626
+ ),
627
+ application_id: str = typer.Option(
628
+ None, "--application-id",
629
+ help="(req: enumerate, create, clone) Application Id"
585
630
  ),
586
631
  # apply, clone
587
632
  manifest_path_filename: str = typer.Option(
588
633
  None, "--manifest-path-filename",
589
- help="(req: apply|clone) Full Path to the manifest file including the filename."
634
+ help="(req: create|apply|clone) Full Path to the manifest file including the filename."
590
635
  ),
591
636
  force: bool = typer.Option(
592
637
  False, "--force",
@@ -627,7 +672,7 @@ def snapend(
627
672
  "--http-lib " + Snapend.get_http_formats_str()
628
673
  )
629
674
  ),
630
- snaps: Union[str, None] = typer.Option(
675
+ snaps_list_str: Union[str, None] = typer.Option(
631
676
  None, "--snaps",
632
677
  help=(
633
678
  "(optional: download) Comma separated list of snap ids to customize the "
@@ -637,15 +682,15 @@ def snapend(
637
682
  ),
638
683
  # Clone
639
684
  name: Union[str, None] = typer.Option(
640
- None, "--name", help="(req: clone) Snapend name"),
685
+ None, "--name", help="(req: clone, optional: create) Snapend name"),
641
686
  env: Union[str, None] = typer.Option(
642
687
  None, "--env", help=(
643
- "(req: clone) Snapend environment"
688
+ "(req: clone, optional: create) Snapend environment"
644
689
  "Environments: (" + ", ".join(Snapend.ENV_TYPES) + ")"
645
690
  )),
646
691
  # Download, Apply, Clone
647
692
  out_path: Union[str, None] = typer.Option(
648
- None, "--out-path", help="(optional: download|apply|clone) Path to save the output file"),
693
+ None, "--out-path", help="(optional: create|download|apply|clone) Path to save the output file"),
649
694
  # update
650
695
  byosnaps_list: str = typer.Option(
651
696
  None, "--byosnaps",
@@ -687,7 +732,7 @@ def snapend(
687
732
  api_key=ctx.obj['api_key'],
688
733
  snapend_id=snapend_id,
689
734
  # Enumerate, Clone
690
- game_id=game_id,
735
+ game_id=application_id if application_id is not None else game_id,
691
736
  # Clone
692
737
  name=name, env=env,
693
738
  # Apply, Clone
@@ -698,7 +743,7 @@ def snapend(
698
743
  category_format=category_format,
699
744
  category_type=category_type,
700
745
  category_http_lib=category_http_lib,
701
- snaps=snaps,
746
+ snaps=snaps_list_str,
702
747
  # Download, Apply and Clone
703
748
  out_path=out_path,
704
749
  # Update
@@ -759,3 +804,105 @@ def byows(
759
804
  getattr(byows_obj, subcommand.replace('-', '_'))()
760
805
  success(f"BYOWs {subcommand} complete")
761
806
  raise typer.Exit(code=SNAPCTL_SUCCESS)
807
+
808
+
809
+ @app.command()
810
+ @telemetry("snaps", subcommand_arg="subcommand")
811
+ def snaps(
812
+ ctx: typer.Context,
813
+ # Required fields
814
+ subcommand: str = typer.Argument(
815
+ ..., help="Snaps Subcommands: " + ", ".join(Snaps.SUBCOMMANDS) + "."
816
+ ),
817
+ out_path_filename: Union[str, None] = typer.Option(
818
+ None, "--out-path-filename", help=(
819
+ "(optional: enumerate) Path and filename to output the snaps list. The filename should end with .json."
820
+ )
821
+ ),
822
+ # overrides
823
+ api_key: Union[str, None] = typer.Option(
824
+ None, "--api-key", help="API Key override.", callback=api_key_context_callback
825
+ ),
826
+ profile: Union[str, None] = typer.Option(
827
+ None, "--profile", help="Profile from the Snapser config to use.", callback=profile_context_callback
828
+ ),
829
+ ) -> None:
830
+ """
831
+ Bring your own workstation commands
832
+ """
833
+ validate_command_context(ctx)
834
+ snaps_obj: Snaps = Snaps(
835
+ subcommand=subcommand,
836
+ base_url=ctx.obj['base_url'],
837
+ api_key=ctx.obj['api_key'],
838
+ out_path_filename=out_path_filename,
839
+ )
840
+ getattr(snaps_obj, subcommand.replace('-', '_'))()
841
+ success(f"Snaps {subcommand} complete")
842
+ raise typer.Exit(code=SNAPCTL_SUCCESS)
843
+
844
+
845
+ @app.command()
846
+ @telemetry("snapend_manifest", subcommand_arg="subcommand")
847
+ def snapend_manifest(
848
+ ctx: typer.Context,
849
+ # Required fields
850
+ subcommand: str = typer.Argument(
851
+ ..., help="Snapend Manifest Subcommands: " + ", ".join(SnapendManifest.SUBCOMMANDS) + "."
852
+ ),
853
+ name: Union[str, None] = typer.Option(
854
+ None, "--name", help="(req: create) Name for your snapend."
855
+ ),
856
+ env: Union[str, None] = typer.Option(
857
+ None, "--env", help=(
858
+ "(req: create) Environment for your snapend - " +
859
+ ", ".join(SnapendManifest.ENVIRONMENTS) + "."
860
+ )
861
+ ),
862
+ manifest_path_filename: Union[str, None] = typer.Option(
863
+ None, "--manifest-path-filename", help=(
864
+ "(req: update, upgrade) Full Path to the manifest file including the filename."
865
+ )
866
+ ),
867
+ snaps_list_str: str = typer.Option(
868
+ None, "--snaps", help=(
869
+ "(use: create, update, upgrade) Comma separated list of snap ids to add, update or upgrade. "
870
+ )
871
+ ),
872
+ features: str = typer.Option(
873
+ None, "--features", help=(
874
+ "(use: create, update) Comma separated list of feature flags to add, update. "
875
+ "Features: " + ", ".join(SnapendManifest.FEATURES)
876
+ )
877
+ ),
878
+ out_path_filename: Union[str, None] = typer.Option(
879
+ None, "--out-path-filename", help=(
880
+ "(optional: enumerate) Path and filename to output the manifest. The filename should end with .json or .yaml"
881
+ )
882
+ ),
883
+ # overrides
884
+ api_key: Union[str, None] = typer.Option(
885
+ None, "--api-key", help="API Key override.", callback=api_key_context_callback
886
+ ),
887
+ profile: Union[str, None] = typer.Option(
888
+ None, "--profile", help="Profile from the Snapser config to use.", callback=profile_context_callback
889
+ ),
890
+ ) -> None:
891
+ """
892
+ Bring your own workstation commands
893
+ """
894
+ validate_command_context(ctx)
895
+ snapend_manifest_obj: SnapendManifest = SnapendManifest(
896
+ subcommand=subcommand,
897
+ base_url=ctx.obj['base_url'],
898
+ api_key=ctx.obj['api_key'],
899
+ name=name,
900
+ environment=env,
901
+ manifest_path_filename=manifest_path_filename,
902
+ snaps=snaps_list_str,
903
+ features=features,
904
+ out_path_filename=out_path_filename,
905
+ )
906
+ getattr(snapend_manifest_obj, subcommand.replace('-', '_'))()
907
+ success(f"Snapend Manifest {subcommand} complete")
908
+ raise typer.Exit(code=SNAPCTL_SUCCESS)
@@ -0,0 +1,8 @@
1
+ '''
2
+ Exceptions used in snapctl.
3
+ '''
4
+
5
+
6
+ class SnapendDownloadException(Exception):
7
+ """Raised when a Snapend download fails or is incomplete."""
8
+ pass
snapctl/utils/helper.py CHANGED
@@ -49,7 +49,8 @@ def validate_api_key(base_url: str, api_key: Union[str, None]) -> bool:
49
49
  raise typer.Exit(code=SNAPCTL_CONFIGURATION_ERROR)
50
50
 
51
51
 
52
- def get_composite_token(base_url: str, api_key: Union[str, None], action: str, params: object) -> str:
52
+ def get_composite_token(
53
+ base_url: str, api_key: Union[str, None], action: str, params: object) -> str:
53
54
  """
54
55
  This function exchanges the api_key for a composite token.
55
56
  """
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: snapctl
3
- Version: 1.0.3
3
+ Version: 1.1.0
4
4
  Summary: Snapser CLI Tool
5
5
  Author: Ajinkya Apte
6
6
  Author-email: aj@snapser.com
@@ -232,7 +232,27 @@ Run the following to see the list of commands Snapser supports
232
232
  snapctl --help
233
233
  ```
234
234
 
235
- ### BYO Snap - Bring your own Snap
235
+ ### 1. Snaps
236
+ Snapctl commands for snaps
237
+
238
+ #### 1. snaps help
239
+ See all the supported commands.
240
+
241
+ ```bash
242
+ # Help for the byosnap command
243
+ snapctl snaps --help
244
+ ```
245
+
246
+ #### 2. snaps enumerate
247
+ See all the supported commands.
248
+
249
+ ```bash
250
+ # Enumerate details for all the available snaps
251
+ # $output_path = Optional path to where you want snapctl to save snap details
252
+ snapctl snaps enumerate --out-path
253
+ ```
254
+
255
+ ### 2. BYO Snap - Bring your own Snap
236
256
  Snapctl commands for your custom code
237
257
 
238
258
  #### 1. byosnap help
@@ -463,7 +483,7 @@ snapctl byosnap publish-version --help
463
483
  snapctl byosnap publish-version --byosnap-id $byosnap_id --tag $image_tag --version $version --path $byosnap_profile_path
464
484
  ```
465
485
 
466
- ### BYO Workstation - Bring your own Workstation
486
+ ### 3. BYO Workstation - Bring your own Workstation
467
487
  Snapctl commands for bring your own workstation. This command allows you to attach your workstation to a Snapend. This is useful for testing and debugging your BYOSnap code.
468
488
 
469
489
  #### 1. byows help
@@ -494,7 +514,7 @@ source ~/.snapser/byows_env_setup.sh
494
514
 
495
515
  Then start your BYOSnap local server in the same tab that has the environment variables set up. This will ensure that the BYOSnap code can access the internal SDK and other Snaps in your Snapend.
496
516
 
497
- ### BYO Game Server - Bring your own Game Server
517
+ ### 4. BYO Game Server - Bring your own Game Server
498
518
  Snapctl commands for your custom game server
499
519
 
500
520
  #### 1. byogs help
@@ -582,32 +602,99 @@ snapctl byogs push --help
582
602
  snapctl byogs push --tag $image_tag
583
603
  ```
584
604
 
605
+ ### 5. Application
606
+ Snapctl commands for your application
585
607
 
586
- ### Game
587
- Snapctl commands for your game
608
+ #### 1. application help
588
609
 
589
- #### 1. game help
610
+ See all the supported commands
611
+
612
+ ```bash
613
+ # Help for the byogs command
614
+ snapctl application --help
615
+ ```
616
+
617
+ #### 2. application create
618
+ Create an application
619
+ ```bash
620
+ snapctl application create --name $app_name
621
+ ```
622
+
623
+ #### 3. application enumerate
624
+ List all the applications
625
+ ```bash
626
+ snapctl application enumerate
627
+ ```
628
+
629
+ ### 6. Snapend Manifest
630
+ Snapctl commands for the Snapend manifest. Manifest is the representation of your Snapser backend
631
+ stored as a JSON or YAML. The manifest can then be used to create, update your backend.
632
+
633
+ #### 1. snapend-manifest help
590
634
 
591
635
  See all the supported commands
592
636
 
593
637
  ```bash
594
638
  # Help for the byogs command
595
- snapctl game --help
639
+ snapctl snapend-manifest --help
596
640
  ```
597
641
 
598
- #### 2. game create
599
- Create a game
642
+ #### 2. Snapend Manifest Create
643
+
644
+ Create a Snapend manifest. The output manifest file can then be used with the `snapend create` or `snapend clone` commands.
645
+
600
646
  ```bash
601
- snapctl game create --name $game_name
647
+ # Create a Snapend manifest file
648
+ # $name = Name for your backend, which is stored in the outputted manifest
649
+ # $env = One of DEVELOPMENT, STAGING or PRODUCTION
650
+ # $output_path_filename = Path and file name to store the manifest. The filename should end with .json or .yaml
651
+ # $snaps = Comma separated list of snap ids you want to add. You can get the snap ids from the
652
+ # `snapctl snaps enumerate --out-path ./snaps.json` command
653
+ # $features = Pass `WEB_SOCKETS` if you want to enable web sockets for your backend.
654
+ # Note: One of snaps or features is required
655
+ # Example:
656
+ # snapend-manifest create --name my-dev-snapend --env DEVELOPMENT --snaps auth,analytics --add-features WEB_SOCKETS --out-path ./snapend-manifest.json
657
+ snapctl snapend-manifest create --name $name$ --env $env$ --snaps $snaps --features $features --out-path-filename $output_path_filename
602
658
  ```
603
659
 
604
- #### 3. game enumerate
605
- List all the games
660
+ #### 3. Snapend Manifest Update
661
+
662
+ Update an existing Snapend manifest.
663
+
606
664
  ```bash
607
- snapctl game enumerate
665
+ # Update a Snapend manifest file
666
+ # $input_manifest = Path and file name of the current manifest. The filename should end with .json or .yaml
667
+ # $output_path_filename = Path and file name to store the manifest. The filename should end with .json or .yaml
668
+ # $snaps = Comma separated list of snap ids you want to have at the end. You can get the snap ids from # the `snapctl snaps enumerate --out-path ./snaps.json` command.
669
+ # IMPORTANT: If your manifest has a snap but your --snaps does not. It will be removed.
670
+ # $features = Pass `WEB_SOCKETS` if you want to enable web sockets for your backend.
671
+ # IMPORTANT: If your manifest has a feature but your --features does not. It will be removed.
672
+ # Note: One of snaps, and features is required
673
+ # Example:
674
+ # snapctl snapend-manifest update --manifest-path-filename ./snapser-jn86b0dv-manifest.yaml --add-snaps game-server-fleets --remove-snaps analytics --remove-features WEB_SOCKETS --out-path ./snapend-updated-manifest.yaml
675
+
676
+ snapctl snapend-manifest update --manifest-path-filename $input_manifest --snaps $snaps --features $features--out-path-filename $output_path_filename
608
677
  ```
609
678
 
610
- ### Snapend
679
+ #### 4. Snapend Manifest Upgrade
680
+
681
+ Upgrade all snaps or a list of snaps to the latest version
682
+
683
+ ```bash
684
+ # Update a Snapend manifest file
685
+ # $input_manifest = Path and file name of the current manifest. The filename should end with .json or .yaml
686
+ # $output_path_filename = Path and file name to store the manifest. The filename should end with .json or .yaml
687
+ # $snaps = (Optional) Comma separated list of snap ids you want to upgrade. You can get the snap ids
688
+ # from the `snapctl snaps enumerate --out-path ./snaps.json` command
689
+ # IMPORTANT: If the --snaps parameter is not provided then all snaps in the manifest will be upgraded
690
+ # Example:
691
+ # snapctl snapend-manifest upgrade --manifest-path-filename ./snapser-jn86b0dv-manifest.yaml --snaps game-server-fleets --out-path ./snapend-updated-manifest.yaml
692
+ # snapctl snapend-manifest upgrade --manifest-path-filename ./snapser-jn86b0dv-manifest.yaml --out-path ./snapend-updated-manifest.yaml
693
+
694
+ snapctl snapend-manifest upgrade --manifest-path-filename $input_manifest --snaps $snaps --out-path-filename $output_path_filename
695
+ ```
696
+
697
+ ### 7. Snapend
611
698
  Snapctl commands for your snapend
612
699
 
613
700
  #### 1. snapend help
@@ -653,7 +740,26 @@ snapctl snapend download --snapend-id $snapend_id --category $category --format
653
740
  snapctl snapend download --snapend-id $snapend_id --category $category --format $format --type $type --http-lib $http_lib --out-path $out_path
654
741
  ```
655
742
 
656
- #### 3. snapend clone
743
+ #### 3. snapend create
744
+
745
+ Create a Snapend from an existing manifest. Passing the blocking flag ensures your CLI command waits till the new Snapend is up.
746
+
747
+ ```bash
748
+ # Help for the crete command
749
+ snapctl snapend create --help
750
+
751
+ # Create a Snapend
752
+ # $app_id = App Id
753
+ # $path_to_manifest = Path to the manifest file; should include the file name
754
+ # Optionally override name and environment by passing the --name and --environment overrides
755
+ # Example:
756
+ # snapctl snapend create --manifest-path-filename $path_to_manifest --app-id $app_id --blocking
757
+ snapctl snapend create --manifest-path-filename $path_to_manifest --app-id $app_id
758
+ snapctl snapend create --manifest-path-filename $path_to_manifest --app-id $app_id --blocking
759
+ snapctl snapend create --name $name --env $env --manifest-path-filename $path_to_manifest --app-id $app_id --blocking
760
+ ```
761
+
762
+ #### 4. snapend clone
657
763
 
658
764
  Clone a Snapend from an existing manifest. Passing the blocking flag ensures your CLI command waits till the new Snapend is up.
659
765
 
@@ -662,17 +768,17 @@ Clone a Snapend from an existing manifest. Passing the blocking flag ensures you
662
768
  snapctl snapend clone --help
663
769
 
664
770
  # Clone your Snapend
665
- # $game_id = Game Id
771
+ # $app_id = App Id
666
772
  # $snapend_name = Name of your new Snapend
667
773
  # $env = One of development, staging
668
774
  # $path_to_manifest = Path to the manifest file; should include the file name
669
775
  # Example:
670
- # snapctl snapend clone --game-id 2581d802-aca-496c-8a76-1953ad0db165 --name new-snapend --env development --manifest-path-filename "C:\Users\name\Downloads\snapser-ox1bcyim-manifest.json" --blocking
671
- snapctl snapend clone --game-id $game_id --name $snapend_name --env $env --manifest-path-filename "$path_to_manifest"
672
- snapctl snapend clone --game-id $game_id --name $snapend_name --env $env --manifest-path-filename "$path_to_manifest" --blocking
776
+ # snapctl snapend clone --app-id 2581d802-aca-496c-8a76-1953ad0db165 --name new-snapend --env development --manifest-path-filename "C:\Users\name\Downloads\snapser-ox1bcyim-manifest.json" --blocking
777
+ snapctl snapend clone --app-id $app_id --name $snapend_name --env $env --manifest-path-filename "$path_to_manifest"
778
+ snapctl snapend clone --app-id $app_id --name $snapend_name --env $env --manifest-path-filename "$path_to_manifest" --blocking
673
779
  ```
674
780
 
675
- #### 4. snapend apply
781
+ #### 5. snapend apply
676
782
 
677
783
  Apply changes to your Snapend from a manifest. You should have the latest manifest before applying changes. Basically, when you download a manifest, Snapser adds an `applied_configuration` section to your manifest, which stores the state of the Snapend during export. Now, if someone manually updates the Snapend or a configuration of a Snap, you are no longer going to have the latest Snapend representation in the `applied_configuration`. This is how Snapser prevents you from stomping over someone elses changes.
678
784
 
@@ -695,7 +801,7 @@ snapctl snapend apply --manifest-path-filename "$path_to_manifest" --blocking
695
801
  snapctl snapend apply --manifest-path-filename "$path_to_manifest" --force --blocking
696
802
  ```
697
803
 
698
- #### 5. snapend update
804
+ #### 6. snapend update
699
805
 
700
806
  Update your BYOSnap or BYOGs versions for the Snapend
701
807
 
@@ -715,7 +821,7 @@ snapctl snapend update --help
715
821
  snapctl snapend update --snapend-id $snapend_id --byosnaps $byosnaps --byogs $byogs --blocking
716
822
  ```
717
823
 
718
- #### 6. snapend state
824
+ #### 7. snapend state
719
825
 
720
826
  Get the Snapend state
721
827
 
@@ -730,7 +836,7 @@ snapctl snapend state --help
730
836
  snapctl snapend state $snapend_id
731
837
  ```
732
838
 
733
- ### Generate
839
+ ### 8. Generate
734
840
  Generator tool to help generate credentials
735
841
 
736
842
  #### 1. generate help
@@ -757,6 +863,7 @@ snapctl generate credentials --category "ecr" --out-path $output_path
757
863
  | 1 | General error |
758
864
  | 2 | Input error |
759
865
  | 3 | Resource not found |
866
+ | 4 | Internal server error |
760
867
 
761
868
  ### Configuration Errors
762
869
  | Error Code | Description |
@@ -765,10 +872,23 @@ snapctl generate credentials --category "ecr" --out-path $output_path
765
872
  | 11 | Configuration error |
766
873
  | 12 | Dependency missing |
767
874
 
875
+ ### Snaps Errors
876
+ | Error Code | Description |
877
+ |------------|----------------------------------------------------------|
878
+ | 13 | Snaps Generic error |
879
+ | 14 | Snaps Enumerate error |
880
+
881
+ ### Snapend Manifest Errors
882
+ | Error Code | Description |
883
+ |------------|----------------------------------------------------------|
884
+ | 16 | Snapend Manifest create error |
885
+ | 17 | Snapend Manifest update error |
886
+ | 18 | Snapend Manifest upgrade error |
887
+
768
888
  ### BYOGS Errors
769
889
  | Error Code | Description |
770
890
  |------------|----------------------------------------------------------|
771
- | 3 | BYOGs resource not found |
891
+ | 3 | Resource not found: BYOGs resource not found |
772
892
  | 20 | Generic BYOGS error |
773
893
  | 21 | BYOGS dependency missing |
774
894
  | 22 | BYOGS ECR login error |
@@ -781,7 +901,7 @@ snapctl generate credentials --category "ecr" --out-path $output_path
781
901
  ### BYOSNAP Errors
782
902
  | Error Code | Description |
783
903
  |------------|----------------------------------------------------------|
784
- | 3 | BYOSnap resource not found |
904
+ | 3 | Resource not found: BYOSnap resource not found |
785
905
  | 30 | Generic BYOSNAP error |
786
906
  | 31 | BYOSNAP dependency missing |
787
907
  | 32 | BYOSNAP ECR login error |
@@ -806,21 +926,21 @@ snapctl generate credentials --category "ecr" --out-path $output_path
806
926
  | 87 | BYOSNAP swagger error |
807
927
 
808
928
 
809
- ### Game Errors
929
+ ### Application Errors
810
930
  | Error Code | Description |
811
931
  |------------|----------------------------------------------------------|
812
- | 3 | Game resource not found |
813
- | 50 | Generic game error |
814
- | 51 | Game create error |
815
- | 52 | Game create permission error |
816
- | 53 | Game create limit error |
817
- | 54 | Game create duplicate name error |
818
- | 55 | Game enumerate error |
932
+ | 3 | Resource not found: Application resource not found |
933
+ | 50 | Generic application error |
934
+ | 51 | Application create error |
935
+ | 52 | Application create permission error |
936
+ | 53 | Application create limit error |
937
+ | 54 | Application create duplicate name error |
938
+ | 55 | Application enumerate error |
819
939
 
820
940
  ### Snapend Errors
821
941
  | Error Code | Description |
822
942
  |------------|----------------------------------------------------------|
823
- | 3 | Snapend resource not found |
943
+ | 3 | Resource not found: Snapend resource not found |
824
944
  | 60 | Generic snapend error |
825
945
  | 61 | Snapend enumerate error |
826
946
  | 62 | Snapend clone error |
@@ -838,6 +958,9 @@ snapctl generate credentials --category "ecr" --out-path $output_path
838
958
  | 74 | Snapend update timeout error |
839
959
  | 75 | Snapend state error |
840
960
  | 76 | Snapend manifest mismatch error |
961
+ | 77 | Snapend create error |
962
+ | 78 | Snapend create server error |
963
+ | 79 | Snapend create timeout error |
841
964
 
842
965
  ### Generate Errors
843
966
  | Error Code | Description |