{"id":15385439,"url":"https://github.com/brianleroux/arc-plugin-custom-domain","last_synced_at":"2026-05-06T07:33:11.591Z","repository":{"id":244864240,"uuid":"816499856","full_name":"brianleroux/arc-plugin-custom-domain","owner":"brianleroux","description":"Setup a custom domain on AWS with Route53 and CloudFront","archived":false,"fork":false,"pushed_at":"2024-06-21T21:11:37.000Z","size":11,"stargazers_count":1,"open_issues_count":1,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-02-02T01:11:35.311Z","etag":null,"topics":["apigateway","aws","cloudfront","lambda","route53","s3","serverless","websockets"],"latest_commit_sha":null,"homepage":"https://arc.codes","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/brianleroux.png","metadata":{"files":{"readme":"readme.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-06-17T22:10:47.000Z","updated_at":"2024-06-21T21:11:40.000Z","dependencies_parsed_at":"2024-06-18T00:04:44.678Z","dependency_job_id":"92d9dc33-28ea-46de-be18-53cd37564000","html_url":"https://github.com/brianleroux/arc-plugin-custom-domain","commit_stats":{"total_commits":6,"total_committers":1,"mean_commits":6.0,"dds":0.0,"last_synced_commit":"e1b6a7b1d7acf113211a5c1c1373b3ff62d5b638"},"previous_names":["brianleroux/arc-plugin-custom-domain"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/brianleroux%2Farc-plugin-custom-domain","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/brianleroux%2Farc-plugin-custom-domain/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/brianleroux%2Farc-plugin-custom-domain/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/brianleroux%2Farc-plugin-custom-domain/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/brianleroux","download_url":"https://codeload.github.com/brianleroux/arc-plugin-custom-domain/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":245937975,"owners_count":20696989,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["apigateway","aws","cloudfront","lambda","route53","s3","serverless","websockets"],"created_at":"2024-10-01T14:44:45.870Z","updated_at":"2026-05-06T07:33:11.560Z","avatar_url":"https://github.com/brianleroux.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# arc-plugin-custom-domain\n\nThis is a plugin for https://arc.codes to help setup a custom domain on CloudFront without pain!\n\nFeatures:\n\n- Creates all the necessary resources for a CloudFront CDN distribution\n- Optionally create DNS records in Route53 including an automatically verified certificate in ACM\n- Automatically detects `@ws` and adds magic same-origin route for `_/wss`; this enables session sharing to web socket lambda functions\n\n# Usage\n\n```bash\nnpm install arc-plugin-custom-domain\n```\n\n- If you want to use Route53 then use `@dns`\n- If you want to manage your DNS elsewhere then use `@cdn`\n\n\u003e [!IMPORTANT]\n\u003e To use this plugin your application must be deployed in `us-east-1`. This is a limitation of how CloudFront works with API Gateway and ACM Certificates.\n\n\u003e [!NOTE]\n\u003e This plugin requires a URLs to exist *before* you use it. Make sure you've deployed at least once before using this plugin with `arc deploy` and `arc deploy --production` respectively.\n\n\u003e [!WARNING]\n\u003e This plugin will fail if used with an app that has never been deployed. You need to deploy the stack at least once before using this plugin. (API Gateway cannot create a domain mapping until it has been deployed at least once.)\n\n## `@dns`\n\nCreates a CloudFront distribution, Route53 A alias record and ACM Certificate automatically; you need to specify `domain` and `zone` for the HostedZoneId. Buying/importing a domain w Route53 should automatically setup a HostedZone for you.\n\nExample:\n\n```\n@app\nmyapp\n\n@aws\nregion us-east-1\n\n@http\n\n@plugins\narc-plugin-custom-domain\n\n@dns\nstaging b4.example.com\nproduction example.com\nzone XKDISW7D\n```\n\n## `@cdn`\n\nCreates a Cloudfront distribution; you need to specify `staging` domain, `production` domain and `cert` with an ACM Certificate ARN.\n\nRequirements:\n\n- Create a certificate and verify it in ACM (AWS Certificate Manager) console in `us-east-1` (ensure you set not only domain `example.com` but also add `*.domain.com` so same cert can be used for staging\n- After deployment; create an A record in your DNS registrar to point to the generated CloudFront distribution (look AWS CloudFront console to find this)\n\nExample:\n\n```\n@app\nmyapp\n\n@aws\nregion us-east-1\n\n@http\n\n@plugins\narc-plugin-custom-domain\n\n@cdn\nstaging b4.example.com\nproduction example.com\ncert arn:aws:acm:us-east-1:555:certificate/xxx\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbrianleroux%2Farc-plugin-custom-domain","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbrianleroux%2Farc-plugin-custom-domain","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbrianleroux%2Farc-plugin-custom-domain/lists"}