Skip to content

Commit cbb35cd

Browse files
albttxMuhammed Afil
authored andcommitted
chore(ci): add build docker image
0 parents  commit cbb35cd

32 files changed

Lines changed: 5239 additions & 0 deletions

.dockerignore

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
node_modules
2+
Dockerfile
3+
.git
4+
.vim
5+
.env

.env.sample

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
MNEMONIC=my hot wallet seed words here that has minimal funds

.github/workflows/docker.yml

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
name: docker
2+
3+
on:
4+
push:
5+
branches:
6+
- 'master'
7+
tags:
8+
- 'v*'
9+
10+
jobs:
11+
docker:
12+
runs-on: ubuntu-latest
13+
steps:
14+
15+
- name: Checkout
16+
uses: actions/checkout@v3
17+
18+
- name: Login to GitHub Container Registry
19+
uses: docker/login-action@v2
20+
with:
21+
registry: ghcr.io
22+
username: ${{ github.repository_owner }}
23+
password: ${{ secrets.GITHUB_TOKEN }}
24+
25+
- name: Docker meta
26+
id: meta
27+
uses: docker/metadata-action@v4
28+
with:
29+
images: ghcr.io/${{ github.repository }}
30+
tags: |
31+
type=raw,value=latest
32+
type=semver,pattern=v{{version}}
33+
34+
- name: Build and push
35+
uses: docker/build-push-action@v3
36+
with:
37+
context: .
38+
push: ${{ github.event_name != 'pull_request' }}
39+
tags: ${{ steps.meta.outputs.tags }}
40+
labels: ${{ steps.meta.outputs.labels }}

.gitignore

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
src/networks.local.json
2+
scripts/*
3+
!scripts/autostake.mjs
4+
!scripts/base.mjs
5+
!scripts/checkAuthz.mjs
6+
!scripts/dryrun.mjs
7+
8+
# dependencies
9+
/node_modules
10+
/.pnp
11+
.pnp.js
12+
13+
# testing
14+
/coverage
15+
16+
# production
17+
/build
18+
19+
# misc
20+
.DS_Store
21+
.env
22+
.env.local
23+
.env.development.local
24+
.env.test.local
25+
.env.production.local
26+
27+
npm-debug.log*
28+
29+
.vim
30+
.iml

.nvmrc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
20

Dockerfile

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
# dev env
2+
FROM node:20.15-buster
3+
4+
RUN apt-get update && apt-get install -y python3 make g++
5+
6+
ENV NODE_ENV=development
7+
8+
WORKDIR /usr/src/app
9+
COPY package*.json ./
10+
RUN npm install
11+
COPY . ./
12+
13+
ENV DIRECTORY_PROTOCOL=https
14+
ENV DIRECTORY_DOMAIN=cosmos.directory
15+
16+
EXPOSE 3000
17+
CMD npm run autostake

LICENSE

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
MIT License
2+
3+
Copyright (c) 2022 ECO Stake
4+
5+
Permission is hereby granted, free of charge, to any person obtaining a copy
6+
of this software and associated documentation files (the "Software"), to deal
7+
in the Software without restriction, including without limitation the rights
8+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9+
copies of the Software, and to permit persons to whom the Software is
10+
furnished to do so, subject to the following conditions:
11+
12+
The above copyright notice and this permission notice shall be included in all
13+
copies or substantial portions of the Software.
14+
15+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21+
SOFTWARE.

0 commit comments

Comments
 (0)