This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Docker Ruby 2.5 on Rails 5.0.3 (ProgateのRuby on Rails 5 学習レッスンとほぼ同じ環境) | |
FROM ruby:2.5 | |
# Rails6ではnodejsとyarnはwebpackをインストールする際に必要 | |
# yarnパッケージ管理ツールをインストール | |
RUN curl -sS https://dl.yarnpkg.com/debian/pubkey.gpg | apt-key add - && \ | |
echo "deb https://dl.yarnpkg.com/debian/ stable main" | tee /etc/apt/sources.list.d/yarn.list | |
RUN apt-get update -qq && apt-get install -y nodejs build-essential libpq-dev postgresql-client yarn | |
WORKDIR /myapp |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
source 'https://rubygems.org' | |
gem 'rails', '5.0.3' | |
# Use Puma as the app server | |
gem 'puma', '3.6.2' | |
# Use SCSS for stylesheets | |
gem 'sass-rails', '5.0.6' | |
# Use Uglifier as compressor for JavaScript assets | |
gem 'uglifier', '3.0.4' | |
gem 'pry-rails', '0.3.4' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Docker Ruby 2.5 on Rails 5.1.6 | |
FROM ruby:2.5 | |
# Rails6ではnodejsとyarnはwebpackをインストールする際に必要 | |
# yarnパッケージ管理ツールをインストール | |
RUN curl -sS https://dl.yarnpkg.com/debian/pubkey.gpg | apt-key add - && \ | |
echo "deb https://dl.yarnpkg.com/debian/ stable main" | tee /etc/apt/sources.list.d/yarn.list | |
RUN apt-get update -qq && apt-get install -y nodejs build-essential libpq-dev postgresql-client yarn | |
WORKDIR /myapp |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Ruby 2.7 on Rails 6 | |
FROM ruby:2.7.4 | |
# Rails6ではnodejsとyarnはwebpackをインストールする際に必要 | |
# yarnパッケージ管理ツールをインストール | |
# yarnパッケージ管理ツールをインストール | |
RUN curl -sS https://dl.yarnpkg.com/debian/pubkey.gpg | apt-key add - && \ | |
echo "deb https://dl.yarnpkg.com/debian/ stable main" | tee /etc/apt/sources.list.d/yarn.list | |
RUN apt-get update -qq && apt-get install -y nodejs build-essential libpq-dev postgresql-client yarn |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Ruby 3.1 on Rails 7 | |
FROM ruby:3.1.0 | |
RUN apt-get update -qq && apt-get install -y nodejs postgresql-client | |
WORKDIR /myapp | |
COPY Gemfile /myapp/Gemfile | |
COPY Gemfile.lock /myapp/Gemfile.lock | |
RUN bundle install | |
# コンテナー起動時に毎回実行されるスクリプトを追加 | |
COPY entrypoint.sh /usr/bin/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html> | |
<head> | |
<meta charset="utf-8"> | |
<meta name="viewport" content="width=device-width, initial-scale=1"> | |
<title>Hello Bulma!</title> | |
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bulma@0.9.1/css/bulma.min.css"> | |
</head> | |
<body> | |
<section class="section"> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const CLASSES = {0:'Apple', 1:'MikanOrange'} | |
//----------------------- | |
// start button event | |
//----------------------- | |
$("#start-button").click(function(){ | |
loadModel() ; | |
startWebcam(); | |
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import 'package:flutter/material.dart'; | |
import 'package:cloud_firestore/cloud_firestore.dart'; | |
void main() => runApp(MyApp()); | |
class MyApp extends StatelessWidget { | |
// This widget is the root of your application. | |
@override | |
Widget build(BuildContext context) { | |
return MaterialApp( |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import 'package:flutter/material.dart'; | |
import 'package:firebase/firebase.dart'; | |
import 'package:firebase/firestore.dart' as fs; | |
// initializeApp()の中身は、ご自身の設定に書き換えてください。 | |
void main() { | |
initializeApp( | |
apiKey: "YourApiKey", | |
authDomain: "YourAuthDomain", | |
databaseURL: "YourDatabaseUrl", |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import 'package:flutter/material.dart'; | |
import 'package:firebase/firebase.dart'; | |
import 'package:firebase/firestore.dart' as fs; | |
void main() { | |
initializeApp( | |
apiKey: "YourApiKey", | |
authDomain: "YourAuthDomain", | |
databaseURL: "YourDatabaseUrl", | |
projectId: "YourProjectId", |
NewerOlder