4 Commits

46 changed files with 110 additions and 1 deletions

75
.github/workflows/deploy.yml vendored Normal file
View File

@@ -0,0 +1,75 @@
name: Deploy to Production
on:
push:
branches: [ "main" ]
env:
REGISTRY: ghcr.io
IMAGE_NAME: ${{ github.repository }}
jobs:
build-and-push:
runs-on: ubuntu-latest
permissions:
contents: read
packages: write
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Log in to the Container registry
uses: docker/login-action@v3
with:
registry: ${{ env.REGISTRY }}
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Extract metadata (tags, labels) for Docker
id: meta
uses: docker/metadata-action@v5
with:
images: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}
tags: |
type=raw,value=latest
type=sha
- name: Build and push Docker image
uses: docker/build-push-action@v5
with:
context: .
push: true
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}
deploy:
runs-on: ubuntu-latest
needs: build-and-push
steps:
- name: Deploy to Remote Server
uses: appleboy/ssh-action@v1.0.3
with:
host: ${{ secrets.REMOTE_HOST }}
username: ${{ secrets.REMOTE_USER }}
key: ${{ secrets.SSH_PRIVATE_KEY }}
script: |
# Login to registry
echo ${{ secrets.GITHUB_TOKEN }} | docker login ghcr.io -u ${{ github.actor }} --password-stdin
# Pull new image
docker pull ghcr.io/${{ env.IMAGE_NAME }}:latest
# Stop and remove existing container
docker stop resume-frontend || true
docker rm resume-frontend || true
# Run new container
docker run -d \
--name resume-frontend \
--restart unless-stopped \
-p 80:80 \
ghcr.io/${{ env.IMAGE_NAME }}:latest
# Cleanup unused images
docker image prune -f

2
.gitignore vendored
View File

@@ -24,4 +24,4 @@ yarn-error.log*
.env .env
#public facing Images #public facing Images
/public # /public

20
Dockerfile Normal file
View File

@@ -0,0 +1,20 @@
# Build stage
FROM node:18-alpine as build
WORKDIR /app
COPY package*.json ./
RUN npm ci
COPY . .
RUN npm run build
# Production stage
FROM nginx:alpine
COPY --from=build /app/build /usr/share/nginx/html
COPY nginx.conf /etc/nginx/conf.d/default.conf
EXPOSE 80
CMD ["nginx", "-g", "daemon off;"]

14
nginx.conf Normal file
View File

@@ -0,0 +1,14 @@
server {
listen 80;
location / {
root /usr/share/nginx/html;
index index.html index.htm;
try_files $uri $uri/ /index.html;
}
error_page 500 502 503 504 /50x.html;
location = /50x.html {
root /usr/share/nginx/html;
}
}

BIN
public/1647091917916.jpeg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 24 KiB

BIN
public/1647091917916.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 185 KiB

BIN
public/20251111_224823.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.7 MiB

BIN
public/20251111_224833.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.5 MiB

BIN
public/20251111_224848.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.6 MiB

BIN
public/20251111_224859.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.5 MiB

BIN
public/20251111_224959.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.7 MiB

BIN
public/20251111_225017.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.7 MiB

BIN
public/20251111_225025.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.5 MiB

BIN
public/20251112_223733.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.6 MiB

BIN
public/20251112_223743.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.7 MiB

BIN
public/20251112_223748.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.6 MiB

BIN
public/20251112_223756.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.7 MiB

BIN
public/20251112_223813.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.6 MiB

BIN
public/20251112_223820.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.6 MiB

BIN
public/20251112_223834.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.6 MiB

BIN
public/20251112_223852.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.6 MiB

BIN
public/20251112_224119.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.8 MiB

BIN
public/20251112_224125.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.7 MiB

BIN
public/20251112_224134.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.7 MiB

BIN
public/20251112_224150.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.8 MiB

BIN
public/20251112_224156.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.8 MiB

BIN
public/20251112_224236.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 9.2 MiB

BIN
public/20251112_224246.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 9.3 MiB

BIN
public/20251112_224411.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.8 MiB

BIN
public/20251112_224416.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.5 MiB

BIN
public/20251112_224420.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.6 MiB

BIN
public/20251112_224435.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 893 KiB

BIN
public/20251112_224437.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 783 KiB

BIN
public/20251123_233533.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 752 KiB

BIN
public/20251123_233541.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 718 KiB

BIN
public/20251123_233608.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.9 MiB

BIN
public/20251123_233616.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.9 MiB

BIN
public/20251123_233625.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.9 MiB

BIN
public/20251123_233643.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.8 MiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 11 KiB

BIN
public/dapperSasha.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 124 KiB

BIN
public/digitCode.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 130 KiB

BIN
public/homedepot.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 71 KiB

BIN
public/metaImage.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 20 KiB

BIN
public/nutrien.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 86 KiB

BIN
public/towerglass.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 13 KiB