Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

letsspeak/Stock

Open more actions menu

Repository files navigation

Stock

CircleCI

Docker

Run in Docker and Build

  1. git clone https://github.com/letsspeak/Stock.git && cd Stock
  2. docker build ./Docker/ci/ or docker pull letsspeak/stock-ci:latest
  3. export CID=$(docker run -d -it -p 8080:8080 letsspeak/stock-ci:latest bash)
  4. docker cp . $CID:/var/stock
  5. docker exec $CID bash -c 'OPTIMIZE=1 make all'

Start Server

  1. docker exec $CID ./.build/release/stock serve
  2. open http://localhost:8080 on your web browser

Stop Server

  1. docker exec $CID pkill -U root -x stock

Create Docker image for deploy

  1. Perform the above Build procedure
  2. docker cp $CID:/var/stock ./Docker/deploy
  3. docker build ./Docker/deploy

Note: deployment server port is 8080

Ubuntu 16.04

Install Dependencies

Swift and Vapor

  1. $ curl -sL https://apt.vapor.sh | bash
  2. $ sudo apt-get update
  3. $ sudo apt-get -y install swift vapor

MySQL

  1. $

nodejs

  1. $ sudo apt-get install -y nodejs npm
  2. $ curl -sL https://deb.nodesource.com/setup_9.x | sudo -E bash -
  3. $ sudo apt-get install -y nodejs

yarn

  1. curl -sS https://dl.yarnpkg.com/debian/pubkey.gpg | sudo apt-key add -
  2. echo "deb https://dl.yarnpkg.com/debian/ stable main" | sudo tee /etc/apt/sources.list.d/yarn.list
  3. sudo apt-get update && sudo apt-get -y install yarn

Build

  1. $ git clone https://github.com/letsspeak/Stock.git && cd Stock
  2. $ make all

Debug on macOS

Install Dependencies

Vapor

  1. $ brew install vapor/tap/ctls

MySQL

  1. $ brew install vapor/tap/cmysql

yarn

  1. $ brew install yarn

Develop & Debug with Xcode on macOS

  1. $ git clone https://github.com/letsspeak/Stock.git && cd Stock
  2. $ make all
  3. $ make xcode (or swift package generate-xcodeproj)
  4. Open generated Stock.xcodeproj
  5. Select Product -> Scheme -> Edit Scheme... on Xcode menu
  6. Info tab with Run pane, Select Executable Run and check Debug executable
  7. Options tab with Run pane, Check Use custom working directory and select *path/to/Stock
  8. Select Product -> Run on Xcode menu

About

Server Side Swift, React front-end, portfolio-blog-todo Web App

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published
Morty Proxy This is a proxified and sanitized view of the page, visit original site.