Skip to content
Merged

pull #16

Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
56 commits
Select commit Hold shift + click to select a range
3b413fa
Merge pull request #8 from nsvk13/dev
nsvk13 May 1, 2025
ae7cfde
ci: fix missing string docker
nsvk13 May 1, 2025
43a125a
ci: fix building image
nsvk13 May 1, 2025
9160738
ci: fix push docker image
nsvk13 May 1, 2025
ce3a3d0
gay fix
nsvk13 May 1, 2025
aed6a8e
ci: fix deployment docker image
nsvk13 May 1, 2025
801d599
Initial commit
nsvk13 May 21, 2025
828ddcd
fix build
nsvk13 May 21, 2025
91efe57
added packages
nsvk13 May 25, 2025
4a97ed7
chore: add highlight.js module
nsvk13 May 25, 2025
48d3015
feat: refactore & new feathure
nsvk13 May 25, 2025
906cb74
feat: refactore & new feathure
nsvk13 May 25, 2025
a43d7c8
feat: refactore & new feathure
nsvk13 May 25, 2025
c829824
Initial constants
nsvk13 May 25, 2025
b09f1a3
feat: refactore & new feathure
nsvk13 May 25, 2025
6422420
docs: initial tag
nsvk13 May 25, 2025
0313295
docs: init test
nsvk13 May 25, 2025
f1e6edf
fuck legacy
nsvk13 May 25, 2025
87a90bf
refactor
nsvk13 May 25, 2025
2168d91
package
nsvk13 May 25, 2025
4f68da6
style: clearning comments
nsvk13 May 25, 2025
11c5f87
chore: change something metadata
nsvk13 May 25, 2025
9fa4572
docker: initial Dockerfiles
nsvk13 May 25, 2025
2a56bdb
docs: initial README.md
nsvk13 May 25, 2025
83651da
blog: push article
nsvk13 May 25, 2025
bc12711
blog: push article
nsvk13 May 25, 2025
4efae56
docs: big dick docs
nsvk13 Jun 7, 2025
2f972b0
docs: super dick commit
nsvk13 Jun 7, 2025
e26199d
1136
nsvk13 Jun 7, 2025
1cf0528
Merge pull request #10 from nsvk13/9-sdf
nsvk13 Jun 7, 2025
7f1619d
del
nsvk13 Jun 7, 2025
308c43e
del
nsvk13 Jun 12, 2025
b683554
style: change time reading
nsvk13 Jun 12, 2025
2afa3e9
blog: initial `tuning-nginx` article
nsvk13 Jun 12, 2025
ef4c288
feat: add webring widget
nsvk13 Jun 16, 2025
2b3c91b
Merge pull request #12 from nsvk13/codex/add-webring-to-footer
nsvk13 Jun 16, 2025
6c061c4
Merge pull request #13 from nsvk13/11-feat-add-webring-buttons
nsvk13 Jun 16, 2025
6b8bebe
feat: fix text duplicate with "alt" tag
nsvk13 Jun 19, 2025
84528d9
blog: delete article
nsvk13 Jul 7, 2025
72bc91f
blog: add devops tag for 'tuning-nginx' article
nsvk13 Jul 7, 2025
6e8ce2c
del
nsvk13 Jul 8, 2025
bda40af
feat: remove webring component
nsvk13 Jul 13, 2025
2f03539
feat: remove webring component
nsvk13 Jul 13, 2025
ce25f1e
feat: styles for cv page
nsvk13 Jul 26, 2025
42ec5fa
feat: add new route and small change tech stack
nsvk13 Jul 26, 2025
beae56d
feat: create cv page
nsvk13 Jul 26, 2025
3439409
feat: create cv client render
nsvk13 Jul 26, 2025
73612ec
cv (wip): initial english cv
nsvk13 Jul 26, 2025
d8a2769
cv (wip): initial russian cv
nsvk13 Jul 26, 2025
e86457d
feat: created lib for cv
nsvk13 Jul 26, 2025
cca7d44
ci: auto build and project release
nsvk13 Jul 26, 2025
c7f88bb
blog: add `golang-string` post
nsvk13 Oct 16, 2025
6fa9aa5
feat: add head meta tag for Telegram Instant view
nsvk13 Oct 16, 2025
9c48251
blog: add fake posts for get Telegram Instant View
nsvk13 Oct 16, 2025
3b09207
blog: add test-instant-view
nsvk13 Oct 16, 2025
06ed07a
blog: delete posts
nsvk13 Oct 18, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 0 additions & 9 deletions .dockerignore

This file was deleted.

3 changes: 0 additions & 3 deletions .eslintrc.json

This file was deleted.

27 changes: 0 additions & 27 deletions .github/ISSUE_TEMPLATE/bug_report.md

This file was deleted.

22 changes: 0 additions & 22 deletions .github/ISSUE_TEMPLATE/feature_request.md

This file was deleted.

59 changes: 0 additions & 59 deletions .github/workflows/ci.yml

This file was deleted.

36 changes: 0 additions & 36 deletions .github/workflows/deploy.yml

This file was deleted.

105 changes: 105 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,105 @@
name: Build and Release

on:
push:
branches: [ main ]

jobs:
release:
runs-on: ubuntu-latest
permissions:
contents: write

steps:
- name: Checkout code
uses: actions/checkout@v4
with:
fetch-depth: 0

- name: Setup Bun
uses: oven-sh/setup-bun@v1
with:
bun-version: latest

- name: Install and build
run: |
bun install --frozen-lockfile
bun run build

