https://github.com/mrinjamul/mrinjamul-admin
Admin Panel for mrinjamul.github.io
https://github.com/mrinjamul/mrinjamul-admin
admin-dashboard go golang heroku security
Last synced: about 1 month ago
JSON representation
Admin Panel for mrinjamul.github.io
- Host: GitHub
- URL: https://github.com/mrinjamul/mrinjamul-admin
- Owner: mrinjamul
- License: mit
- Created: 2021-06-15T07:13:00.000Z (almost 5 years ago)
- Default Branch: master
- Last Pushed: 2021-08-27T14:43:52.000Z (almost 5 years ago)
- Last Synced: 2025-02-01T18:43:48.895Z (over 1 year ago)
- Topics: admin-dashboard, go, golang, heroku, security
- Language: JavaScript
- Homepage: https://mrinjamul-admin.herokuapp.com
- Size: 2.08 MB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
- Code of conduct: CODE_OF_CONDUCT.md
Awesome Lists containing this project
README
# Golang Adminer
Admin Panel for mrinjamul.github.io
## Used Tools and Technologies
- [Golang](https://golang.org/)
- [NodeJs](https://nodejs.org/) (Required: 12+ ,Recommanded: 14 LTS)
- [Docker](https://www.docker.com/) (Optional)
- [Auth0 Account](https://auth0.com/)
- [Firebase](https://firebase.google.com/)
- [Gin Gonic](https://gin-gonic.com/)
- [JWT](https://github.com/square/go-jose)
- [xid](https://github.com/rs/xid)
- [Reactstrap](https://reactstrap.github.io/)
- [React Font Awesome](https://github.com/FortAwesome/react-fontawesome)
- [highlight.js](https://highlightjs.org/) (Imported buthNot Used)
## Required secrets
For ENV,
# Golang ENV (.env)
GIN_MODE=release
PORT=
AUTH0_API_IDENTIFIER=
AUTH0_DOMAIN=
# ReactJs ENV (ui/.env)
REACT_APP_API_URL=
REACT_APP_AUTH0_DOMAIN=
REACT_APP_AUTH0_CLIENTID=
REACT_APP_AUTH0_AUDIENCE=
And Firebase admin sdk private key,
- `serviceAccountKey.json`
Put `serviceAccountKey.json` in project's root directory.
Note: auth_config.json does not required. It's removed.
## Build
### Docker
```shell
docker build -t mrinjamul-admin:latest .
```
### Normal Build
For server,
```shell
go mod download
go build -o main .
```
For UI,
```shell
cd ui
npm install
touch .env # Write environment variables
npm run build
cp -rf build ../static
cd ..
```
## Running
### Run normally
```shell
touch .env # Write environment variables
source .env
./main
```
### Docker
```shell
docker run --rm -dp 3000:3000 --name myadmin mrinjamul-admin:latest
```
## Endpoints
| Methods | Endpoints | Description |
| ------- | ----------------- | ------------------------------------------------------ |
| GET | /api/ping | Use for ping |
| GET | /api/projects | fetch project informations |
| POST | /api/messages | send messeges to firestore |
| GET | /api/messages | fetch messeges from firestore (protected) |
| DELETE | /api/messages/:id | NEED TO IMPLEMENT (WIP) (delete a messege) (protected) |
| PUT | /api/messages | NEED TO IMPLEMENT (WIP) (mark as read) (protected) |
## Author
- Injamul Mohammad Mollah
## License
- under [MIT license](https://github.com/mrinjamul/mrinjamul-admin/blob/master/LICENSE)