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
apiVersion: v1 | |
kind: Service | |
metadata: | |
name: flask-test-service | |
spec: | |
selector: | |
app: flask-test-app | |
ports: | |
- protocol: "TCP" | |
port: 6000 |
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
private ApiInfo apiDetails() { | |
return new ApiInfo( | |
"Spring Boot Starter Kit", | |
"This is sample starter kit for spring boot to start project for beginner", | |
"1.0.1", | |
"This is free Licence version", | |
new springfox.documentation.service.Contact("Tariqul Islam", "http://github.com/tariqulislam", "tariqul.islam.rony@gmail.com"), | |
"API License", | |
"https://github.com/tariqulislam", | |
Collections.emptyList()); |
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 React from 'react'; | |
import './App.css'; | |
import { withTranslation, Trans } from 'react-i18next' | |
class App extends React.Component { | |
constructor(props) { | |
super(props) | |
this.state = { | |
value: "en" | |
} |
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 i18n from 'i18next' | |
import LanguageDetector from "i18next-browser-languagedetector" | |
import {initReactI18next} from 'react-i18next' | |
import XHR from 'i18next-xhr-backend' | |
import languageEN from './locate/en/translate.json' | |
import languageJP from './locate/jp/translate.json' | |
i18n | |
.use(XHR) | |
.use(LanguageDetector) |
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
{ | |
"translations": { | |
"paragraph": "段落", | |
"author": { | |
"title": "著者名", | |
"value": "タリクル" | |
}, | |
"description": { | |
"title": "説明", | |
"value": "部屋、電車、飛行機などの囲まれた場所にいるときに強いタバコの煙の臭いがするたびに、怒り始めます。いくつかの理由があります。第一に、医学研究者は、間接喫煙、つまり他の人のタバコからの煙が癌やその他の健康上の問題を引き起こすことを示しました。煙が車の排気ガスや燃えているごみであれば、火を消し、窓を開けて煙を取り除きます。第二に、悪臭を放ちます。煙は喫煙者から離れて部屋を埋めます。" |
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
{ | |
"translations": { | |
"paragraph": "Introduction", | |
"author": { | |
"title": "Author Name", | |
"value": "Tariqul" | |
}, | |
"description": { | |
"title": "description", | |
"value": "Whenever I smell strong tobacco smoke when I'm in an enclosed space such as a room, train, or aircraft, I begin to get angry. There are several reasons. First, medical researchers have shown that secondhand smoke, that is, the smoke from other people's cigarettes, causes cancer and other health problems. If the smoke were car exhaust or burning trash, we would put out the fire and open the windows to get rid of the smoke. Second, it stinks. The smoke drifts away from the smoker and fills the room." |
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 React from 'react'; | |
import './App.css'; | |
import {Home} from './routes/HomeComponent' | |
function App() { | |
return ( | |
<div className="App"> | |
<Home /> | |
</div> | |
); |
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
// ./routes/Home.js | |
import React, {Component} from 'react' | |
export class Home extends Component { | |
/* Add the contructor to initialize the local state of the component */ | |
constructor(props) { | |
super(props) | |
/* initial the state for component */ | |
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
FROM python:3.7.5-buster | |
# set up the psycopg2 | |
# set up the psycopg2 | |
RUN apt-get update && apt-get install -y libpq-dev \ | |
gcc \ | |
postgresql-client | |
RUN pip install psycopg2==2.8.3 | |
RUN apt-get autoremove -y gcc |
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
version: '3.7' | |
services: | |
web: | |
build: ./app | |
command: python manage.py runserver 0.0.0.0:8000 | |
volumes: | |
- ./app/:/usr/src/app/ | |
ports: | |
- 8000:8000 | |
env_file: |
NewerOlder