- name: Get version
id: version
run: |
# Получаем последний тег
LAST_TAG=$(git describe --tags --abbrev=0 2>/dev/null || echo "v0.0.0")

# Парсим версию
VERSION=${LAST_TAG#v}
IFS='.' read -ra VERSION_PARTS <<< "$VERSION"
MAJOR=${VERSION_PARTS[0]:-0}
MINOR=${VERSION_PARTS[1]:-0}
PATCH=${VERSION_PARTS[2]:-0}

# Просто инкрементим patch
PATCH=$((PATCH + 1))
NEW_VERSION="v$MAJOR.$MINOR.$PATCH"

echo "version=$NEW_VERSION" >> $GITHUB_OUTPUT
echo "version_no_v=$MAJOR.$MINOR.$PATCH" >> $GITHUB_OUTPUT

- name: Create archives
run: |
mkdir -p release

# Исходники
mkdir -p release/nsvk13-${{ steps.version.outputs.version_no_v }}
rsync -av \
--exclude='.git' \
--exclude='.github' \
--exclude='node_modules' \
--exclude='release' \
--exclude='.env*' \
--exclude='*.log' \
. release/nsvk13-${{ steps.version.outputs.version_no_v }}/

# Только build
mkdir -p release/nsvk13-build-${{ steps.version.outputs.version_no_v }}
cp -r .next release/nsvk13-build-${{ steps.version.outputs.version_no_v }}/
cp -r public release/nsvk13-build-${{ steps.version.outputs.version_no_v }}/
cp package.json release/nsvk13-build-${{ steps.version.outputs.version_no_v }}/
cp next.config.mjs release/nsvk13-build-${{ steps.version.outputs.version_no_v }}/

cd release

# Архивы
tar -czf nsvk13-${{ steps.version.outputs.version_no_v }}.tar.gz nsvk13-${{ steps.version.outputs.version_no_v }}/
zip -r nsvk13-${{ steps.version.outputs.version_no_v }}.zip nsvk13-${{ steps.version.outputs.version_no_v }}/
tar -czf nsvk13-build-${{ steps.version.outputs.version_no_v }}.tar.gz nsvk13-build-${{ steps.version.outputs.version_no_v }}/
zip -r nsvk13-build-${{ steps.version.outputs.version_no_v }}.zip nsvk13-build-${{ steps.version.outputs.version_no_v }}/

- name: Create Release
uses: softprops/action-gh-release@v1
with:
tag_name: ${{ steps.version.outputs.version }}
name: "Release ${{ steps.version.outputs.version }}"
body: |
## nsvk13.dev ${{ steps.version.outputs.version }}

**Archives:**
- `nsvk13-${{ steps.version.outputs.version_no_v }}.tar.gz` - Source code
- `nsvk13-${{ steps.version.outputs.version_no_v }}.zip` - Source code
- `nsvk13-build-${{ steps.version.outputs.version_no_v }}.tar.gz` - Build only
- `nsvk13-build-${{ steps.version.outputs.version_no_v }}.zip` - Build only

**Deploy:**
```bash
curl -L https://github.com/${{ github.repository }}/releases/download/${{ steps.version.outputs.version }}/nsvk13-${{ steps.version.outputs.version_no_v }}.tar.gz | tar -xz
cd nsvk13-${{ steps.version.outputs.version_no_v }}
bun install && bun run start
```
files: |
release/nsvk13-${{ steps.version.outputs.version_no_v }}.tar.gz
release/nsvk13-${{ steps.version.outputs.version_no_v }}.zip
release/nsvk13-build-${{ steps.version.outputs.version_no_v }}.tar.gz
release/nsvk13-build-${{ steps.version.outputs.version_no_v }}.zip
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
18 changes: 2 additions & 16 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,16 +2,6 @@

# dependencies
/node_modules
/.pnp
.pnp.*
.yarn/*
!.yarn/patches
!.yarn/plugins
!.yarn/releases
!.yarn/versions

# testing
/coverage

# next.js
/.next/
Expand All @@ -20,22 +10,18 @@
# production
/build

# misc
.DS_Store
*.pem

# debug
npm-debug.log*
yarn-debug.log*
yarn-error.log*
.pnpm-debug.log*

# env files (can opt-in for committing if needed)
# env files
.env*

# vercel
.vercel

# typescript
*.tsbuildinfo
next-env.d.ts
next-env.d.ts
32 changes: 13 additions & 19 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,30 +1,24 @@
# --- Build project ---
FROM oven/bun:1.2.10 as builder

WORKDIR /app
FROM oven/bun:1 AS builder
WORKDIR /usr/src/app

COPY package.json bun.lock ./

RUN bun install
RUN bun install --frozen-lockfile --production

COPY . .

RUN bun run build

# --- Deploy project ---
FROM oven/bun:1.2.10-slim

WORKDIR /app

COPY --from=builder /app/.next .next
COPY --from=builder /app/public public
COPY --from=builder /app/package.json .
COPY --from=builder /app/bun.lock .
COPY --from=builder /app/node_modules node_modules
FROM oven/bun:1 AS runner
WORKDIR /usr/src/app

ENV NODE_ENV=production
ENV PORT=3000

COPY --from=builder /usr/src/app/node_modules ./node_modules
COPY --from=builder /usr/src/app/.next ./.next
COPY --from=builder /usr/src/app/public ./public
COPY --from=builder /usr/src/app/next.config.mjs ./next.config.mjs
COPY --from=builder /usr/src/app/package.json ./package.json
COPY --from=builder /usr/src/app/bun.lock ./bun.lock

EXPOSE 3000

CMD ["bun", "start"]
CMD ["bun", "run", "start"]
Loading