This commit is contained in:
Maidul Islam
2022-11-18 18:25:14 -05:00
11 changed files with 163 additions and 102 deletions
+2 -2
View File
@@ -28,8 +28,8 @@ EMAIL_TOKEN_LIFETIME=
MONGO_URL=mongodb://root:example@mongo:27017/?authSource=admin MONGO_URL=mongodb://root:example@mongo:27017/?authSource=admin
# Optional credentials for MongoDB container instance # Optional credentials for MongoDB container instance
MONGO_USERNAME=root MONGO_INITDB_ROOT_USERNAME=root
MONGO_PASSWORD=example MONGO_INITDB_ROOT_PASSWORD=example
# Mongo-Express vars (needed for development only) # Mongo-Express vars (needed for development only)
ME_CONFIG_MONGODB_ADMINUSERNAME=root ME_CONFIG_MONGODB_ADMINUSERNAME=root
+4 -2
View File
@@ -1,5 +1,7 @@
# Contributing to Infisical # Contributing to Infisical
Thanks for taking the time to contribute! Thanks for taking the time to contribute! 😃 🚀
Please refer to our Contributing Guide for instructions on how to contribute. Please refer to our [Contributing Guide](https://infisical.com/docs/contributing) for instructions on how to contribute.
We also have some 🔥amazing🔥 merch for our contributors. Please reach out to tony@infisical.com for more info 👀
+4 -4
View File
@@ -1,14 +1,14 @@
build: build:
docker-compose -f docker-compose.yml -f docker-compose.prod.yml build docker-compose -f docker-compose.yml build
push: push:
docker-compose -f docker-compose.yml -f docker-compose.prod.yml push docker-compose -f docker-compose.yml push
up-dev: up-dev:
docker-compose -f docker-compose.yml -f docker-compose.dev.yml up --build docker-compose -f docker-compose.dev.yml up
up-prod: up-prod:
docker-compose -f docker-compose.yml -f docker-compose.prod.yml up --build docker-compose -f docker-compose.yml up
down: down:
docker-compose down docker-compose down
+4 -5
View File
@@ -3,7 +3,7 @@
<img width="300" src="/img/logoname-white.svg#gh-dark-mode-only" alt="infisical"> <img width="300" src="/img/logoname-white.svg#gh-dark-mode-only" alt="infisical">
</h1> </h1>
<p align="center"> <p align="center">
<p align="center">Open-source, end-to-end encrypted, 1-line-of-code tool to sync environment variables across you team and infrastructure.</p> <p align="center">Open-source, end-to-end encrypted, easy-to-use tool to auto-sync environment variables across you team and infrastructure.</p>
</p> </p>
<h4 align="center"> <h4 align="center">
@@ -30,7 +30,7 @@
**[Infisical](https://infisical.com)** is an open source tool to help teams manage and sync environment variables across their development workflow and infrastructure. It's designed to be simple and end-to-end encrypted. You can start with just 1 line of code within 10 minutes. **[Infisical](https://infisical.com)** is an open source tool to help teams manage and sync environment variables across their development workflow and infrastructure. It's designed to be simple and end-to-end encrypted. You can start with just 1 line of code within 10 minutes.
- **User-Friendly Dashboard** to manage your organization's environment variables within projects - **User-Friendly Dashboard** to manage your organization's environment variables within projects
- **[Language-Agnostic CLI](https://infisical.com/docs/CLI)** that pulls and injects environment variables into your local workflow - **[Language-Agnostic CLI](https://infisical.com/docs/CLI)** that pulls and injects environment variables into your local workflow
- **[Complete control over your data](https://infisical.com/docs/self_host_overview)** - host it yourself on any infrastructure - **[Complete control over your data](https://infisical.com/docs/self_host_overview)** - host it yourself on any infrastructure
- **Navigate Multiple Environments** per project (e.g. development, staging, production, etc.) - **Navigate Multiple Environments** per project (e.g. development, staging, production, etc.)
- **Personal/Shared** scoping for environment variables - **Personal/Shared** scoping for environment variables
@@ -88,7 +88,6 @@ We're currently setting the foundation and building integrations so secrets can
- [ ] GitLab - [ ] GitLab
- [ ] CircleCI - [ ] CircleCI
We're currently in Public Alpha. We're currently in Public Alpha.
## Open-source vs. paid ## Open-source vs. paid
@@ -99,7 +98,6 @@ This repo is entirely MIT licensed, with the exception of the `ee` directory whi
Looking to report a security vulnerability? Please don't post about it in GitHub issue. Instead, refer to our [SECURITY.md](./SECURITY.md) file. Looking to report a security vulnerability? Please don't post about it in GitHub issue. Instead, refer to our [SECURITY.md](./SECURITY.md) file.
## Contributors 🦸 ## Contributors 🦸
[//]: contributor-faces [//]: contributor-faces
@@ -107,4 +105,5 @@ Looking to report a security vulnerability? Please don't post about it in GitHub
<!-- ALL-CONTRIBUTORS-LIST:START - Do not remove or modify this section --> <!-- ALL-CONTRIBUTORS-LIST:START - Do not remove or modify this section -->
<!-- prettier-ignore-start --> <!-- prettier-ignore-start -->
<!-- markdownlint-disable --> <!-- markdownlint-disable -->
<a href="https://github.com/dangtony98"><img src="https://avatars.githubusercontent.com/u/25857006?v=4" width="50" height="50" alt=""/></a> <a href="https://github.com/vlad-matsiiako"><img src="https://avatars.githubusercontent.com/u/78047717?s=96&v=4" width="50" height="50" alt=""/></a> <a href="https://github.com/maidul98"><img src="https://avatars.githubusercontent.com/u/9300960?v=4" width="50" height="50" alt=""/></a> <a href="https://github.com/hanywang2"><img src="https://avatars.githubusercontent.com/u/44352119?v=4" width="50" height="50" alt=""/></a>
<a href="https://github.com/dangtony98"><img src="https://avatars.githubusercontent.com/u/25857006?v=4" width="50" height="50" alt=""/></a> <a href="https://github.com/vlad-matsiiako"><img src="https://avatars.githubusercontent.com/u/78047717?s=96&v=4" width="50" height="50" alt=""/></a> <a href="https://github.com/maidul98"><img src="https://avatars.githubusercontent.com/u/9300960?v=4" width="50" height="50" alt=""/></a> <a href="https://github.com/hanywang2"><img src="https://avatars.githubusercontent.com/u/44352119?v=4" width="50" height="50" alt=""/></a> <a href="https://github.com/tobias-mintlify"><img src="https://avatars.githubusercontent.com/u/110702161?v=4" width="50" height="50" alt=""/></a>
+1
View File
@@ -38,6 +38,7 @@ import {
} from './routes'; } from './routes';
const connectWithRetry = () => { const connectWithRetry = () => {
console.log('MONGO_URL', MONGO_URL);
mongoose.connect(MONGO_URL) mongoose.connect(MONGO_URL)
.then(() => console.log('Successfully connected to DB')) .then(() => console.log('Successfully connected to DB'))
.catch((e) => { .catch((e) => {
+26 -14
View File
@@ -1,8 +1,21 @@
version: '3' version: '3'
services: services:
nginx:
container_name: infisical-dev-nginx
image: nginx
ports:
- 8080:80
volumes:
- ./nginx/default.dev.conf:/etc/nginx/conf.d/default.conf:ro
depends_on:
- frontend
- backend
networks:
- infisical-dev
backend: backend:
container_name: infisical-backend container_name: infisical-dev-backend
restart: unless-stopped restart: unless-stopped
depends_on: depends_on:
- mongo - mongo
@@ -17,10 +30,10 @@ services:
command: npm run dev command: npm run dev
env_file: .env env_file: .env
networks: networks:
- infisical - infisical-dev
frontend: frontend:
container_name: infisical-frontend container_name: infisical-dev-frontend
restart: unless-stopped restart: unless-stopped
depends_on: depends_on:
- backend - backend
@@ -35,32 +48,31 @@ services:
- ./frontend/components:/app/components - ./frontend/components:/app/components
env_file: .env env_file: .env
networks: networks:
- infisical - infisical-dev
mongo: mongo:
container_name: infisical-mongo
image: mongo image: mongo
container_name: infisical-dev-mongo
restart: always restart: always
env_file: env_file: .env
- .env
volumes: volumes:
- mongo-data:/data/db - mongo-data:/data/db
networks: networks:
- infisical - infisical-dev
mongo-express: mongo-express:
container_name: infisical-mongo-express container_name: infisical-dev-mongo-express
image: mongo-express image: mongo-express
restart: always restart: always
depends_on: env_file: .env
- mongo
ports: ports:
- 8081:8081 - 8081:8081
env_file:
- .env
networks: networks:
- infisical - infisical-dev
volumes: volumes:
mongo-data: mongo-data:
driver: local driver: local
networks:
infisical-dev:
-57
View File
@@ -1,57 +0,0 @@
version: '3'
services:
backend:
platform: linux/amd64
container_name: infisical-backend
restart: unless-stopped
depends_on:
- mongo
build:
context: ./backend
dockerfile: Dockerfile
image: infisical/backend
volumes:
- ./backend/src:/app/src
- ./backend/nodemon.json:/app/nodemon.json
- /app/node_modules
command: npm run start
env_file: .env
networks:
- infisical
frontend:
platform: linux/amd64
container_name: infisical-frontend
restart: unless-stopped
depends_on:
- backend
build:
context: ./frontend
dockerfile: Dockerfile.prod
image: infisical/frontend
volumes:
- ./frontend/pages:/app/pages
- ./frontend/public:/app/public
- ./frontend/styles:/app/styles
- ./frontend/components:/app/components
- ./frontend/next.config.js:/app/next.config.js
env_file: .env
networks:
- infisical
mongo:
container_name: infisical-mongo
image: mongo
restart: always
environment:
MONGO_INITDB_ROOT_USERNAME: root
MONGO_INITDB_ROOT_PASSWORD: example
volumes:
- mongo-data:/data/db
networks:
- infisical
volumes:
mongo-data:
driver: local
+57 -3
View File
@@ -5,13 +5,67 @@ services:
container_name: infisical-nginx container_name: infisical-nginx
image: nginx image: nginx
ports: ports:
- "8080:80" - 80:80
- 443:443
volumes: volumes:
- ./nginx/default.conf:/etc/nginx/conf.d/default.conf:ro - ./nginx/default.conf:/etc/nginx/conf.d/default.conf:ro
networks:
- infisical
depends_on: depends_on:
- frontend - frontend
- backend
networks:
- infisical
backend:
platform: linux/amd64
container_name: infisical-backend
restart: unless-stopped
depends_on:
- mongo
build:
context: ./backend
dockerfile: Dockerfile
image: infisical/backend
volumes:
- ./backend/src:/app/src
- ./backend/nodemon.json:/app/nodemon.json
- /app/node_modules
command: npm run start
env_file: .env
networks:
- infisical
frontend:
platform: linux/amd64
container_name: infisical-frontend
restart: unless-stopped
depends_on:
- backend
build:
context: ./frontend
dockerfile: Dockerfile.prod
image: infisical/frontend
volumes:
- ./frontend/pages:/app/pages
- ./frontend/public:/app/public
- ./frontend/styles:/app/styles
- ./frontend/components:/app/components
- ./frontend/next.config.js:/app/next.config.js
env_file: .env
networks:
- infisical
mongo:
container_name: infisical-mongo
image: mongo
restart: always
volumes:
- mongo-data:/data/db
networks:
- infisical
volumes:
mongo-data:
driver: local
networks: networks:
infisical: infisical:
+10 -7
View File
@@ -26,12 +26,20 @@
{ {
"name": "Security", "name": "Security",
"icon": "shield-halved", "icon": "shield-halved",
"url": "https://infisical.com/security" "url": "https://infisical.com/security",
"color": {
"from": "#A1B659",
"to": "#F8B7BD"
}
}, },
{ {
"name": "Blog", "name": "Blog",
"icon": "newspaper", "icon": "newspaper",
"url": "https://infisical.com/blog" "url": "https://infisical.com/blog",
"color": {
"from": "#A1B659",
"to": "#F8B7BD"
}
} }
], ],
"navigation": [ "navigation": [
@@ -73,10 +81,5 @@
] ]
} }
], ],
"classes": {
"topbarCtaButton": "bg-[#BADC58] hover:opacity-80 text-black rounded-md px-7 py-2.5 font-semibold",
"anchors": "group-hover:bg-gradient-to-br from-sky-400 to-primary",
"activeAnchors": "bg-gradient-to-br"
},
"backgroundImage": "/docs/images/background.png" "backgroundImage": "/docs/images/background.png"
} }
+15
View File
@@ -1,5 +1,20 @@
server { server {
listen 80; listen 80;
listen [::]:80;
server_name api.infisical.com;
return 302 https://$server_name$request_uri;
}
server {
listen 443 default_server ssl http2;
listen [::]:443 ssl http2;
server_name api.infiscal.com;
ssl_certificate /etc/ssl/cert.pem;
ssl_certificate_key /etc/ssl/cert.key;
location /api { location /api {
proxy_set_header X-Real-RIP $remote_addr; proxy_set_header X-Real-RIP $remote_addr;
+32
View File
@@ -0,0 +1,32 @@
server {
listen 80;
location /api {
proxy_set_header X-Real-RIP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header Host $http_host;
proxy_set_header X-NginX-Proxy true;
proxy_pass http://backend:4000;
proxy_redirect off;
proxy_cookie_path / "/; secure; HttpOnly; SameSite=strict";
}
location / {
include /etc/nginx/mime.types;
proxy_set_header X-Real-RIP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header Host $http_host;
proxy_set_header X-NginX-Proxy true;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "upgrade";
proxy_pass http://frontend:3000;
proxy_redirect off;
}
}