Package: one-cli
one-cliCLI to manage all stacks from DNX.Quick startDownload the latest release with the command.curl -sSL https://raw.githubusercontent.com/DNXLabs/one-cli/master/get_one.sh | bashTest to ensure the version you installed is up-to-date.one --versionInstall shell completion (Optional)curl -sSL https://raw.githubusercontent.com/DNXLabs/one-cli/master/shell_completion.py | python3Install specific versionexportONE_VERSION=<version># Linuxsudocurl-Lhttps://github.com/DNXLabs/one-cli/releases/download/$ONE_VERSION/one_linux_amd64-o/usr/local/bin/one# Macossudocurl-Lhttps://github.com/DNXLabs/one-cli/releases/download/$ONE_VERSION/one_macos_amd64-o/usr/local/bin/one

sudochmod+x/usr/local/bin/oneInstall with PyPiPyPI Projectpip3installone-cli# or setting a versionpip3installone-cli==<version>CI/CD pipelines with DockerTo use the CLI within any CI/CD pipeline we encourage to use our docker image:dnxsolutions/one-cliWARNING: This docker image should only be used inside CI/CD pipelines and it can generate error if used as an alias.UsageUsage: one [OPTIONS] COMMAND [ARGS]...

  CLI to manage all stacks from DNX.

Options:
  --version  Show the version and exit.
  --help     Show this message and exit.

Commands:
  app        Group of app commands wrapped inside docker.
  auth       Group of auth commands.
  aws        AWS CLI alias.
  aws-v2     AWS v2 CLI alias.
  init       Create config file for CLI in current directory.
  terraform  Group of terraform commands wrapped inside docker.
  workspace  Manage workspaces.Configuration Exampleone.yamlimages:terraform:dnxsolutions/terraform:0.13.0-dnx1gsuite:dnxsolutions/aws-google-auth:latestazure:dnxsolutions/docker-aws-azure-ad:latestaws:dnxsolutions/aws:1.18.44-dnx2aws_2:dnxsolutions/aws:2.0.37-dnx1ecs_deploy:dnxsolutions/ecs-deploy:1.2.0required_version:">=0.5.0,<=0.7.0"# ECS Appapp:name:copacabanaport:80docker:file:Dockerfileimage_name:copacabanaregistry_type:ecrregistry_options:ecr_aws_account_id:<redact>ecr_aws_region:ap-southeast-2ecr_aws_assume_role:trueecr_aws_role:<redact>ecs_task_definition_file:task-definition.tpl.json# Static Appapp:type:staticsrc:./builds3_bucket_name:<redact>distribution_id:<redact>workspaces:# ECS App example:mgmt_ecs_app:type:ecsaws:account_id:<redact>role:<redact>assume_role:true|false (default to false)region:ap-southeast-2ecs_cluster_name:cluster-01# Static App example:mgmt_static_app:aws:account_id:<redact>role:<redact>region:ap-southeast-2assume_role:true# Override the template static appapp:src:./builds3_bucket_name:<redact>distribution_id:<redact># Terraform examplemgmt:aws:account_id:<redact>role:<redact>nonprod:aws:account_id:<redact>role:<redact>prod:aws:account_id:<redact>role:<redact>default:aws:account_id:<redact>role:<redact>assume_role:true|false (default to false)Plugin SystemTo give better support for customization inside the CLI we created aplugin systemthat you can extend code, creating new commands and groups and even modify the existing ones.All plugins need to be python packages to work.List of pluginsplugin-commandsplugin-kubeplugin-dnx-assumeplugin-foundationRunning$onemy_plugin
Itworks!Manualy generate binarypipinstallpyinstaller
pyinstaller--clean--hidden-importone.__main__cli.py--onefile--noconsole-noneDevelopmentDependenciesPython 3Python Virtual Environment# Create environmentpython3-mvenvenv# To activate the environmentsourceenv/bin/activate# When you finish you can exit typingdeactivateInstall dependenciespip3install--editable.AuthorManaged byDNX Solutions.LicenseApache 2 Licensed. SeeLICENSEfor full details.