Skip to content

Commit abf4399

Browse files
authored
Merge branch 'main' into aryan
2 parents f6002b1 + 28b34f1 commit abf4399

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

46 files changed

+1913
-488
lines changed

.devcontainer/Dockerfile

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,3 +16,7 @@ COPY --chown=${USERNAME}:${USERNAME} config ${HOME}
1616
# && apt-get autoremove -y \
1717
# && apt-get clean -y \
1818
# && rm -rf /var/lib/apt/lists/{apt,dpkg,cache,log} /tmp/* /var/tmp/*
19+
20+
# set user and working directory
21+
USER ${USERNAME}
22+
WORKDIR ${ROS_WORKSPACE}

.devcontainer/base-dev/README.md

Lines changed: 1 addition & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -62,23 +62,9 @@ If you want to push this to GitHub (instead of using the slow Build Images workf
6262
6363
1. Login to the GitHub container registry: [Authenticating with a personal access token (classic)](https://docs.github.com/en/packages/working-with-a-github-packages-registry/working-with-the-container-registry#authenticating-with-a-personal-access-token-classic)
6464
65-
2. Push each image, replacing `<tag>` with the desired tag in the commands below
65+
2. Push the image, replacing `<tag>` with the desired tag in the command below
6666
6767
```
68-
docker buildx build . \
69-
--file base-dev.Dockerfile \
70-
--tag ghcr.io/ubcsailbot/sailbot_workspace/base:<tag> \
71-
--platform linux/arm64,linux/amd64 \
72-
--builder sailbot \
73-
--target base \
74-
--push
75-
docker buildx build . \
76-
--file base-dev.Dockerfile \
77-
--tag ghcr.io/ubcsailbot/sailbot_workspace/local-base:<tag> \
78-
--platform linux/arm64,linux/amd64 \
79-
--builder sailbot \
80-
--target local-base \
81-
--push
8268
docker buildx build . \
8369
--file base-dev.Dockerfile \
8470
--tag ghcr.io/ubcsailbot/sailbot_workspace/dev:<tag> \

.devcontainer/docker-compose.yml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ services:
55
build:
66
context: .
77
dockerfile: Dockerfile
8+
user: ros
89
ports:
910
# website
1011
- "3005:3005"
@@ -27,7 +28,7 @@ services:
2728

2829
# URL: mongodb://localhost:27017
2930
mongodb:
30-
image: mongo:7
31+
image: mongo:${MONGO_TAG:-4.4.18}
3132
restart: unless-stopped
3233
volumes:
3334
- mongodb-data:/data/db:delegated

.devcontainer/website/docker-compose.website.prod.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,9 +8,11 @@ services:
88
volumes:
99
- ../src/website:/website:cached
1010
- website-node-modules:/website/node_modules:delegated
11+
- website-tests-node-modules:/website/tests/node_modules:delegated
1112

1213
# Runs on the same network as the workspace container, allows "forwardPorts" in devcontainer.json function.
1314
network_mode: service:sailbot-workspace
1415

1516
volumes:
1617
website-node-modules:
18+
website-tests-node-modules:

.devcontainer/website/docker-compose.website.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,9 +8,11 @@ services:
88
volumes:
99
- ../src/website:/website:cached
1010
- website-node-modules:/website/node_modules:delegated
11+
- website-tests-node-modules:/website/tests/node_modules:delegated
1112

1213
# Runs on the same network as the workspace container, allows "forwardPorts" in devcontainer.json function.
1314
network_mode: service:sailbot-workspace
1415

1516
volumes:
1617
website-node-modules:
18+
website-tests-node-modules:

.github/dependabot.yml

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,11 +9,17 @@ updates:
99
directory: "/" # Location of package manifests
1010
schedule:
1111
interval: "weekly"
12+
# Disable dependabot for website dependencies
1213
- package-ecosystem: "npm"
13-
directory: "/"
14+
directory: "/src/website"
15+
schedule:
16+
interval: "weekly"
17+
open-pull-requests-limit: 0
18+
# Disable dependabot for website test dependencies
19+
- package-ecosystem: "npm"
20+
directory: "/src/website/tests"
1421
schedule:
1522
interval: "weekly"
16-
# Disable all pull requests for npm dependencies
1723
open-pull-requests-limit: 0
1824
# # Create a group of dependencies to be updated together in one pull request
1925
# groups:

.github/workflows/build-images.yml

Lines changed: 6 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,9 @@ on:
44
workflow_dispatch:
55
inputs:
66
tag:
7-
description: 'Tag of the base, local-base, and dev images'
8-
required: false
7+
description: 'Tag of the Docker image'
8+
required: true
99
type: string
10-
default: 'main'
1110

1211
concurrency:
1312
group: ${{ github.workflow }}-${{ github.ref }}
@@ -34,37 +33,15 @@ jobs:
3433
username: ${{ github.actor }}
3534
password: ${{ secrets.PAT_TOKEN }}
3635

37-
- name: Build and push base
38-
uses: docker/build-push-action@v5
39-
with:
40-
context: "{{defaultContext}}:.devcontainer/base-dev"
41-
file: base-dev.Dockerfile
42-
push: true
43-
tags: ghcr.io/ubcsailbot/sailbot_workspace/base:${{ inputs.tag }}
44-
platforms: linux/arm64,linux/amd64
45-
cache-from: type=gha
46-
cache-to: type=gha,mode=max
47-
target: base
48-
49-
- name: Build and push local-base
50-
uses: docker/build-push-action@v5
51-
with:
52-
context: "{{defaultContext}}:.devcontainer/base-dev"
53-
file: base-dev.Dockerfile
54-
push: true
55-
tags: ghcr.io/ubcsailbot/sailbot_workspace/local-base:${{ inputs.tag }}
56-
platforms: linux/arm64,linux/amd64
57-
cache-from: type=gha
58-
cache-to: type=gha,mode=max
59-
target: local-base
60-
6136
- name: Build and push dev
62-
uses: docker/build-push-action@v5
37+
uses: docker/build-push-action@v6
6338
with:
6439
context: "{{defaultContext}}:.devcontainer/base-dev"
6540
file: base-dev.Dockerfile
6641
push: true
67-
tags: ghcr.io/ubcsailbot/sailbot_workspace/dev:${{ inputs.tag }}
42+
tags: |
43+
ghcr.io/ubcsailbot/sailbot_workspace/dev:${{ inputs.tag }}
44+
ghcr.io/ubcsailbot/sailbot_workspace/dev:latest
6845
platforms: linux/arm64,linux/amd64
6946
cache-from: type=gha
7047
cache-to: type=gha,mode=max

.markdown-link-check.json

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,5 +21,7 @@
2121
{
2222
"pattern": "^https://linuxize.com*"
2323
}
24-
]
24+
],
25+
26+
"aliveStatusCodes": [403, 200]
2527
}

mkdocs.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ site_author: UBCSailbot Software Team
66
# Repository
77
repo_name: UBCSailbot/sailbot_workspace
88
repo_url: https://github.com/UBCSailbot/sailbot_workspace
9-
edit_uri: "edit/main/sailbot_workspace/"
9+
edit_uri: "edit/main/docs/"
1010

1111
# Configuration
1212
theme:

sailbot.code-workspace

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -420,7 +420,7 @@
420420
"label": "purge",
421421
"detail": "Purge workspace by deleting all generated files.",
422422
"type": "shell",
423-
"command": "rm -fr build install log; py3clean .",
423+
"command": "sudo rm -rf build install log; py3clean .",
424424
"problemMatcher": []
425425
},
426426
// Linting and static code analysis tasks

0 commit comments

Comments
 (0)