Skip to content

Commit

Permalink
separate the large files from the other assets
Browse files Browse the repository at this point in the history
  • Loading branch information
squi-ddy committed Dec 23, 2023
1 parent 3c4fe9b commit 31a30c7
Show file tree
Hide file tree
Showing 31 changed files with 72 additions and 13 deletions.
1 change: 1 addition & 0 deletions .dockerignore
Original file line number Diff line number Diff line change
Expand Up @@ -5,3 +5,4 @@
dist/
docs/
node_modules/
static-large/
13 changes: 13 additions & 0 deletions .github/workflows/docker.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ jobs:
# node-version: 16.19.0
# - run: npm run genrss
- uses: actions/checkout@v2

- name: Push image to AppVenture registry
uses: docker/build-push-action@v1
with:
Expand All @@ -27,3 +28,15 @@ jobs:
registry: registry.nush.app
repository: appventure-website-v4
tags: latest
path: .
build_args: STATIC_URL=https://large.nush.app

- name: Push large static files image to AppVenture registry
uses: docker/build-push-action@v1
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
registry: registry.nush.app
repository: appventure-website-v4
tags: static-latest
path: ./static-large
6 changes: 6 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,12 @@ COPY package.json .
COPY yarn.lock .
RUN yarn install --frozen-lockfile
COPY . .
# replace the values in constants.ts
ARG STATIC_URL
ENV STATIC_URL ${STATIC_URL}
RUN apt-get update && apt-get install -y gettext-base
RUN envsubst < src/constants.ts > src/constants.ts.tmp
RUN mv src/constants.ts.tmp src/constants.ts
RUN yarn run gridsome build

FROM nginx:alpine-slim AS deploy
Expand Down
Binary file removed content/projects/astrosim/AstroSim-linux.jar
Binary file not shown.
Binary file removed content/projects/astrosim/AstroSim-macos.jar
Binary file not shown.
2 changes: 1 addition & 1 deletion content/projects/astrosim/main.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,6 @@ gallery:
- ./astrosim2.png
- ./astrosim3.png
achievements:
attachment: ./astrosim.zip
attachment: astrosim.zip
website:
featured: false
2 changes: 1 addition & 1 deletion content/projects/boids-simulation/main.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,6 @@ gallery:
- ./1.png
- ./2.png
achievements:
attachment: ./boids-simulation.zip
attachment: boids-simulation.zip
website:
featured: false
2 changes: 1 addition & 1 deletion content/projects/ch4/main.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,6 @@ gallery:
- ./0.png
- ./1.png
achievements:
attachment: ./ch4.zip
attachment: ch4.zip
website:
featured: false
2 changes: 1 addition & 1 deletion content/projects/contagion/main.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,6 @@ gallery:
- ./Screenshot2.png
- ./Screenshot3.png
achievements:
attachment: ./contagion.zip
attachment: contagion.zip
website:
featured: false
2 changes: 1 addition & 1 deletion content/projects/guardians-of-earth/main.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -23,4 +23,4 @@ gallery:
- ./83ba42aedcf1244700f76c05159f5343.png
achievements:
- Champion, Singapore Games Creation Competition, 2017
attachment: ./guardianofearthexe.zip
attachment: guardianofearthexe.zip
2 changes: 1 addition & 1 deletion content/projects/health-bot/main.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -18,4 +18,4 @@ gallery:
- ./gameplay.png
- ./note.png
- ./event.png
attachment: ./operation-health-healthbot.zip
attachment: operation-health-healthbot.zip
2 changes: 1 addition & 1 deletion content/projects/kito/main.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,6 @@ gallery:
- ./kito1.png
- ./kito3.png
achievements:
attachment: ./kito.apk
attachment: kito.apk
website:
featured: false
2 changes: 1 addition & 1 deletion content/projects/lead-tools/main.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -26,4 +26,4 @@ gallery:
- ./pic4.png
- ./pic5.png
- ./pic6.png
attachment: ./leadtools.jar
attachment: leadtools.jar
2 changes: 1 addition & 1 deletion content/projects/securus/main.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -26,4 +26,4 @@ gallery:
- ./621658893965615209823006296463120118317056n.jpg
- ./6538682320577126245383137946313844110917632n.jpg
- ./657496317503635920334904520356433685905408n.jpg
attachment: ./app-debug.apk
attachment: securus.apk
2 changes: 1 addition & 1 deletion content/projects/sudokupp/main.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,6 @@ gallery:
- ./2.png
- ./3.png
achievements:
attachment: ./sudoku++.zip
attachment: sudoku++.zip
website:
featured: false
2 changes: 1 addition & 1 deletion doc/archetypes/project.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,6 @@ gallery:
- ./file1.xxx
achievements:
- achievement, YYYY
attachment: ./file.xxx
attachment: file.xxx
website: https://example.com
featured: false
17 changes: 17 additions & 0 deletions docker-compose.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
version: "3.8"

services:
web:
build:
context: .
args:
- STATIC_URL=http://localhost:5001
ports:
- "5000:80"
depends_on:
- static
static:
build:
context: ./static-large
ports:
- "5001:3000"
1 change: 1 addition & 0 deletions src/constants.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
export const STATIC_URL = "$STATIC_URL";
Loading

0 comments on commit 31a30c7

Please sign in to comment.