-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathcopier.yml
More file actions
190 lines (165 loc) · 5.67 KB
/
copier.yml
File metadata and controls
190 lines (165 loc) · 5.67 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
# Copier configuration/questions for "SFU fullstack project template"
_templates_suffix: ""
_tasks:
- python tasks.py
_subdirectory: template
copier__project_name_raw:
type: str
default: "My Awesome Scaf Project"
help: "The name of your project."
validator: >-
{% if not copier__project_name_raw.strip() %}
"Project name cannot be empty."
{% endif %}
copier__project_name:
type: str
default: "{{ copier__project_name_raw | replace(\"'\", \"\") | replace('\"', '') }}"
when: false
copier__project_slug:
type: str
default: "{{ is_project_slug if is_project_slug else copier__project_name.lower().replace(' ', '_').replace('-', '_').replace('.', '_').strip() }}"
help: "The project slug derived from the project name."
validator: >-
{% if not copier__project_slug.isidentifier() %}
"'{{ copier__project_slug }}' is not a valid Python identifier."
{% elif copier__project_slug != copier__project_slug.lower() %}
"'{{ copier__project_slug }}' must be all lowercase."
{% elif not copier__project_slug.strip() %}
"Project slug cannot be empty."
{% endif %}
copier__project_dash:
type: str
default: "{{ copier__project_slug.lower().replace(' ', '-').replace('_', '-').replace('.', '-').strip() }}"
help: "The project name in dash-separated format."
when: false
copier__rfc1123_subdomain:
type: str
default: "{{ copier__project_slug.lower().replace('_', '-') | regex_replace('[^a-z0-9-]', '') }}"
help: "A RFC 1123 compliant version of the project slug."
when: false
copier__description:
type: str
default: "Behold My Awesome Project!"
help: "A brief description of your project."
validator: >-
{% if not copier__description.strip() %}
"Description cannot be empty."
{% endif %}
copier__author_name:
type: str
default: "Joe Scaf"
help: "The name of the author."
validator: >-
{% if "\\" in copier__author_name %}
"Backslashes ('\\') are not allowed in the author name."
{% elif not copier__author_name.strip() %}
"Author name cannot be empty."
{% elif not copier__author_name.replace(" ", "").replace("-", "").replace("'", "").isalpha() %}
"'{{ copier__author_name }}' should contain only alphabetic characters, spaces, hyphens, and apostrophes."
{% endif %}
copier__domain_name:
type: str
default: "sixfeetup.com"
help: "The domain name associated with the project."
validator: >-
{% if not copier__domain_name.strip() %}
"Domain name cannot be empty."
{% endif %}
copier__existing_hosted_zone:
type: str
default: ""
help: "Enter the existing hosted zone name if you want to reuse one (e.g., domain.tld for subdomain.domain.tld projects). Leave empty to create a new hosted zone."
validator: >-
{% if copier__existing_hosted_zone.strip() and not copier__domain_name.endswith("." + copier__existing_hosted_zone) %}
"The domain name '{{ copier__domain_name }}' must be a subdomain of the hosted zone '{{ copier__existing_hosted_zone }}'"
{% endif %}
copier__email:
type: str
default: "{{ copier__author_name.lower().replace(' ', '-') }}@{{ copier__domain_name }}"
help: "The author's email address."
validator: >-
{% if not copier__email.strip() %}
"Email cannot be empty."
{% elif "@" not in copier__email %}
"'{{ copier__email }}' is not a valid email address."
{% endif %}
copier__version:
type: str
default: "0.1.0"
help: "The initial version of the project."
validator: >-
{% if not copier__version.strip() %}
"Version cannot be empty."
{% endif %}
copier__timezone:
type: str
default: "America/New_York"
help: "The default timezone for the project."
validator: >-
{% if not copier__timezone.strip() %}
"Timezone cannot be empty."
{% endif %}
copier__aws_region:
type: str
default: "us-east-1"
help: "AWS region for deployment."
validator: >-
{% if not copier__aws_region.strip() %}
"AWS region cannot be empty."
{% endif %}
copier__aws_account_id:
type: str
default: "000000000000"
help: "AWS account ID for deployment."
validator: >-
{% if not copier__aws_account_id.strip() %}
"AWS account ID cannot be empty."
{% endif %}
copier__create_nextjs_frontend:
type: bool
default: true
help: "Do you want to create a Next.js frontend? (y/n) [default: Yes]"
copier__mail_service:
type: str
default: "Amazon SES"
choices:
- "Mailgun"
- "Amazon SES"
- "Other SMTP"
help: "Which mail service do you want to use?"
when: false
copier__operating_system:
type: str
default: "k3s"
choices:
k3s: "k3s"
talos: "talos"
help: "Deploy Kubernetes on k3s running on Ubuntu or on Talos Linux?"
copier__use_celery:
type: bool
default: false
help: "Do you want to use Celery for task management? (y/n) [default: No]"
copier__use_sentry:
type: bool
default: false
help: "Do you want to integrate Sentry for error tracking? (y/n) [default: No]"
copier__repo_url:
type: str
default: "git@github.com:organization_name/{{ copier__project_slug }}.git"
help: "The URL of the repository."
validator: >-
{% if not copier__repo_url.startswith("git@") or not ":" in copier__repo_url or not "/" in copier__repo_url.split(":")[1] or not ".git" in copier__repo_url %}
Value must follow the format git@provider:orgname/repo.git
{% endif %}
copier__source_control_provider:
type: str
when: false
default: "{{ copier__repo_url.split('@')[1].split(':')[0] }}"
copier__source_control_organization_slug:
type: str
when: false
default: "{{ copier__repo_url.split(':')[1].split('/')[0] }}"
copier__repo_name:
type: str
when: false
default: "{{ copier__repo_url.split(':')[1].split('/')[1].replace('.git', '') }}"