module
Version:
v0.0.0-...-8a6c13a
Opens a new window with list of versions in this module.
Published: Apr 1, 2024
License: MIT
Opens a new window with license information.
README
¶
Simple Temporary Files sharing RESTful API with oauth2
API Documentation
⚠ This API is not stable yet, maybe have some breaking changes in the future.
Usage
Requirements
- WSL2 (Windows Subsystem for Linux)
Only need if you use Windows OS
- Make (version >= 4.4.x)
- Go (version >= 1.21.x)
- Git (version >= 2.43.x)
- Docker (version >= 24.0.x)
Optional, only if you want to build image
Installation
git clone https://github.com/afifurrohman-id/tempsy.git
cd tempsy
- Insert Variable into
.env
file
cat <<EOENV > configs/.env
# Server
GOOGLE_CLOUD_STORAGE_BUCKET=example-google-cloud-storage-bucket
APP_ENV=testing
PORT=3210
SERVER_URL=https://example.com
# Credentials
GOOGLE_CLOUD_STORAGE_SERVICE_ACCOUNT=BASE64_ENCODED_JSON_GCP_SERVICE_ACCOUNT_CREDENTIAL
JWT_SECRET_KEY=example-jwt-secret-key
# Emulator
GOOGLE_CLOUD_STORAGE_EMULATOR_ENDPOINT=https://example.com/emulators/storage/v1
# testing
GOOGLE_OAUTH2_REFRESH_TOKEN_TEST=example-oauth2-refresh-token
GOOGLE_OAUTH2_CLIENT_ID_TEST=example-google-oauth2-client-id
GOOGLE_OAUTH2_CLIENT_SECRET_TEST=example-google-oauth2-client-secret
EOENV
go mod tidy
Run
make compose-up
make run
make
make build-image
make test
Directories
¶
Click to show internal directories.
Click to hide internal directories.