version: 2
jobs:
  build-backend:
    working_directory: /go/src/github.com/tejpbit/talarlista/backend
    docker:
      - image: circleci/golang:1.8
    steps:
      - checkout:
          path: /go/src/github.com/tejpbit/talarlista/
      - run: go build backend/main.go

  build-frontend:
    working_directory: ~/talarlista/frontend
    docker:
      - image: circleci/node:8.1.2
    steps:
      - checkout:
          path: ~/talarlista
      - run: npm install
      - run: npm run build
      - run: npm run test
      - run: tar -czvf build.tar.gz build/*
      - store_artifacts:
          path: build.tar.gz
workflows:
  version: 2
  build:
    jobs:
      - build-backend
      - build-frontend
version: 2
jobs:
  build-backend:
    working_directory: /go/src/github.com/tejpbit/talarlista/
    docker:
      - image: circleci/golang:1.8
    steps:
      - checkout:
          path: /go/src/github.com/tejpbit/talarlista/
      - run: go build backend/main.go

  build-frontend:
    working_directory: ~/talarlista/frontend
    docker:
      - image: circleci/node:8.1.2
    steps:
      - checkout:
          path: ~/talarlista
      - run: npm install
      - run: npm run build
      - run: npm run test
      - run: tar -czvf build.tar.gz build/*
      - store_artifacts:
          path: build.tar.gz
workflows:
  version: 2
  build:
    jobs:
      - build-backend
      - build-frontend
Change working directory for backend
Change working directory for backend

