Skip to content
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

Add support for links to resources #62

Open
tobywf opened this issue Oct 31, 2018 · 3 comments
Open

Add support for links to resources #62

tobywf opened this issue Oct 31, 2018 · 3 comments

Comments

@tobywf
Copy link
Contributor

tobywf commented Oct 31, 2018

Add an e.g. deepLink property to the schema that allows generating links to a resource given identifiers. This is useful for the console.

@tobywf
Copy link
Contributor Author

tobywf commented Feb 11, 2019

Example from EC2 in the deeplink package:

image({ region }) {
  return `/ec2/v2/home?region=${region}#Images:sort=name`
},
instance({ region, resource }) {
  return `/ec2/home?region=${region}#Instances:instanceId=${resource}`;
},

@tobywf
Copy link
Contributor Author

tobywf commented Mar 11, 2019

Proposal for adding this to a schema:

{
   [...]
  "deeplink": {
    "mapping": {
      "instanceId": "#/InstanceId"
    },
    "template": "https://{region}.console.aws.amazon.com/ec2/v2/home?region={region}#Instances:instanceId=${instanceId}"
  }
}

where mapping maps a simple key to a JSON pointer (URI fragment or not?) which can be applied to a resource blob, or empty if not required. global variables like region don't need to be mapped.

Open questions:

  • relative vs absolute URL (think of partner resources)
  • HTTPS only
  • which global vars
  • template syntax
  • JSON pointers are URI fragment representation or vanilla

@tobywf tobywf closed this as completed Mar 20, 2019
@johnttompkins johnttompkins reopened this Nov 27, 2019
@johnttompkins
Copy link
Contributor

going to move this to the schema repo for better tracking

@johnttompkins johnttompkins transferred this issue from aws-cloudformation/cloudformation-cli Nov 27, 2019
@tobywf tobywf mentioned this issue Dec 13, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants