Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

revert site back online + point to new owner resource #387

Merged
merged 11 commits into from
Dec 12, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 5 additions & 4 deletions .github/workflows/cloudflare-ca-beta.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,14 +35,15 @@ jobs:
env:
NITRO_PRESET: cloudflare
REGION: CA
PROD: 'false'
PROD: 'true'

- name: CA BETA Publish to Cloudflare
- name: Publish to Cloudflare
uses: cloudflare/wrangler-action@2.0.0
with:
apiToken: ${{ secrets.CF_API_TOKEN }}
accountId: ${{ secrets.CF_ACCOUNT_ID }}
wranglerVersion: '1.19.12'
environment: ca_beta
environment: test
env:
PROD: 'false'
PROD: 'true'
REGION: CA
53 changes: 0 additions & 53 deletions .github/workflows/cloudflare-ca-prod.yml

This file was deleted.

2 changes: 1 addition & 1 deletion .nvmrc
Original file line number Diff line number Diff line change
@@ -1 +1 @@
20
16
37 changes: 37 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
####
# build: pull in + install everything to run nuxt build
####

FROM node:12-alpine as build
RUN apk --no-cache add wget git g++ make python

WORKDIR /build
COPY package*.json /build/
RUN npm install
RUN apk --no-cache del git g++ make python
COPY . /build

RUN npm run build


########
# run: do production install + copy build output of build container and run the node server
########
FROM node:12-alpine as main

WORKDIR /build
COPY --from=build /build/package*.json /build/
RUN npm install --production

# copy min needed to run (built) app
COPY --from=build /build/nuxt.config.ts /build
COPY --from=build /build/.nuxt /build/.nuxt
COPY --from=build /build/static /build/static
RUN apk --no-cache add wget

EXPOSE 3000

HEALTHCHECK --interval=30s --timeout=1s CMD wget localhost:3000/ping -q -O/dev/null || exit 1

USER node
CMD npm start
9 changes: 9 additions & 0 deletions Dockerfile-dev
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
FROM node:10-alpine

WORKDIR /build
COPY package*.json /build/
VOLUME /build

EXPOSE 3000

CMD HOST=0.0.0.0 NODE_ENV=production PROD=true npm run dev
21 changes: 21 additions & 0 deletions LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
The MIT License (MIT)

Copyright (c) 2017 Ammobin.ca

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
107 changes: 53 additions & 54 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,83 +1,82 @@
# ammobin.ca has been shut down
# AmmoBin.ca [![Greenkeeper badge](https://badges.greenkeeper.io/ammobinDOTca/ammobin-client.svg)](https://greenkeeper.io/) [![docker pulls](https://img.shields.io/docker/pulls/ammobindotca/ammobin-client.svg)](https://hub.docker.com/r/ammobindotca/ammobin-client 'DockerHub')

the code on the master branch is the shutdown version of the site
The meta search site for ammo prices across Canada. built with [nuxt.js](https://nuxtjs.org) (and thus vue.js).

if you want to see what it looked like (or steal the code) [goto here](https://github.com/ammobinDOTca/ammobin-client/releases/tag/LAST_LIVE_VERSION_OF_SITE# )
![Screenshot-2017-9-27 The place to view the best online ammo prices across Canada.png](https://raw.githubusercontent.com/ammobinDOTca/ammobin-client/master/Screenshot-2017-9-27%20The%20place%20to%20view%20the%20best%20online%20ammo%20prices%20across%20Canada%20.png)

----
## how to run

# Nuxt 3 Minimal Starter
1. `docker run ammobindotca/ammo-bin-client -p 3000:3000`

Look at the [Nuxt 3 documentation](https://nuxt.com/docs/getting-started/introduction) to learn more.
## how to run locally

## Setup
- `npm i`
- `PROD=true npm run dev` (will target prod api)

Make sure to install the dependencies:
##

```bash
# npm
npm install
`AWS_PROFILE=beta BUCKET_NAME=beta-ammobin-ca node upload.js`

# pnpm
pnpm install
## todo

# yarn
yarn install
- https://github.com/WICG/BackgroundSync/blob/master/explainer.md

# bun
bun install
```
## contributing

## Development Server
- do some work
- submit pr

Start the development server on `http://localhost:3000`:
## vendors to add

```bash
# npm
npm run dev
- https://www.italiansportinggoods.com/ammunition/rifle.html
- https://internationalshootingsupplies.com/
- https://shophighfalls.com/collections/rifle-ammo?view=ALL (css rules hinder pulling data. will need to update scraper)
- http://shop.sylvestresportinggoods.com/Rifle-Ammunition/?p=catalog&mode=catalog&parent=506&pg=1&CatalogSetSortBy=price

# pnpm
pnpm run dev
- http://www.grouseriver.com/Hunting-Shooting/Ammunition
- https://blue-wolf-firearms-canada.myshopify.com/collections/rimfire
- https://gunworx.ca/collections/ammunition
- https://www.latulippe.com/en/our-stores/
- http://doctordeals.ca/product-category/smoking-gun/ammunition/rifle-ammo/
- http://store.easthilloutdoors.com/ammo/bulk-ammo

# yarn
yarn dev
* http://www.danchasse.com/shop_free/index.php?categoryID=109 (je ne parle en francis)

# bun
bun run dev
```
# low priority

## Production
- http://greendiamondoutfitters.ca/home/products_grid/category/rifle-ammunition/P24
- http://practicalperformance.ca/accessories/ammunition/
- https://www.greatnorthprecision.com/collections/rifle-ammunition-1
- http://targetshootingproducts.com/index.php?cPath=10&osCsid=b5dd02944271605ca93e19ea903cd3d2
- http://www.thegunroom.ca/index.php?route=product/category&path=85 (6 items

Build the application for production:
## blocked

```bash
# npm
npm run build
- http://westrifle.com/wrstore/index.php?main_page=index&cPath=2 (everything was sold out nov 2017)
- https://eccfirearms.blogspot.ca/2011/02/ammunition-ecc-firearms-has-widest.html (cant buy oneline as of feb 17 2018)
- https://tandtarms.com/product-category/ammo/
- http://www.armseast.ca/surplus_ammunition/ no items
- https://selectshootingsupplies.com/pages/ammunition no online sales
- https://www.precisionoptics.net/category_s/761.htm html is too nasty to bother with

# pnpm
pnpm run build
(see commented out retailers in constants.ts for disabled integrations)

# yarn
yarn build
## skipped

# bun
bun run build
```
- wholesalesports.com
- http://www.prairieshotammo.com/find-a-dealer-3.html (but should review these retailers to see if they have online shops)
- http://www.generalgun.ca/ammunition only 1 item
- https://www.kellysonline.ca/collections/ammunition only 1 item
- https://armtac.com/category/ammunition only one 1 item

Locally preview production build:
## incomplete vendors

```bash
# npm
npm run preview
- none

# pnpm
pnpm run preview
## docker hub

# yarn
yarn preview
https://hub.docker.com/r/ammobindotca/ammobin-client/

# bun
bun run preview
```
## regionalize work

Check out the [deployment documentation](https://nuxt.com/docs/getting-started/deployment) for more information.
- update
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Loading