-
Notifications
You must be signed in to change notification settings - Fork 78
/
justfile
76 lines (60 loc) · 2.09 KB
/
justfile
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
set dotenv-load
set export
alias s := ui-serve
alias serve := ui-serve
alias chk := ui-check
alias u := ui-upgrade
# Serve the site for dev usage
ui-serve:
bun run dev
# Build the site for production
ui-build:
bun run build
# Use prettier & biome to format the code
ui-format:
bun run prettier && bun run format
# convert all the images to webp
ui-webp:
bun run webp
# install deps
i:
bun i
# check for outdated deps
ui-outdated:
bun outdated
# check for dependency updates
ui-check:
bun run taze
# upgrade deps
ui-upgrade:
bun run taze latest -u -w && just ui-clean-npm-i
# clear node_modules, bun lock file and reinstall deps
ui-clean-npm-i:
rm -rf node_modules && rm -rf bun.lockb && bun i
# Login to ECR
login:
aws --profile default configure set aws_access_key_id $AWS_ACCESS_KEY_ID
aws --profile default configure set aws_secret_access_key $AWS_SECRET_ACCESS_KEY
aws ecr get-login-password --region $DOCKER_REPO_REGION | docker login --username AWS --password-stdin $DOCKER_REPO
# Build
build:
docker build --platform linux/amd64 -t docs.rocketpool.net:latest .
# Login and deploy to ECR
login-and-deploy:
aws --profile default configure set aws_access_key_id $AWS_ACCESS_KEY_ID
aws --profile default configure set aws_secret_access_key $AWS_SECRET_ACCESS_KEY
aws ecr get-login-password --region $DOCKER_REPO_REGION | docker login --username AWS --password-stdin $DOCKER_REPO
docker build --platform linux/amd64 -t docs.rocketpool.net:latest .
docker tag docs.rocketpool.net:latest $DOCKER_REPO/docs.rocketpool.net:latest
docker push $DOCKER_REPO/docs.rocketpool.net:latest
# Build and deploy to ECR
deploy:
just ui-build
docker build --platform linux/amd64 -t docs.rocketpool.net:latest .
docker tag docs.rocketpool.net:latest $DOCKER_REPO/docs.rocketpool.net:latest
docker push $DOCKER_REPO/docs.rocketpool.net:latest
tag-push:
docker tag docs.rocketpool.net:latest $DOCKER_REPO/docs.rocketpool.net:latest
docker push $DOCKER_REPO/docs.rocketpool.net:latest
rmi:
docker rmi $DOCKER_REPO/docs.rocketpool.net:latest