lono 7.4.11 → 8.0.0.pre.rc1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.cody/README.md +5 -15
- data/.cody/acceptance/bin/build.sh +52 -0
- data/.cody/acceptance/buildspec.yml +10 -0
- data/.cody/acceptance/project.rb +6 -0
- data/.cody/{role.rb → acceptance/role.rb} +0 -0
- data/.cody/shared/script/install/lono.sh +40 -0
- data/.cody/shared/script/install.sh +5 -0
- data/CHANGELOG.md +33 -5
- data/CONTRIBUTING.md +2 -2
- data/Gemfile +5 -1
- data/LICENSE.txt +201 -1
- data/README.md +6 -5
- data/lib/lono/api/client.rb +3 -2
- data/lib/lono/app/inits.rb +13 -0
- data/lib/lono/app.rb +71 -0
- data/lib/lono/app_file/base.rb +1 -1
- data/lib/lono/app_file/build/lambda_layer/ruby_packager.rb +9 -9
- data/lib/lono/app_file/build/lambda_layer.rb +3 -3
- data/lib/lono/app_file/build.rb +9 -14
- data/lib/lono/app_file/registry/item.rb +4 -4
- data/lib/lono/app_file/upload.rb +1 -1
- data/lib/lono/autoloader.rb +2 -2
- data/lib/lono/aws_services/helper.rb +43 -6
- data/lib/lono/aws_services.rb +37 -6
- data/lib/lono/blueprint.rb +18 -9
- data/lib/lono/booter.rb +28 -0
- data/lib/lono/{template → builder}/context/helpers.rb +1 -1
- data/lib/lono/{template → builder}/context/loader/load_files.rb +5 -6
- data/lib/lono/builder/context/loader.rb +35 -0
- data/lib/lono/builder/context/params.rb +7 -0
- data/lib/lono/{template → builder}/context/ssm_fetcher.rb +1 -1
- data/lib/lono/{template → builder}/context.rb +5 -9
- data/lib/lono/{param/generator.rb → builder/param.rb} +21 -22
- data/lib/lono/builder/template/aws_service.rb +15 -0
- data/lib/lono/builder/template/bashify.rb +43 -0
- data/lib/lono/{template → builder/template}/configset_injector.rb +4 -4
- data/lib/lono/{template/strategy/dsl/builder → builder/template/dsl/evaluator}/fn.rb +2 -2
- data/lib/lono/{template/strategy/dsl/builder → builder/template/dsl/evaluator}/helpers/core_helper.rb +1 -1
- data/lib/lono/{template/strategy/dsl/builder → builder/template/dsl/evaluator}/helpers/ec2_helper.rb +1 -1
- data/lib/lono/{template/strategy/dsl/builder → builder/template/dsl/evaluator}/helpers/file_helper.rb +8 -12
- data/lib/lono/{template/strategy/dsl/builder → builder/template/dsl/evaluator}/helpers/s3_helper.rb +2 -2
- data/lib/lono/{template/strategy/dsl/builder → builder/template/dsl/evaluator}/helpers/stack_helper.rb +11 -8
- data/lib/lono/{template/strategy/dsl/builder → builder/template/dsl/evaluator}/helpers/tags_helper.rb +1 -1
- data/lib/lono/{template/strategy/dsl/builder → builder/template/dsl/evaluator}/helpers.rb +2 -2
- data/lib/lono/builder/template/dsl/evaluator/section/base.rb +23 -0
- data/lib/lono/{template/strategy/dsl/builder → builder/template/dsl/evaluator}/section/condition.rb +1 -1
- data/lib/lono/{template/strategy/dsl/builder → builder/template/dsl/evaluator}/section/mapping.rb +1 -1
- data/lib/lono/{template/strategy/dsl/builder → builder/template/dsl/evaluator}/section/methods.rb +7 -7
- data/lib/lono/{template/strategy/dsl/builder → builder/template/dsl/evaluator}/section/output.rb +1 -1
- data/lib/lono/{template/strategy/dsl/builder → builder/template/dsl/evaluator}/section/parameter.rb +1 -1
- data/lib/lono/{template/strategy/dsl/builder → builder/template/dsl/evaluator}/section/resource/property_mover.rb +1 -1
- data/lib/lono/{template/strategy/dsl/builder → builder/template/dsl/evaluator}/section/resource.rb +1 -1
- data/lib/lono/{template/strategy/dsl/builder → builder/template/dsl/evaluator}/section/section.rb +1 -1
- data/lib/lono/{template/strategy/dsl/builder → builder/template/dsl/evaluator}/squeezer.rb +1 -1
- data/lib/lono/{template/strategy/dsl/builder → builder/template/dsl/evaluator}/stringify.rb +1 -1
- data/lib/lono/{template/strategy/dsl/builder → builder/template/dsl/evaluator}/syntax/extend_with.rb +1 -1
- data/lib/lono/{template/strategy/dsl/builder → builder/template/dsl/evaluator}/syntax/parameter_group.rb +1 -1
- data/lib/lono/{template/strategy/dsl/builder → builder/template/dsl/evaluator}/syntax.rb +3 -3
- data/lib/lono/builder/template/dsl/evaluator.rb +45 -0
- data/lib/lono/{template/strategy → builder/template}/dsl/finalizer/parameter_groups.rb +2 -2
- data/lib/lono/{template/strategy → builder/template}/dsl/finalizer.rb +1 -1
- data/lib/lono/builder/template/dsl.rb +14 -0
- data/lib/lono/{template → builder/template}/evaluate.rb +18 -6
- data/lib/lono/builder/template/helpers.rb +149 -0
- data/lib/lono/{output/template.rb → builder/template/output.rb} +14 -7
- data/lib/lono/{template → builder/template}/post_processor.rb +4 -4
- data/lib/lono/{template → builder/template}/upload.rb +3 -5
- data/lib/lono/builder/template.rb +55 -0
- data/lib/lono/bundler/cli/base.rb +10 -0
- data/lib/lono/bundler/cli/bundle.rb +44 -0
- data/lib/lono/bundler/cli/clean.rb +27 -0
- data/lib/lono/bundler/cli/help/bundle.md +3 -0
- data/lib/lono/bundler/cli/help.rb +11 -0
- data/lib/lono/bundler/cli.rb +7 -0
- data/lib/lono/bundler/component/concerns/local_concern.rb +10 -0
- data/lib/lono/bundler/component/concerns/notation_concern.rb +59 -0
- data/lib/lono/bundler/component/concerns/path_concern.rb +68 -0
- data/lib/lono/bundler/component/concerns/stack_concern.rb +60 -0
- data/lib/lono/bundler/component/fetcher/base.rb +27 -0
- data/lib/lono/bundler/component/fetcher/gcs.rb +69 -0
- data/lib/lono/bundler/component/fetcher/git.rb +69 -0
- data/lib/lono/bundler/component/fetcher/local.rb +15 -0
- data/lib/lono/bundler/component/fetcher/s3.rb +66 -0
- data/lib/lono/bundler/component/fetcher.rb +18 -0
- data/lib/lono/bundler/component/http/concern.rb +45 -0
- data/lib/lono/bundler/component/http/source.rb +19 -0
- data/lib/lono/bundler/component/org_repo.rb +65 -0
- data/lib/lono/bundler/component/props/extension.rb +19 -0
- data/lib/lono/bundler/component/props/typer.rb +41 -0
- data/lib/lono/bundler/component/props.rb +122 -0
- data/lib/lono/bundler/component/registry.rb +136 -0
- data/lib/lono/bundler/component.rb +52 -0
- data/lib/lono/bundler/config.rb +18 -0
- data/lib/lono/bundler/dsl/syntax.rb +46 -0
- data/lib/lono/bundler/dsl.rb +21 -0
- data/lib/lono/bundler/exporter/base.rb +6 -0
- data/lib/lono/bundler/exporter/copy.rb +22 -0
- data/lib/lono/bundler/exporter.rb +50 -0
- data/lib/lono/bundler/extract/tar.rb +34 -0
- data/lib/lono/bundler/extract/zip.rb +16 -0
- data/lib/lono/bundler/info.rb +39 -0
- data/lib/lono/bundler/list.rb +26 -0
- data/lib/lono/bundler/lockfile/version_comparer.rb +56 -0
- data/lib/lono/bundler/lockfile/yamler.rb +36 -0
- data/lib/lono/bundler/lockfile.rb +66 -0
- data/lib/lono/bundler/lonofile.rb +32 -0
- data/lib/lono/bundler/runner.rb +27 -0
- data/lib/lono/bundler/syncer.rb +70 -0
- data/lib/lono/bundler/util/git.rb +37 -0
- data/lib/lono/bundler/util/logging.rb +7 -0
- data/lib/lono/bundler/util/sure.rb +5 -0
- data/lib/lono/{bundle.rb → bundler.rb} +38 -4
- data/lib/lono/cfn/base.rb +9 -196
- data/lib/lono/cfn/cancel.rb +9 -26
- data/lib/lono/cfn/concerns/build.rb +10 -0
- data/lib/lono/cfn/concerns/template_output.rb +10 -0
- data/lib/lono/cfn/concerns.rb +43 -0
- data/lib/lono/cfn/delete.rb +8 -32
- data/lib/lono/cfn/deploy/base.rb +4 -0
- data/lib/lono/cfn/deploy/iam.rb +49 -0
- data/lib/lono/cfn/deploy/notification.rb +8 -0
- data/lib/lono/cfn/deploy/operable.rb +18 -0
- data/lib/lono/cfn/deploy/opts.rb +49 -0
- data/lib/lono/cfn/deploy/rollback.rb +46 -0
- data/lib/lono/cfn/deploy/tags.rb +18 -0
- data/lib/lono/cfn/deploy.rb +71 -5
- data/lib/lono/cfn/download.rb +5 -7
- data/lib/lono/cfn/output.rb +49 -0
- data/lib/lono/cfn/plan/base.rb +19 -0
- data/lib/lono/cfn/plan/changeset/base.rb +19 -0
- data/lib/lono/cfn/plan/changeset/notifications.rb +24 -0
- data/lib/lono/cfn/plan/changeset/outputs.rb +25 -0
- data/lib/lono/cfn/plan/changeset/resources.rb +48 -0
- data/lib/lono/cfn/plan/changeset/tags.rb +16 -0
- data/lib/lono/cfn/plan/changeset.rb +136 -0
- data/lib/lono/cfn/plan/concerns.rb +10 -0
- data/lib/lono/cfn/plan/delete.rb +16 -0
- data/lib/lono/cfn/plan/diff/base.rb +10 -0
- data/lib/lono/cfn/plan/diff/data.rb +52 -0
- data/lib/lono/cfn/plan/diff/file.rb +56 -0
- data/lib/lono/cfn/plan/new.rb +26 -0
- data/lib/lono/cfn/{preview → plan}/param.rb +26 -34
- data/lib/lono/cfn/plan/summary.rb +16 -0
- data/lib/lono/cfn/plan/template.rb +28 -0
- data/lib/lono/cfn/plan.rb +33 -0
- data/lib/lono/cfn/show.rb +30 -0
- data/lib/lono/cfn/status.rb +1 -1
- data/lib/lono/cli/abstract.rb +17 -0
- data/lib/lono/cli/base.rb +9 -0
- data/lib/lono/cli/build.rb +101 -0
- data/lib/lono/cli/bundle.rb +21 -0
- data/lib/lono/cli/cfn/opts.rb +59 -0
- data/lib/lono/cli/cfn.rb +19 -0
- data/lib/lono/cli/clean.rb +22 -0
- data/lib/lono/{code.rb → cli/code.rb} +2 -2
- data/lib/lono/{completion.rb → cli/completion.rb} +2 -2
- data/lib/lono/{help → cli/help}/blueprint/new.md +4 -4
- data/lib/lono/{help/generate.md → cli/help/build.md} +6 -6
- data/lib/lono/{help → cli/help}/cfn/cancel.md +0 -0
- data/lib/lono/cli/help/cfn/download.md +3 -0
- data/lib/lono/{help → cli/help}/cfn/preview.md +9 -8
- data/lib/lono/{help → cli/help}/cfn/status.md +0 -0
- data/lib/lono/cli/help/cfn.md +4 -0
- data/lib/lono/{help → cli/help}/code/convert.md +0 -0
- data/lib/lono/{help → cli/help}/code/import.md +2 -2
- data/lib/lono/{help → cli/help}/completion.md +3 -3
- data/lib/lono/{help → cli/help}/completion_script.md +0 -0
- data/lib/lono/{help → cli/help}/configsets.md +0 -0
- data/lib/lono/cli/help/down.md +13 -0
- data/lib/lono/cli/help/new/project.md +34 -0
- data/lib/lono/{help → cli/help}/param/generate.md +0 -0
- data/lib/lono/cli/help/param.md +6 -0
- data/lib/lono/{help → cli/help}/pro/blueprints.md +0 -0
- data/lib/lono/{help → cli/help}/pro/configsets.md +0 -0
- data/lib/lono/{help → cli/help}/script/build.md +0 -0
- data/lib/lono/{help → cli/help}/script/upload.md +0 -0
- data/lib/lono/{help → cli/help}/seed.md +2 -2
- data/lib/lono/cli/help/summary.md +33 -0
- data/lib/lono/{help → cli/help}/template/bashify.md +0 -0
- data/lib/lono/cli/help/template/generate.md +7 -0
- data/lib/lono/{help → cli/help}/template.md +0 -0
- data/lib/lono/cli/help/up.md +30 -0
- data/lib/lono/{help → cli/help}/user_data.md +3 -3
- data/lib/lono/cli/help.rb +56 -0
- data/lib/lono/cli/list.rb +28 -0
- data/lib/lono/cli/new/blueprint.rb +33 -0
- data/lib/lono/cli/new/concerns.rb +16 -0
- data/lib/lono/{configset/new.rb → cli/new/configset.rb} +2 -9
- data/lib/lono/{extension/new.rb → cli/new/extension.rb} +2 -10
- data/lib/lono/cli/new/helper.rb +32 -0
- data/lib/lono/cli/new/project.rb +77 -0
- data/lib/lono/cli/new/sequence.rb +51 -0
- data/lib/lono/cli/new/shim.rb +59 -0
- data/lib/lono/cli/new/test/blueprint.rb +23 -0
- data/lib/lono/cli/new/test/sequence.rb +10 -0
- data/lib/lono/cli/new/test.rb +8 -0
- data/lib/lono/cli/new.rb +31 -0
- data/lib/lono/{opts.rb → cli/opts.rb} +9 -12
- data/lib/lono/{s3.rb → cli/s3.rb} +9 -7
- data/lib/lono/cli/script/base.rb +5 -0
- data/lib/lono/cli/script/build.rb +72 -0
- data/lib/lono/cli/script/upload.rb +49 -0
- data/lib/lono/{script.rb → cli/script.rb} +2 -2
- data/lib/lono/cli/seed.rb +9 -0
- data/lib/lono/cli/test.rb +35 -0
- data/lib/lono/cli.rb +80 -106
- data/lib/lono/command.rb +27 -0
- data/lib/lono/configset/{generator.rb → builder.rb} +9 -7
- data/lib/lono/configset/combiner.rb +8 -6
- data/lib/lono/configset/evaluate_file.rb +1 -1
- data/lib/lono/configset/meta.rb +1 -1
- data/lib/lono/configset/s3_file/build.rb +5 -4
- data/lib/lono/configset/s3_file/item.rb +1 -1
- data/lib/lono/configset/s3_file/upload.rb +2 -2
- data/lib/lono/configset/strategy/base.rb +6 -6
- data/lib/lono/configset/strategy/helpers/dsl/core.rb +1 -1
- data/lib/lono/core.rb +25 -54
- data/lib/lono/extensions/dsl.rb +2 -5
- data/lib/lono/extensions/loader.rb +1 -12
- data/lib/lono/extensions.rb +2 -2
- data/lib/lono/importer/base.rb +5 -5
- data/lib/lono/importer/download.rb +7 -7
- data/lib/lono/importer/dsl.rb +3 -3
- data/lib/lono/importer/service/coder.rb +10 -10
- data/lib/lono/importer.rb +1 -10
- data/lib/lono/inspector/base.rb +7 -7
- data/lib/lono/inspector/summary.rb +19 -17
- data/lib/lono/layering/layer.rb +126 -0
- data/lib/lono/layering.rb +13 -55
- data/lib/lono/logger/formatter.rb +13 -0
- data/lib/lono/logger.rb +33 -0
- data/lib/lono/lookup.rb +12 -0
- data/lib/lono/names.rb +50 -0
- data/lib/lono/plugin/meta.rb +30 -0
- data/lib/lono/plugin/tester.rb +13 -0
- data/lib/lono/plugin.rb +10 -0
- data/lib/lono/s3/aws_setup.rb +4 -3
- data/lib/lono/s3/bucket.rb +19 -19
- data/lib/lono/s3/uploader.rb +10 -12
- data/lib/lono/script/base.rb +3 -3
- data/lib/lono/script/build.rb +11 -12
- data/lib/lono/script/upload.rb +7 -7
- data/lib/lono/{seed → seeder}/service_role.rb +1 -1
- data/lib/lono/{seed/base.rb → seeder.rb} +21 -36
- data/lib/lono/user_data.rb +8 -13
- data/lib/lono/utils/context.rb +15 -0
- data/lib/lono/utils/item/zip.rb +5 -5
- data/lib/lono/utils/logging.rb +7 -0
- data/lib/lono/utils/{pretty_time.rb → pretty.rb} +6 -2
- data/lib/lono/utils/quit.rb +7 -0
- data/lib/lono/utils/rsync.rb +4 -2
- data/lib/lono/utils/sure.rb +4 -4
- data/lib/lono/version.rb +1 -1
- data/lib/lono.rb +7 -11
- data/lib/templates/blueprint/template.rb +2 -0
- data/lib/templates/configset/{lib/configset.rb → configset.rb} +0 -0
- data/lib/templates/examples/blueprint/template.rb +9 -0
- data/lib/templates/helper/%underscore_name%_helper.rb.tt +6 -0
- data/lib/templates/{skeleton → project}/.gitignore +1 -2
- data/lib/templates/project/Gemfile.tt +11 -0
- data/lib/templates/project/README.md +9 -0
- data/lib/templates/project/config/app.rb +3 -0
- data/lib/templates/shim/lono +7 -0
- data/lono.gemspec +51 -43
- metadata +261 -264
- data/.circleci/README.md +0 -3
- data/.circleci/config.yml +0 -58
- data/.cody/acceptance.sh +0 -49
- data/.cody/buildspec.yml +0 -9
- data/.cody/demo.rb +0 -38
- data/.cody/project.rb +0 -6
- data/.gitmodules +0 -3
- data/lib/lono/abstract_base.rb +0 -25
- data/lib/lono/aws_services/stack.rb +0 -41
- data/lib/lono/aws_services/stack_set.rb +0 -41
- data/lib/lono/blueprint/configset/loader.rb +0 -7
- data/lib/lono/blueprint/helper.rb +0 -24
- data/lib/lono/blueprint/meta.rb +0 -30
- data/lib/lono/blueprint/new.rb +0 -127
- data/lib/lono/blueprint/root.rb +0 -25
- data/lib/lono/cfn/create.rb +0 -41
- data/lib/lono/cfn/opts.rb +0 -88
- data/lib/lono/cfn/preview/changeset.rb +0 -168
- data/lib/lono/cfn/preview/codediff.rb +0 -41
- data/lib/lono/cfn/preview/diff_viewer.rb +0 -23
- data/lib/lono/cfn/rollback.rb +0 -26
- data/lib/lono/cfn/update.rb +0 -71
- data/lib/lono/cfn.rb +0 -75
- data/lib/lono/clean.rb +0 -14
- data/lib/lono/configset/list.rb +0 -67
- data/lib/lono/configset/preparer.rb +0 -44
- data/lib/lono/configset/register/base.rb +0 -122
- data/lib/lono/configset/register/blueprint.rb +0 -16
- data/lib/lono/configset/register/dsl.rb +0 -14
- data/lib/lono/configset/register/project.rb +0 -13
- data/lib/lono/configset/resolver.rb +0 -47
- data/lib/lono/configset.rb +0 -16
- data/lib/lono/conventions.rb +0 -23
- data/lib/lono/core/config.rb +0 -22
- data/lib/lono/default/settings.yml +0 -21
- data/lib/lono/ext/bundler.rb +0 -7
- data/lib/lono/extension/helper.rb +0 -13
- data/lib/lono/extension/list.rb +0 -40
- data/lib/lono/extension.rb +0 -9
- data/lib/lono/extensions/preparer.rb +0 -26
- data/lib/lono/extensions/register.rb +0 -15
- data/lib/lono/file_uploader.rb +0 -21
- data/lib/lono/finder/base.rb +0 -152
- data/lib/lono/finder/blueprint/configset.rb +0 -17
- data/lib/lono/finder/blueprint.rb +0 -11
- data/lib/lono/finder/configset.rb +0 -11
- data/lib/lono/finder/extension.rb +0 -11
- data/lib/lono/generate.rb +0 -107
- data/lib/lono/help/cfn/create.md +0 -26
- data/lib/lono/help/cfn/delete.md +0 -13
- data/lib/lono/help/cfn/deploy.md +0 -21
- data/lib/lono/help/cfn/download.md +0 -3
- data/lib/lono/help/cfn/update.md +0 -49
- data/lib/lono/help/cfn.md +0 -7
- data/lib/lono/help/new.md +0 -57
- data/lib/lono/help/param.md +0 -6
- data/lib/lono/help/sets/delete.md +0 -8
- data/lib/lono/help/sets/deploy.md +0 -76
- data/lib/lono/help/sets/instances/delete.md +0 -21
- data/lib/lono/help/sets/instances/list.md +0 -14
- data/lib/lono/help/sets/instances/status.md +0 -15
- data/lib/lono/help/sets/instances/sync.md +0 -90
- data/lib/lono/help/sets/status.md +0 -23
- data/lib/lono/help/summary.md +0 -33
- data/lib/lono/help/template/generate.md +0 -7
- data/lib/lono/help/upgrade.md +0 -1
- data/lib/lono/help/xgraph.md +0 -16
- data/lib/lono/help.rb +0 -15
- data/lib/lono/importer/erb.rb +0 -31
- data/lib/lono/inspector/graph.rb +0 -125
- data/lib/lono/jade/circular.rb +0 -26
- data/lib/lono/jade/materializer/final.rb +0 -10
- data/lib/lono/jade/materializer/gems_builder.rb +0 -81
- data/lib/lono/jade/materializer/source.rb +0 -54
- data/lib/lono/jade/materializer.rb +0 -15
- data/lib/lono/jade/registry.rb +0 -64
- data/lib/lono/jade.rb +0 -110
- data/lib/lono/jadespec.rb +0 -68
- data/lib/lono/new/helper.rb +0 -15
- data/lib/lono/new.rb +0 -95
- data/lib/lono/param.rb +0 -14
- data/lib/lono/pro/base.rb +0 -16
- data/lib/lono/pro/repo.rb +0 -28
- data/lib/lono/pro.rb +0 -15
- data/lib/lono/project_checker.rb +0 -35
- data/lib/lono/registration/base.rb +0 -37
- data/lib/lono/registration/check.rb +0 -15
- data/lib/lono/registration/temp.rb +0 -53
- data/lib/lono/registration/user.rb +0 -60
- data/lib/lono/seed.rb +0 -39
- data/lib/lono/sequence.rb +0 -35
- data/lib/lono/sets/base.rb +0 -50
- data/lib/lono/sets/create.rb +0 -30
- data/lib/lono/sets/delete.rb +0 -52
- data/lib/lono/sets/deploy.rb +0 -11
- data/lib/lono/sets/instances/base.rb +0 -30
- data/lib/lono/sets/instances/delete.rb +0 -69
- data/lib/lono/sets/instances/list.rb +0 -13
- data/lib/lono/sets/instances/opts.rb +0 -29
- data/lib/lono/sets/instances/status.rb +0 -12
- data/lib/lono/sets/instances/sync.rb +0 -180
- data/lib/lono/sets/instances.rb +0 -33
- data/lib/lono/sets/list.rb +0 -35
- data/lib/lono/sets/opts.rb +0 -18
- data/lib/lono/sets/preview/codediff.rb +0 -35
- data/lib/lono/sets/preview/param.rb +0 -32
- data/lib/lono/sets/status/instance/base.rb +0 -120
- data/lib/lono/sets/status/instance/completed.rb +0 -35
- data/lib/lono/sets/status/instance/deleted.rb +0 -32
- data/lib/lono/sets/status/instance/show.rb +0 -7
- data/lib/lono/sets/status/instance.rb +0 -20
- data/lib/lono/sets/status/instances.rb +0 -133
- data/lib/lono/sets/status.rb +0 -116
- data/lib/lono/sets/summarize.rb +0 -20
- data/lib/lono/sets/time_spent.rb +0 -11
- data/lib/lono/sets/update.rb +0 -81
- data/lib/lono/sets.rb +0 -38
- data/lib/lono/setting.rb +0 -75
- data/lib/lono/template/aws_service.rb +0 -20
- data/lib/lono/template/bashify.rb +0 -39
- data/lib/lono/template/context/loader.rb +0 -52
- data/lib/lono/template/generator.rb +0 -23
- data/lib/lono/template/helper.rb +0 -152
- data/lib/lono/template/strategy/base.rb +0 -4
- data/lib/lono/template/strategy/common/helpers.rb +0 -44
- data/lib/lono/template/strategy/dsl/builder/section/base.rb +0 -30
- data/lib/lono/template/strategy/dsl/builder.rb +0 -59
- data/lib/lono/template/strategy/dsl.rb +0 -14
- data/lib/lono/template/strategy/erb.rb +0 -82
- data/lib/lono/template/strategy/source.rb +0 -8
- data/lib/lono/template/template.rb +0 -54
- data/lib/lono/template/util.rb +0 -8
- data/lib/lono/template.rb +0 -24
- data/lib/lono/upgrade.rb +0 -20
- data/lib/lono/utils/generators/tree.rb +0 -18
- data/lib/templates/blueprint/%blueprint_name%.gemspec.tt +0 -45
- data/lib/templates/blueprint/.gitignore +0 -11
- data/lib/templates/blueprint/CHANGELOG.md +0 -7
- data/lib/templates/blueprint/Gemfile +0 -4
- data/lib/templates/blueprint/README.md.tt +0 -33
- data/lib/templates/blueprint/Rakefile.tt +0 -9
- data/lib/templates/blueprint/seed/configs.rb +0 -28
- data/lib/templates/blueprint_types/dsl/app/templates/%blueprint_name%.rb +0 -36
- data/lib/templates/blueprint_types/dsl/app/user_data/bootstrap.sh +0 -2
- data/lib/templates/blueprint_types/erb/app/definitions/base.rb.tt +0 -1
- data/lib/templates/blueprint_types/erb/app/templates/%blueprint_name%.yml +0 -67
- data/lib/templates/configset/%configset_name%.gemspec.tt +0 -42
- data/lib/templates/configset/.gitignore +0 -10
- data/lib/templates/configset/CHANGELOG.md +0 -7
- data/lib/templates/configset/Gemfile +0 -4
- data/lib/templates/configset/README.md.tt +0 -3
- data/lib/templates/configset/Rakefile.tt +0 -9
- data/lib/templates/extension/%extension_name%.gemspec.tt +0 -46
- data/lib/templates/extension/.gitignore +0 -11
- data/lib/templates/extension/.rspec +0 -3
- data/lib/templates/extension/CHANGELOG.md +0 -7
- data/lib/templates/extension/Gemfile.tt +0 -4
- data/lib/templates/extension/Rakefile.tt +0 -9
- data/lib/templates/extension/spec/spec_helper.rb.tt +0 -29
- data/lib/templates/skeleton/Gemfile +0 -3
- data/lib/templates/skeleton/README.md +0 -58
- data/lib/templates/skeleton/configs/settings.yml +0 -13
- data/vendor/cfn-status/CHANGELOG.md +0 -14
- data/vendor/cfn-status/Gemfile +0 -4
- data/vendor/cfn-status/Gemfile.lock +0 -49
- data/vendor/cfn-status/LICENSE.txt +0 -21
- data/vendor/cfn-status/README.md +0 -58
- data/vendor/cfn-status/Rakefile +0 -6
- data/vendor/cfn-status/bin/console +0 -14
- data/vendor/cfn-status/bin/setup +0 -8
- data/vendor/cfn-status/cfn-status.gemspec +0 -30
- data/vendor/cfn-status/lib/cfn-status.rb +0 -1
- data/vendor/cfn-status/lib/cfn_status/aws_service.rb +0 -51
- data/vendor/cfn-status/lib/cfn_status/version.rb +0 -3
- data/vendor/cfn-status/lib/cfn_status.rb +0 -245
- data/vendor/cfn-status/spec/fixtures/cfn/pages/fresh/describe_stack_events-1.json +0 -1103
- data/vendor/cfn-status/spec/fixtures/cfn/pages/fresh/describe_stack_events-2.json +0 -1104
- data/vendor/cfn-status/spec/fixtures/cfn/pages/fresh/describe_stack_events-3.json +0 -1103
- data/vendor/cfn-status/spec/fixtures/cfn/pages/updating/describe_stack_events-1.json +0 -1103
- data/vendor/cfn-status/spec/fixtures/cfn/pages/updating/describe_stack_events-2.json +0 -1104
- data/vendor/cfn-status/spec/fixtures/cfn/pages/updating/describe_stack_events-3.json +0 -1103
- data/vendor/cfn-status/spec/fixtures/cfn/stack-events-complete.json +0 -1080
- data/vendor/cfn-status/spec/fixtures/cfn/stack-events-in-progress.json +0 -1080
- data/vendor/cfn-status/spec/fixtures/cfn/stack-events-update-rollback-complete.json +0 -1086
- data/vendor/cfn-status/spec/lib/cfn_status_spec.rb +0 -153
- data/vendor/cfn-status/spec/spec_helper.rb +0 -14
@@ -1,82 +0,0 @@
|
|
1
|
-
module Lono::Template::Strategy
|
2
|
-
class Erb < Base
|
3
|
-
include Lono::Template::Evaluate
|
4
|
-
include Lono::Template::Util
|
5
|
-
|
6
|
-
def initialize(options={})
|
7
|
-
super
|
8
|
-
@templates = []
|
9
|
-
@results = {}
|
10
|
-
end
|
11
|
-
|
12
|
-
def run(options={})
|
13
|
-
evaluate_templates
|
14
|
-
build_templates
|
15
|
-
write_output
|
16
|
-
end
|
17
|
-
|
18
|
-
# Instance eval's the template declarations in app/definitions in this order:
|
19
|
-
#
|
20
|
-
# app/definitions/base.rb
|
21
|
-
# app/definitions/base - all files in folder
|
22
|
-
# app/definitions/[Lono.env].rb
|
23
|
-
# app/definitions/[Lono.env] - all files in folder
|
24
|
-
#
|
25
|
-
# So Lono.env specific template declarations override base template declarations.
|
26
|
-
def evaluate_templates
|
27
|
-
evaluate_template("base")
|
28
|
-
evaluate_folder("base")
|
29
|
-
evaluate_template(Lono.env)
|
30
|
-
evaluate_folder(Lono.env)
|
31
|
-
end
|
32
|
-
|
33
|
-
def evaluate_template(name)
|
34
|
-
path = "#{Lono.config.definitions_path}/#{name}.rb"
|
35
|
-
evaluate_template_path(path)
|
36
|
-
end
|
37
|
-
|
38
|
-
def evaluate_folder(folder)
|
39
|
-
paths = Dir.glob("#{Lono.config.definitions_path}/#{folder}/**/*")
|
40
|
-
paths.select{ |e| File.file?(e) }.each do |path|
|
41
|
-
evaluate_template_path(path)
|
42
|
-
end
|
43
|
-
end
|
44
|
-
|
45
|
-
def template(name, &block)
|
46
|
-
@templates << {name: name, block: block}
|
47
|
-
end
|
48
|
-
|
49
|
-
def build_templates
|
50
|
-
@templates.each do |t|
|
51
|
-
@results[t[:name]] = Lono::Template::Template.new(@blueprint, t[:name], t[:block], @options).build
|
52
|
-
end
|
53
|
-
end
|
54
|
-
|
55
|
-
def write_output
|
56
|
-
output_path = "#{Lono.config.output_path}/#{@blueprint}/templates"
|
57
|
-
FileUtils.rm_rf(Lono.config.output_path) if @options[:clean] # removes entire output folder. params and templates
|
58
|
-
FileUtils.mkdir_p(output_path)
|
59
|
-
puts "Generating CloudFormation templates for blueprint #{@blueprint.color(:green)}:" unless @options[:quiet]
|
60
|
-
@results.each do |name,text|
|
61
|
-
path = "#{output_path}/#{name}".sub(/^\.\//,'') # strip leading '.'
|
62
|
-
path += ".yml"
|
63
|
-
unless @options[:quiet]
|
64
|
-
pretty_path = path.sub("#{Lono.root}/",'')
|
65
|
-
puts " #{pretty_path}"
|
66
|
-
end
|
67
|
-
ensure_parent_dir(path)
|
68
|
-
text = commented(text)
|
69
|
-
IO.write(path, text) # write file first so validate method is simpler
|
70
|
-
Lono::Yamler::Validator.new(path).validate!
|
71
|
-
end
|
72
|
-
end
|
73
|
-
|
74
|
-
def commented(text)
|
75
|
-
comment =<<~EOS
|
76
|
-
# This file was generated with lono. Do not edit directly, the changes will be lost.
|
77
|
-
# More info: http://lono.cloud
|
78
|
-
EOS
|
79
|
-
"#{comment}#{text}"
|
80
|
-
end
|
81
|
-
end
|
82
|
-
end
|
@@ -1,54 +0,0 @@
|
|
1
|
-
require 'erb'
|
2
|
-
require 'json'
|
3
|
-
require 'base64'
|
4
|
-
|
5
|
-
class Lono::Template::Template
|
6
|
-
include ERB::Util
|
7
|
-
|
8
|
-
# Main template Erb methods are: source and variables
|
9
|
-
#
|
10
|
-
# template "example-2" do
|
11
|
-
# source "example"
|
12
|
-
# variables(test: 1)
|
13
|
-
# end
|
14
|
-
#
|
15
|
-
attr_reader :name
|
16
|
-
def initialize(blueprint, name, block=nil, options={})
|
17
|
-
@blueprint, @name, @block, @options = blueprint, name, block, options
|
18
|
-
@source_path = default_source_path(name)
|
19
|
-
end
|
20
|
-
|
21
|
-
# Returns path, example: ./app/templates/example.yml
|
22
|
-
def source(path)
|
23
|
-
@source_path = path[0..0] == '/' ? path : "#{Lono.config.templates_path}/#{path}"
|
24
|
-
@source_path += ".yml"
|
25
|
-
end
|
26
|
-
|
27
|
-
def variables(vars={})
|
28
|
-
vars.each do |var,value|
|
29
|
-
context.instance_variable_set("@#{var}", value)
|
30
|
-
end
|
31
|
-
end
|
32
|
-
|
33
|
-
# internal methods
|
34
|
-
def default_source_path(name)
|
35
|
-
"#{Lono.config.templates_path}/#{name}.yml" # defaults to name, source method overrides
|
36
|
-
end
|
37
|
-
|
38
|
-
def build
|
39
|
-
instance_eval(&@block) if @block
|
40
|
-
|
41
|
-
if File.exist?(@source_path)
|
42
|
-
RenderMePretty.result(@source_path, context: context)
|
43
|
-
else
|
44
|
-
puts "ERROR: #{@source_path} does not exist, but it was used as a template source.".color(:red)
|
45
|
-
exit 1
|
46
|
-
end
|
47
|
-
end
|
48
|
-
|
49
|
-
# Context for ERB rendering.
|
50
|
-
# This is where we control what references get passed to the ERB rendering.
|
51
|
-
def context
|
52
|
-
@context ||= Lono::Template::Context.new(@options)
|
53
|
-
end
|
54
|
-
end
|
data/lib/lono/template/util.rb
DELETED
data/lib/lono/template.rb
DELETED
@@ -1,24 +0,0 @@
|
|
1
|
-
module Lono
|
2
|
-
class Template < Command
|
3
|
-
class_option :quiet, type: :boolean, desc: "silence the output"
|
4
|
-
class_option :noop, type: :boolean, desc: "noop mode, do nothing destructive"
|
5
|
-
|
6
|
-
desc "generate BLUEPRINT", "Generate the CloudFormation templates"
|
7
|
-
long_desc Lono::Help.text("template/generate")
|
8
|
-
option :clean, type: :boolean, desc: "remove all output files before generating"
|
9
|
-
def generate(blueprint)
|
10
|
-
Generator.new(options.merge(blueprint: blueprint)).run
|
11
|
-
end
|
12
|
-
|
13
|
-
desc "upload", "Uploads templates to configured s3 folder"
|
14
|
-
def upload(blueprint)
|
15
|
-
Upload.new(options.merge(blueprint: blueprint)).run
|
16
|
-
end
|
17
|
-
|
18
|
-
desc "bashify URL-OR-PATH", "Convert the UserData section of an existing CloudFormation Template to a starter bash script that is compatiable with lono"
|
19
|
-
long_desc Lono::Help.text("template/bashify")
|
20
|
-
def bashify(path)
|
21
|
-
Bashify.new(options.merge(path: path)).run
|
22
|
-
end
|
23
|
-
end
|
24
|
-
end
|
data/lib/lono/upgrade.rb
DELETED
@@ -1,20 +0,0 @@
|
|
1
|
-
module Lono
|
2
|
-
class Upgrade
|
3
|
-
def initialize(options)
|
4
|
-
@options = options
|
5
|
-
end
|
6
|
-
|
7
|
-
def run
|
8
|
-
app_blueprints_move # v6 to v7
|
9
|
-
puts "Lono project upgraded"
|
10
|
-
end
|
11
|
-
|
12
|
-
def app_blueprints_move
|
13
|
-
return if File.exist?("#{Lono.root}/app/blueprints")
|
14
|
-
return unless File.exist?("#{Lono.root}/blueprints")
|
15
|
-
|
16
|
-
FileUtils.mv("#{Lono.root}/blueprints", "#{Lono.root}/app/blueprints")
|
17
|
-
puts "Move blueprints to app/blueprints"
|
18
|
-
end
|
19
|
-
end
|
20
|
-
end
|
@@ -1,18 +0,0 @@
|
|
1
|
-
module Lono::Utils::Generators
|
2
|
-
module Tree
|
3
|
-
private
|
4
|
-
def tree_structure(name)
|
5
|
-
return if options[:from_new] || options[:import] # only for lono new
|
6
|
-
|
7
|
-
tree_installed = system("type tree > /dev/null 2>&1")
|
8
|
-
return unless tree_installed
|
9
|
-
|
10
|
-
structure = `tree .`
|
11
|
-
puts <<~EOL
|
12
|
-
Here is the structure of your #{name}:
|
13
|
-
|
14
|
-
#{structure}
|
15
|
-
EOL
|
16
|
-
end
|
17
|
-
end
|
18
|
-
end
|
@@ -1,45 +0,0 @@
|
|
1
|
-
lib = File.expand_path("../lib", __FILE__)
|
2
|
-
$LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
|
3
|
-
|
4
|
-
Gem::Specification.new do |spec|
|
5
|
-
spec.name = "<%= blueprint_name %>"
|
6
|
-
spec.version = "0.1.0"
|
7
|
-
spec.authors = ["<%= user_info[:author] %>"]
|
8
|
-
spec.email = ["<%= ENV['LONO_EMAIL'] || user_info[:email] %>"]
|
9
|
-
|
10
|
-
spec.summary = "Write a short summary because it's required." # TODO: Change me
|
11
|
-
spec.homepage = "<%= ENV['LONO_ORG'] || "https://github.com/USER" %>/<%= blueprint_name %>"
|
12
|
-
spec.license = "<%= ENV['LONO_LICENSE'] || 'Nonstandard' %>"<%= ENV["LONO_LICENSE_EXTRA"] %>
|
13
|
-
|
14
|
-
# Prevent pushing this gem to RubyGems.org. To allow pushes either set the 'allowed_push_host'
|
15
|
-
# to allow pushing to a single host or delete this section to allow pushing to any host.
|
16
|
-
if spec.respond_to?(:metadata)
|
17
|
-
spec.metadata["lono_type"] = "blueprint"
|
18
|
-
spec.metadata["lono_strategy"] = "<%= @options[:type] %>"
|
19
|
-
|
20
|
-
spec.metadata["allowed_push_host"] = "<%= ENV['LONO_ALLOWED_PUSH_HOST'] || "TODO: Set to 'http://mygemserver.com'"%>"
|
21
|
-
spec.metadata["homepage_uri"] = spec.homepage
|
22
|
-
<% if ENV['LONO_ORG'] -%>
|
23
|
-
spec.metadata["source_code_uri"] = "<%= ENV['LONO_ORG'] %>/<%= blueprint_name %>"
|
24
|
-
spec.metadata["changelog_uri"] = "<%= ENV['LONO_ORG'] %>/<%= blueprint_name %>/blob/master/CHANGELOG.md"
|
25
|
-
<% else -%>
|
26
|
-
spec.metadata["source_code_uri"] = "https://github.com/user/repo" # TODO: Change me
|
27
|
-
spec.metadata["changelog_uri"] = "https://github.com/user/repo/blob/master/CHANGELOG.md" # TODO: Change me
|
28
|
-
<% end -%>
|
29
|
-
else
|
30
|
-
raise "RubyGems 2.0 or newer is required to protect against public gem pushes."
|
31
|
-
end
|
32
|
-
|
33
|
-
# Specify which files should be added to the gem when it is released.
|
34
|
-
# The `git ls-files -z` loads the files in the RubyGem that have been added into git.
|
35
|
-
spec.files = Dir.chdir(File.expand_path('..', __FILE__)) do
|
36
|
-
`git ls-files -z`.split("\x0").reject { |f| f.match(%r{^(test|spec|features)/}) }
|
37
|
-
end
|
38
|
-
spec.bindir = "exe"
|
39
|
-
spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
|
40
|
-
spec.require_paths = ["lib"]
|
41
|
-
|
42
|
-
spec.add_development_dependency "bundler", "~> 2.0"
|
43
|
-
spec.add_development_dependency "rake", "~> 10.0"
|
44
|
-
spec.add_development_dependency "rspec", "~> 3.0"
|
45
|
-
end
|
@@ -1,33 +0,0 @@
|
|
1
|
-
# Blueprint: <%= blueprint_name %>
|
2
|
-
|
3
|
-
## Usage
|
4
|
-
|
5
|
-
1. Configure: configs/<%= blueprint_name %> values
|
6
|
-
2. Deploy
|
7
|
-
|
8
|
-
## Configure
|
9
|
-
|
10
|
-
First you want to configure the `configs/<%= blueprint_name %>` [config files](https://lono.cloud/docs/core/configs/). You can use [lono seed](https://lono.cloud/reference/lono-seed/) to configure starter values quickly.
|
11
|
-
|
12
|
-
LONO_ENV=development lono seed <%= blueprint_name %>
|
13
|
-
|
14
|
-
For additional environments:
|
15
|
-
|
16
|
-
LONO_ENV=production lono seed <%= blueprint_name %>
|
17
|
-
|
18
|
-
The generated files in `config/<%= blueprint_name %>` folder look something like this:
|
19
|
-
|
20
|
-
configs/<%= blueprint_name %>/
|
21
|
-
├── params
|
22
|
-
│ ├── development.txt
|
23
|
-
│ └── production.txt
|
24
|
-
└── variables
|
25
|
-
├── development.rb
|
26
|
-
└── production.rb
|
27
|
-
|
28
|
-
## Deploy
|
29
|
-
|
30
|
-
Use the [lono cfn deploy](https://lono.cloud/reference/lono-cfn-deploy/) command to deploy. Example:
|
31
|
-
|
32
|
-
LONO_ENV=development lono cfn deploy <%= blueprint_name %>-development --blueprint <%= blueprint_name %> --sure
|
33
|
-
LONO_ENV=production lono cfn deploy <%= blueprint_name %>-production --blueprint <%= blueprint_name %> --sure
|
@@ -1,28 +0,0 @@
|
|
1
|
-
# This is an optional class is used by `lono seed [blueprint]` to create starter configs.
|
2
|
-
# Example files that get created:
|
3
|
-
#
|
4
|
-
# configs/BLUEPRINT/params/LONO_ENV.txt
|
5
|
-
# configs/BLUEPRINT/variables/LONO_ENV.rb
|
6
|
-
#
|
7
|
-
# The `Lono::Seed::Configs` class should implement:
|
8
|
-
#
|
9
|
-
# setup: Hook to perform logic at the beginning. A good place to create IAM service roles.
|
10
|
-
# variables: Template for generated variables file. Contents of what gets created at
|
11
|
-
# configs/[blueprint]/variables/development.rb
|
12
|
-
#
|
13
|
-
# Note: There is no need to define a params method. Lono is able to generate a params config starter file by evaluating the template defintion.
|
14
|
-
#
|
15
|
-
class Lono::Seed::Configs < Lono::Seed::Base
|
16
|
-
# Setup hook
|
17
|
-
# def setup
|
18
|
-
# end
|
19
|
-
|
20
|
-
# Template for variables.
|
21
|
-
# Return String with the content of the config/BLUEPRINT/variables file.
|
22
|
-
# def variables
|
23
|
-
# <<~EOL
|
24
|
-
# @variable1 = "starter_value1"
|
25
|
-
# @variable2 = "starter_value2"
|
26
|
-
# EOL
|
27
|
-
# end
|
28
|
-
end
|
@@ -1,36 +0,0 @@
|
|
1
|
-
aws_template_format_version "2010-09-09"
|
2
|
-
description "Demo stack"
|
3
|
-
|
4
|
-
parameter("InstanceType", "t3.micro")
|
5
|
-
|
6
|
-
mapping("AmiMap",
|
7
|
-
"ap-northeast-1": { Ami: "ami-068a6cefc24c301d2" },
|
8
|
-
"ap-northeast-2": { Ami: "ami-0d59ddf55cdda6e21" },
|
9
|
-
"ap-south-1": { Ami: "ami-0ce933e2ae91880d3" },
|
10
|
-
"ap-southeast-1": { Ami: "ami-07539a31f72d244e7" },
|
11
|
-
"ap-southeast-2": { Ami: "ami-0119aa4d67e59007c" },
|
12
|
-
"ca-central-1": { Ami: "ami-0ff24797826ebbcd5" },
|
13
|
-
"eu-central-1": { Ami: "ami-0d4c3eabb9e72650a" },
|
14
|
-
"eu-north-1": { Ami: "ami-006cda581cf39451b" },
|
15
|
-
"eu-west-1": { Ami: "ami-01f14919ba412de34" },
|
16
|
-
"eu-west-2": { Ami: "ami-05f37c3995fffb4fd" },
|
17
|
-
"eu-west-3": { Ami: "ami-0e9e6ba6d3d38faa8" },
|
18
|
-
"sa-east-1": { Ami: "ami-07820a4443539a2b0" },
|
19
|
-
"us-east-1": { Ami: "ami-00068cd7555f543d5" },
|
20
|
-
"us-east-2": { Ami: "ami-0dacb0c129b49f529" },
|
21
|
-
"us-west-1": { Ami: "ami-0b2d8d1abb76a53d8" },
|
22
|
-
"us-west-2": { Ami: "ami-0c5204531f799e0c6" }
|
23
|
-
)
|
24
|
-
|
25
|
-
resource("Instance", "AWS::EC2::Instance",
|
26
|
-
InstanceType: ref("InstanceType"),
|
27
|
-
ImageId: find_in_map("AmiMap", ref("AWS::Region"), "Ami"),
|
28
|
-
SecurityGroupIds: [get_att("SecurityGroup.GroupId")],
|
29
|
-
UserData: base64(sub(user_data("bootstrap.sh")))
|
30
|
-
)
|
31
|
-
resource("SecurityGroup", "AWS::EC2::SecurityGroup",
|
32
|
-
GroupDescription: "demo security group",
|
33
|
-
)
|
34
|
-
|
35
|
-
output("Instance")
|
36
|
-
output("SecurityGroup", get_att("SecurityGroup.GroupId"))
|
@@ -1 +0,0 @@
|
|
1
|
-
template "<%= blueprint_name %>"
|
@@ -1,67 +0,0 @@
|
|
1
|
-
---
|
2
|
-
AWSTemplateFormatVersion: '2010-09-09'
|
3
|
-
Description: Demo stack
|
4
|
-
Parameters:
|
5
|
-
InstanceType:
|
6
|
-
Default: t3.micro
|
7
|
-
Type: String
|
8
|
-
Mappings:
|
9
|
-
AmiMap:
|
10
|
-
ap-northeast-1:
|
11
|
-
Ami: ami-068a6cefc24c301d2
|
12
|
-
ap-northeast-2:
|
13
|
-
Ami: ami-0d59ddf55cdda6e21
|
14
|
-
ap-south-1:
|
15
|
-
Ami: ami-0ce933e2ae91880d3
|
16
|
-
ap-southeast-1:
|
17
|
-
Ami: ami-07539a31f72d244e7
|
18
|
-
ap-southeast-2:
|
19
|
-
Ami: ami-0119aa4d67e59007c
|
20
|
-
ca-central-1:
|
21
|
-
Ami: ami-0ff24797826ebbcd5
|
22
|
-
eu-central-1:
|
23
|
-
Ami: ami-0d4c3eabb9e72650a
|
24
|
-
eu-north-1:
|
25
|
-
Ami: ami-006cda581cf39451b
|
26
|
-
eu-west-1:
|
27
|
-
Ami: ami-01f14919ba412de34
|
28
|
-
eu-west-2:
|
29
|
-
Ami: ami-05f37c3995fffb4fd
|
30
|
-
eu-west-3:
|
31
|
-
Ami: ami-0e9e6ba6d3d38faa8
|
32
|
-
sa-east-1:
|
33
|
-
Ami: ami-07820a4443539a2b0
|
34
|
-
us-east-1:
|
35
|
-
Ami: ami-00068cd7555f543d5
|
36
|
-
us-east-2:
|
37
|
-
Ami: ami-0dacb0c129b49f529
|
38
|
-
us-west-1:
|
39
|
-
Ami: ami-0b2d8d1abb76a53d8
|
40
|
-
us-west-2:
|
41
|
-
Ami: ami-0c5204531f799e0c6
|
42
|
-
Resources:
|
43
|
-
Instance:
|
44
|
-
Type: AWS::EC2::Instance
|
45
|
-
Properties:
|
46
|
-
InstanceType:
|
47
|
-
Ref: InstanceType
|
48
|
-
ImageId:
|
49
|
-
Fn::FindInMap:
|
50
|
-
- AmiMap
|
51
|
-
- Ref: AWS::Region
|
52
|
-
- Ami
|
53
|
-
SecurityGroupIds:
|
54
|
-
- Fn::GetAtt:
|
55
|
-
- SecurityGroup
|
56
|
-
- GroupId
|
57
|
-
UserData:
|
58
|
-
Fn::Base64:
|
59
|
-
Fn::Sub:
|
60
|
-
- |-
|
61
|
-
#!/bin/bash
|
62
|
-
echo "hello world"
|
63
|
-
- {}
|
64
|
-
SecurityGroup:
|
65
|
-
Type: AWS::EC2::SecurityGroup
|
66
|
-
Properties:
|
67
|
-
GroupDescription: demo security group
|
@@ -1,42 +0,0 @@
|
|
1
|
-
Gem::Specification.new do |spec|
|
2
|
-
spec.name = "<%= configset_name %>"
|
3
|
-
spec.version = "0.1.0"
|
4
|
-
spec.authors = ["<%= user_info[:author] %>"]
|
5
|
-
spec.email = ["<%= ENV['LONO_EMAIL'] || user_info[:email] %>"]
|
6
|
-
|
7
|
-
spec.summary = "Write a short summary because it's required." # TODO: Change me
|
8
|
-
spec.homepage = "<%= ENV['LONO_ORG'] || "https://github.com/USER" %>/<%= configset_name %>"
|
9
|
-
spec.license = "<%= ENV['LONO_LICENSE'] || 'Nonstandard' %>"<%= ENV["LONO_LICENSE_EXTRA"] %>
|
10
|
-
|
11
|
-
# Prevent pushing this gem to RubyGems.org. To allow pushes either set the 'allowed_push_host'
|
12
|
-
# to allow pushing to a single host or delete this section to allow pushing to any host.
|
13
|
-
if spec.respond_to?(:metadata)
|
14
|
-
spec.metadata["lono_type"] = "configset"
|
15
|
-
spec.metadata["lono_strategy"] = "dsl"
|
16
|
-
spec.metadata["allowed_push_host"] = "<%= ENV['LONO_ALLOWED_PUSH_HOST'] || "TODO: Set to 'http://mygemserver.com'"%>"
|
17
|
-
|
18
|
-
spec.metadata["homepage_uri"] = spec.homepage
|
19
|
-
<% if ENV['LONO_ORG'] -%>
|
20
|
-
spec.metadata["source_code_uri"] = "<%= ENV['LONO_ORG'] %>/<%= configset_name %>"
|
21
|
-
spec.metadata["changelog_uri"] = "<%= ENV['LONO_ORG'] %>/<%= configset_name %>/blob/master/CHANGELOG.md"
|
22
|
-
<% else -%>
|
23
|
-
spec.metadata["source_code_uri"] = "https://github.com/user/repo" # TODO: Change me
|
24
|
-
spec.metadata["changelog_uri"] = "https://github.com/user/repo/blob/master/CHANGELOG.md" # TODO: Change me
|
25
|
-
<% end -%>
|
26
|
-
else
|
27
|
-
raise "RubyGems 2.0 or newer is required to protect against public gem pushes."
|
28
|
-
end
|
29
|
-
|
30
|
-
# Specify which files should be added to the gem when it is released.
|
31
|
-
# The `git ls-files -z` loads the files in the RubyGem that have been added into git.
|
32
|
-
spec.files = Dir.chdir(File.expand_path('..', __FILE__)) do
|
33
|
-
`git ls-files -z`.split("\x0").reject { |f| f.match(%r{^(test|spec|features)/}) }
|
34
|
-
end
|
35
|
-
spec.bindir = "exe"
|
36
|
-
spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
|
37
|
-
spec.require_paths = ["lib"]
|
38
|
-
|
39
|
-
spec.add_development_dependency "bundler", "~> 2.0"
|
40
|
-
spec.add_development_dependency "rake", "~> 10.0"
|
41
|
-
spec.add_development_dependency "rspec", "~> 3.0"
|
42
|
-
end
|
@@ -1,46 +0,0 @@
|
|
1
|
-
# coding: utf-8
|
2
|
-
lib = File.expand_path("../lib", __FILE__)
|
3
|
-
$LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
|
4
|
-
require "<%= extension_name %>/version"
|
5
|
-
|
6
|
-
Gem::Specification.new do |spec|
|
7
|
-
spec.name = "<%= extension_name %>"
|
8
|
-
spec.version = <%= extension_class_name %>::VERSION
|
9
|
-
spec.authors = ["<%= user_info[:author] %>"]
|
10
|
-
spec.email = ["<%= ENV['LONO_EMAIL'] || user_info[:email] %>"]
|
11
|
-
spec.summary = "Lono extension: <%= extension_name %>"
|
12
|
-
spec.homepage = "<%= ENV['LONO_ORG'] || "https://github.com/USER" %>/<%= extension_name %>"
|
13
|
-
spec.license = "<%= ENV['LONO_LICENSE'] || 'Nonstandard' %>"<%= ENV["LONO_LICENSE_EXTRA"] %>
|
14
|
-
|
15
|
-
# Prevent pushing this gem to RubyGems.org. To allow pushes either set the 'allowed_push_host'
|
16
|
-
# to allow pushing to a single host or delete this section to allow pushing to any host.
|
17
|
-
if spec.respond_to?(:metadata)
|
18
|
-
spec.metadata["lono_type"] = "extension"
|
19
|
-
spec.metadata["allowed_push_host"] = "<%= ENV['LONO_ALLOWED_PUSH_HOST'] || "TODO: Set to 'http://mygemserver.com'"%>"
|
20
|
-
|
21
|
-
spec.metadata["homepage_uri"] = spec.homepage
|
22
|
-
<% if ENV['LONO_ORG'] -%>
|
23
|
-
spec.metadata["source_code_uri"] = "<%= ENV['LONO_ORG'] %>/<%= extension_name %>"
|
24
|
-
spec.metadata["changelog_uri"] = "<%= ENV['LONO_ORG'] %>/<%= extension_name %>/blob/master/CHANGELOG.md"
|
25
|
-
<% else -%>
|
26
|
-
spec.metadata["source_code_uri"] = "https://github.com/user/repo" # TODO: Change me
|
27
|
-
spec.metadata["changelog_uri"] = "https://github.com/user/repo/blob/master/CHANGELOG.md" # TODO: Change me
|
28
|
-
<% end -%>
|
29
|
-
else
|
30
|
-
raise "RubyGems 2.0 or newer is required to protect against public gem pushes."
|
31
|
-
end
|
32
|
-
|
33
|
-
spec.files = `git ls-files`.split($/)
|
34
|
-
spec.bindir = "exe"
|
35
|
-
spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
|
36
|
-
spec.test_files = spec.files.grep(%r{^(test|spec|features)/})
|
37
|
-
spec.require_paths = ["lib"]
|
38
|
-
|
39
|
-
spec.add_dependency "activesupport", "~> 6"
|
40
|
-
spec.add_dependency "zeitwerk", "~> 2"
|
41
|
-
|
42
|
-
spec.add_development_dependency "bundler", "~> 2"
|
43
|
-
spec.add_development_dependency "byebug", "~> 11"
|
44
|
-
spec.add_development_dependency "rake", "~> 13"
|
45
|
-
spec.add_development_dependency "rspec", "~> 3"
|
46
|
-
end
|